“How did you hear about us,” cont. Add “Other” text field
Following up on a previous post - http://lifehackmom.com/how-to-add-a-how-did-you-hear-about-us-survey-to-webjobs/
Here is how to add a write-in “Other” text field, in case a registrant was referred by a source that isn’t in the drop-down list you created.
Step 1: Add other_referrals field to database
In jb_users table, add a new text field called other_referrals to store the data that users write in on their registration form.
Step 2: Register Employer page:
In engine/pages/register_employer.php — Add this line under the line where you added the referrals - around line 151
‘other_referrals’ => $sql->escape_string($input[’other_referrals’]),
Add other_referrals into your array a few lines down, so that it looks like this:
array(’login’, ‘password’, ’status’, ’salutation’, ‘first_name’,'middle_initial’, ‘last_name’,
’suffix’, ’suffix_titles’, ‘company_name’, ‘completed’, ’signup_time’, ‘referrals’, ‘other_referrals’, ‘timezone’, ‘language’));
Step 3:
Add the other field to the xml file (smartway/conf/register_employer or register_employer_city or whatever depending on how you’ve configured webjobs).
<input name=”other_referrals” required=”0″>other_referrals</input>
You are done! So easy!
Next post will be on how to track and view the results in the Smartway statistics section.