PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

$form for all forms that I created

  1. sascha
    Member

    Hi there,

    is there a way to access $form for all forms that I created? I mean not just for the individual form that I am on, but the form data for all the forms. I assume the $form object for each form is saved in the DB. How would I retrieve it for all existing forms?

    Posted 12 years ago on Tuesday January 17, 2012 | Permalink
  2. sascha
    Member

    Hi there,

    ok I found this useful:
    $form = RGFormsModel::get_form_meta('11'); // 11 is id of form

    What happens if I call the above with an id, that does not exist? Will it just skip or throw an error?

    AND: (this is only for possible performance reasons - not sure if that should be a consideration?)

    instead of getting the whole form array with:

    $form = RGFormsModel::get_form_meta('11'); // 11 is id of form

    Is there a way to only get the ['cssClass'] part for each form only? That must be quicker I assume than getting always the whole form - especially if you have lets say 50 forms. That is a lot of information to get and keep somewhere.

    Posted 12 years ago on Tuesday January 17, 2012 | Permalink