hugo-mx-gateway

Contact/demo forms handler for static websites (program)
  https://github.com/rchakode/hugo-mx-gateway
  0
  no reviews



Hugo-mx-gateway provides a RESTful POST endpoint for static contact/demo request pages. It's a simple, yet a powerful tool built for this only-designated purpose, e.g. for use with static sites built using Hugo.

hugo-mx-gateway is built upon a simple request handling workflow:

* Create an HTML form with a POST action pointing towards the hugo-mx- gateway service. * For each user request, hugo-mx-gateway automatically retrieves information submitted by the user (email, subject, message details...), then generates and sends a templated email (based on Go Template to the user-provided email address, while bcc'ing a copy of that email to an address that you can define for internal tracking and follow up. * Once a request is processed (upon success or failure), hugo-mx-gateway handles the reply back towards the calling static page by redirecting the browser to the origin page with additional URL parameters describing the completion status of the processing (e.g. /contact.html?status=success&message=request%20submitted). The parameters can then be easily retrieved and shown to the user, e.g. with a few lines of Javascript within the static page.