The 'Pricing' page was populated from a LISE module.
The form field to be auto filled:
Code: Select all
<div class="form-group mt-10">
<label for="mysubject"><span>Subject</span><i class="fal fa-question"></i></label>
<input type="text" name="mysubject" id="mysubject" placeholder="Subject" required/>
</div>
I created the link in the LISE template including the info I wanted in the subject field of the form:
Code: Select all
<a href="{cms_selflink href="contact"}&subject={$item->title|escape:url} at {$item->price_text}{$item->price}" class="site-btn">Submit Enquiry</a>
Then in the CGBetterForms form 'Pre-render Logic' field I added:
Code: Select all
{cgbf_set key=mysubject value={$smarty.get.subject|unescape} }
Now each enquiry link automatically fills the 'Subject' field of the contact form.