Pre-filled fields on the basis of the referring pages

Marek 22 Mar, 2012
Hi,

please i have this problem.

I have some products and i need create Question form, but is possible to create some hidden field or something, what pre-filled field on the basis of refferring page? Perfect was title?

Thanks.
GreyHead 22 Mar, 2012
Hi Marek ,

Which version of ChronoForms are you using? You can find the version from Site Admin | Extensions | Install/Uninstall | Components in Joomla! 1.5 or Site Admin | Extensions | Extension Manager | Manage in Joomla! 1.6/1.7/2.5.

Bob
Marek 22 Mar, 2012
Hi Bob,

i use lastest version: Chronoforms_V4_RC3.21_J1.6.zip
GreyHead 22 Mar, 2012
Hi Marek,

If you are using the ChronoForms plug-in to embed the form in articles then add a Hidden input with the name title and drag a Custom Code element into the Preview box. Open the element, check the 'Pure Code' box and add this code
<?php
$doc =& JFactory::getDocument();
?>
<input type='hidden' name='title' id='title' value='<?php echo $doc->getTitle(); ?>' />

This will put the current page title in your form data.

Bob
This topic is locked and no more replies can be posted.