Header(array('settings' => 'Settings', 'help' => 'Help'), 'custom_code_config_{n}'); ?>
tabStart('settings'); ?>
input('action_custom_code_{n}_mode_config', array('type' => 'select', 'label' => 'Mode', 'options' => array('controller' => 'Controller', 'view' => 'View'), 'smalldesc' => 'When should this code run ? during the controller code processing (early) or later when the ouput is viewed.')); ?>
input('action_custom_code_{n}_action_label_config', array('type' => 'text', 'label' => "Action Label", 'class' => 'medium_input', 'smalldesc' => 'Label for your action in the wizard.')); ?>
input('action_custom_code_{n}_content1_config', array('type' => 'textarea', 'label' => "Code", 'rows' => 20, 'cols' => 70, 'smalldesc' => 'any code can be placed here, any PHP code should include the PHP tags.')); ?>
tabEnd(); ?>
tabStart('help'); ?>
You may use PHP code with php tags.
Running this as Controller is required if you want to do some data processing for some serverside stuff like sending emails, uploading files, saving data or even processing some payment gateway response.
Running this as View is "advised" if you want to output some data, like any kind of HTML, it depends on when and where you want this data displayed and on which other actions do you have.
Running in View will auto enable the "curly brackets replacer".
the variable $form->form_output is available for use at both modes, it holds the form view output up to the moment of running this action.