Created
April 15, 2017 03:35
-
-
Save matthewholliday/e6b3ef65c51ff65f01e126562d26fcac to your computer and use it in GitHub Desktop.
concatenate hidden input value with url
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<script type='text/javascript'> | |
function clickyClick() { | |
url = 'https://cei.org' + document.getElementById("contactid").value; | |
//cei.org used here for example | |
window.open(url, '_blank'); | |
} | |
</script> | |
</head> | |
<body> | |
<!-- Use hidden input instead of form --> | |
<input type="hidden" name="contactid" id="contactid" value="%%fieldname%%"/> | |
<br> | |
<button onclick="clickyClick()">Get Link</button> | |
</body> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment