Code: Select all
function addComment(num){
window.open('addcomment.php?ref=articles_comments&article=num','Add A Comment', 'width=500,height=360,resizeable=no');
}Code: Select all
<a href="javascript:addComment(<?php echo $_GET['doc']; ?>);">Add A Comment</a>http://localhost/public/addcomment.php? ... rticle=num
Which isn't what I want. I need it to have the &article equal the value given to it by the $_GET['doc']. I tried combining PHP and Javascript in the original function, but it didn't work. Is there a way of allowing Javascript to get the GET variables? Better yet, how can I make this method work?