Template Form Values

Discussion in 'Developers' Forum' started by nveid, Aug 23, 2011.

  1. nveid

    nveid ISPConfig Developer

    How can I use a template form value that is not defined in the form/list definition file(I don't want to write this form value to SQL)?


    Any examples I could be pointed to possibly?
     
  2. till

    till Super Moderator

    You can set the variable manually with the setVar function of the templating system in the onShow function of the form.

    For examples, take a look at the various *_edit.php files.
     
  3. nveid

    nveid ISPConfig Developer

    I mean reading it in, not displaying it to the template.
     
  4. till

    till Super Moderator

    You mean a submitted form value? All submitted values are in the PHP $_POST variable. You can e.g. use the onAfterUpdate or onAfterInsert functions to implement actions that occur after a form has been submitted.
     
    Last edited: Aug 23, 2011
  5. nveid

    nveid ISPConfig Developer

    Ahh, okay thanks! The appropriate method on the object to throw my code in. That completes a lot of the work I been working on, thanks! :)
     

Share This Page