// Package web serves the broker's minimal hosted pages (RTL Persian). Clients // normally redirect users back to their OWN return_url; these pages are a // branded landing + a fallback result screen for direct visits. package web import ( "fmt" "html" "net/http" "github.com/gin-gonic/gin" ) const shell = `
این سرویس پرداختهای آنلاین را از طریق زرینپال پردازش میکند.
برای پرداخت، از طریق وبسایت مربوطه اقدام کنید.
` c.Header("Content-Type", "text/html; charset=utf-8") c.String(http.StatusOK, page("FlatRender Pay", inner)) } // Result is an optional fallback screen a client may point its return_url at. func Result(c *gin.Context) { status := c.Query("status") ref := c.Query("ref_id") var inner string if status == "Paid" { inner = `کد پیگیری: ` + html.EscapeString(ref) + `
` } } else { inner = `