I have a URL that looks like
https://go.feeds4.com/merchants/?pid=1676&mid=4261
How do I pass this as a function parameter. I am trying to pass the value but not able to get anything in the function.
Does the & in query paramter cause issues?
HTML
<a href="javascript:;"
onclick=rendernewmodal(<?php echo '"'.htmlspecialchars_decode($merchant->affiliate_link).'"'; ?>);>
<i class="fa fa-angle-right" aria-hidden="true"></i>
</a>
On View Page Source, I can see the following
<a href="javascript:;"
onclick=rendernewmodal("https://go.feeds4.com/merchants/?pid=1676&mid=4261");>
JS
function rendernewmodal(url) {
alert (url);
}
I don't see any alert showing value of the URL. Please help.
" ".