<script> jQuery(document).ready(function($) { $.urlParam = function (name) { var results = new RegExp('[?&]' + name + '=([^&#]*)') .exec(window.location.search); return (results !== null) ? results[1] || 0 : false; } console.log($.urlParam('id')); //registration console.log($.urlParam('email')); //bobo@example.com var email = decodeURI($.urlParam('email')); var replaced = email.replace("%40", "@"); var type = decodeURI($.urlParam('type')); var replaced2 = type.replace("+", " "); $("#wpforms-2228-field_0").val($.urlParam('id')); $("#wpforms-1770-field_4").val(replaced); $("#wpforms-1770-field_6").val("Suite a votre demande de devis nous vous prions de trouver ci joint notre proposition de tarif pour '" + replaced2 + "'.... "); }) </script>
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter