Title: Insert Parameters from URL
Last modified: August 7, 2019

---

# Insert Parameters from URL

 *  Resolved [colcrlogist](https://wordpress.org/support/users/colcrlogist/)
 * (@colcrlogist)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/insert-parameters-from-url/)
 * Hi, I am trying the code from the Help Center – [https://help.10web.io/hc/en-us/articles/360015534251-Insert-Parameters-from-URL](https://help.10web.io/hc/en-us/articles/360015534251-Insert-Parameters-from-URL)
 * I have replaced the {{field_id}} with wdform_5_element7 and {{param_name}} with
   test and I am using the url for my form as /form-maker/preview/?wdform_id=7&test
   =abc
 * abc is not being populated in the field.
 * I have tried with double {{ }} and single { } and without them but this is making
   no difference.
 * Please help as this is driving me nuts!
 * Thanks, Colin

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Support [Zhanna Khachatryan](https://wordpress.org/support/users/zhannak/)
 * (@zhannak)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/insert-parameters-from-url/#post-11812054)
 * Hi Colin,
 * Thanks for your inquiry.
 * Colin, please try to add this code:
 *     ```
       function getParameterByName(name, url) {
                if (!url) {
                     url = window.location.href;
                }
                name = name.replace(/[[]]/g, "$&");
                var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"),
                    results = regex.exec(url);
                if (!results) return null;
                if (!results[2]) return '';
                return decodeURIComponent(results[2].replace('/+/g', " "));
           }
           jQuery("#wdform_5_element7").val(getParameterByName("test"));
           jQuery("#wdform_5_element7").attr("class", "input_active");
       ```
   
 * Please make sure to choose the correct ID.
 * If for some reason this won’t help, then please try to inspect element to see
   whether you have any errors.
 *  Thread Starter [colcrlogist](https://wordpress.org/support/users/colcrlogist/)
 * (@colcrlogist)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/insert-parameters-from-url/#post-11815945)
 * Thank you, not sure what the difference is but that is working – 5 stars 🙂
 *  Plugin Support [Zhanna Khachatryan](https://wordpress.org/support/users/zhannak/)
 * (@zhannak)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/insert-parameters-from-url/#post-11823336)
 * Awesome @colcrlogis!

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Insert Parameters from URL’ is closed to new replies.

 * ![](https://ps.w.org/form-maker/assets/icon-256x256.png?rev=2068681)
 * [Form Maker by 10Web - Mobile-Friendly Drag & Drop Contact Form Builder](https://wordpress.org/plugins/form-maker/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/form-maker/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/form-maker/)
 * [Active Topics](https://wordpress.org/support/plugin/form-maker/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/form-maker/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/form-maker/reviews/)

## Tags

 * [parameters](https://wordpress.org/support/topic-tag/parameters/)

 * 3 replies
 * 2 participants
 * Last reply from: [Zhanna Khachatryan](https://wordpress.org/support/users/zhannak/)
 * Last activity: [6 years, 10 months ago](https://wordpress.org/support/topic/insert-parameters-from-url/#post-11823336)
 * Status: resolved