Form helper - and single pages - send & receive data
PermalinkExample:
I set in the form the name to "ezra" --> sumbit
The output: "Hello ezra"
"THE PROBLEM" This example works fine but i want to learn how to use the form helper to pass data (not html markup). What i need to change in the view code?
The controller:
single_page/controllers/example.php
<?php //Controller namespace Application\Controller\SinglePage; use PageController; class Example extends PageController { public function helloWorld_function(){ $name = "Hello " . $this->post('name'); $this->set('myName', $name); } }
The view:
single_page/example.php
"action="<?php echo $this->action('helloWorld_function')?>">"
http://documentation.concrete5.org/developers/security/sanitizing-u...
http://documentation.concrete5.org/developers/appendix/form-widget-...
It shows you how to use the helper and some specific form widgets (font picker, user picker, color picker...)
TO learn about the more traditional form inputs (text input, select list, checkbox...) you can look at the legacy docs. It hasn't changed with 5.7
http://legacy-documentation.concrete5.org/developers/forms/standard...