- JotForm SupportNeilVicenteAsked on November 07, 2012 at 11:33 AM
In response to flcag's question here re: utilizing (hosted) WordPress username as session variable in the save forms feature
Note: this is for forms embedded on a post/page
1. Install and activate a WordPress plugin called PHP Code for Posts
2. Get your form's iFrame embed codes.
3. Integrate your form's iFrame codes with custom WP codes using the guideline below. The added codes are highlighted in yellow.
<?php global $current_user;
<iframe allowtransparency="true" src="//form.jotform.com/form/20105908108?session=<?php echo $current_user->user_login ?>" frameborder="0" style="width:100%; height:486px; border:none;"
4. Having activated the PHP Code for Posts plugin, go to the said plugin's page, then click Add New (code)
5. Add the integrated form codes (from step 3) then click Save this code
6. After saving, copy the Shortcode generated for that particular PHP snippet
7. Copy this shortcode on any WordPress post or page
8. Save your WordPress post or page
- guest_23100490542037Answered on November 07, 2012 at 12:08 PMThank You!