Code: Select all
{cms_module module='FormBuilder' form='myform' value_fld1=$myVar}
Here's an example of some of it (I've only included a few fields because the full thing is massive, like a hundred fields!)
Code: Select all
<div class="feedback">
{$fb_form_header}
{if $fb_form_done == 1}
{* This first section is for displaying submission errors *}
{if isset($fb_submission_error) && $fb_submission_error}
<div class="error_message">{$fb_submission_error}</div>
{if isset($fb_show_submission_errors) && $fb_show_submission_errors}
<div>
{foreach from=$fb_submission_error_list item=thisErr}
<span class="error">{$thisErr}</span>
{/foreach}
<br />
</div>
{/if}
{/if}
{else}
{if $fb_form_has_validation_errors}
<div>
{foreach from=$fb_form_validation_errors item=thisErr}
<span class="error">{$thisErr}</span>
{/foreach}
<br />
</div>
{/if}
{if $captcha_error}
<div>
<span class="error">You did not correctly enter the characters in the image. Please try again.</span>
<br />
</div>
{/if}
{$fb_form_start}
{$fb_hidden}
<fieldset>
<legend>Send us a message</legend>
<p>(You have to enter something in the fields marked with a '*')</p>
<div class="input-field">
<label class="main-label">Your Name *:</label>
<input name="cntnt01fbrp__14" class="textfield med" type="text">
</div>
{*hundreds more fields here*}
<div class="input-field">
<label class="main-label">Please enter the characters you see in the 'captcha' image below *</label>
{$graphic_captcha}
<input class="textfield small" name="cntnt01fbrp_captcha_phrase" id="cntnt01fbrp_captcha_phrase" value="" maxlength="255" type="text">
<p>(This helps prevent spam email, and so allows us to respond to your message sooner.) </p>
</div>
<div class="input-field">
{$submit}
</div>
</fieldset>
{/if}
{$fb_form_end}
{$fb_form_footer}
I've done a {get_template_vars} and found objects for each of my form fields, and done a print_r on a few of them. I was hoping that the {$my_field->values} object variable might give what I'm after, but it seems that the previously entered value is just added to the {$my_field->input} html string, which I'm not using on a lot of my fields as they are hard coded... is there anyway I can get at the value or do I just have to bite the bullet and use the input variable of each field to generate my html?