Jump to content

Create a simple form in a front office page


Recommended Posts

Hi there,

I would like to create a simple form on a front office page. I started to create a module, I called it cg_cartegrise. In that module I manage to display text content in backoffice. I then create two pages on front office: formulaire and resultat. this by creating 'controller/front/formulaire.php and resultat.php. these controllers redirect to views/templates/front/formulaire.tpl and resultat.tpl.

So I can see my pages formulaire ans resultat displayed in path : http://localhost/prestashop/module/cg_mymodule/formulaire and ./resultat

Ok. Now, how can I use class HelperForm() in front controllercg_cartegrise.zip to get my form displayed on page formulaire.

Is it also possible to have a dedicated controller to execute or process this form, and then display the results in page resultat.

Thank's per advance.

cg_cartegrise-2.zip

Edited by Jean L.
update and precise my request (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...