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.

Using plugin options as form fields

  1. Paul
    Member

    Hi, Can you give me a quick pointer on how to use values from the wordpress options table in form fields.

    For example, if one of my plugin options is 'product1' - is it possible to use $myoptions['product1'] in a form field?

    thanks,
    Paul.

    Posted 13 years ago on Monday May 24, 2010 | Permalink
  2. Are you referring to populating fields dynamically? This is doable. You have to write PHP and use available hooks to populate the fields. You can populate them with whatever you want, including WordPress options. You just have to know how to write the PHP to do so.

    See these threads:

    http://forum.gravityhelp.com/topic/post-title-automaticly-into-form

    http://forum.gravityhelp.com/topic/correct-syntax-to-populate-fields-dynamically

    You can also search the forums for "pre-populating fields" or similar searches and find other threads that discuss how to pre-define fields values using code.

    Posted 13 years ago on Monday May 24, 2010 | Permalink
  3. Paul
    Member

    Perfect - thanks Carl - brilliant response time by the way..

    Posted 13 years ago on Monday May 24, 2010 | Permalink