i have a page that generate pop up when user click on a link….
the link will call javascript function and pass certain unique value of ‘userID’ to the function. what i am trying to do is to use this userID to differentiate name between one popup windows (childwindows) to another, so i can easily call the child window when needed. i need to detect whether the popup window for certain user has already exist or not….if no more exist, a new pop up window will be displayed whenever the user click on the link again. if the window exist, it just call the existing window to be focus, so there would not be redundant pop up for one user or one userID….
anydoubt pls tell me…thanks alot……
my email : [email][email protected]
i have try the following code, but it keep prompting error :
<script language=”JavaScript”>
var popwindow_private = null;
function private_chat(parameter)
{
var userID = parameter;
// display the popup
var popwindow_privateChat = popwindow_private + userID;
if(popwindow_privateChat == userID)
{
popwindow_private = “Value”;
popwindow_privateChat = window.open(‘private_chat.php?recepientID=’ + userID, ‘_blank’,’width=650,height=450,resizable=no,toolbar=0,menubar=0,status=0,location=0,top=50,left=300′);
}
else
{
popwindow_privateChat.focus();
}
}
</script>
<a href= “javascript:void(0)” onClick=”private_chat($userID);”>Start to Chat<br></a>”;
if there is other way to do this pls let me know also…thnks again~~~