onmouseover question?

Discussion in 'PHP' started by ram741, Jun 24, 2010.

  1. #1
    Hello,

    I have a code for embeding a video clip , when you click on the video it takes you to host website with a url that keep changing every 2days or so . so my question is . is there a way I can get the mouse to click on the video when it's over the video frame .
    example: I am trying to use this code:
    <script language="javascript" type="text/javascript">
    
    var win=null;
    function NewWindow(mypage,myname,w,h,scroll,pos){
    if(pos=="random"){LeftPosition=(screen.width)?Math.floor(Math.random()*(screen.width-w)):100;TopPosition=(screen.height)?Math.floor(Math.random()*((screen.height-h)-75)):100;}
    if(pos=="center"){LeftPosition=(screen.width)?(screen.width-w)/2:100;TopPosition=(screen.height)?(screen.height-h)/2:100;}
    else if((pos!="center" && pos!="random") || pos==null){LeftPosition=0;TopPosition=20}
    settings='width='+w+',height='+h+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=no';
    win=window.open(mypage,myname,settings);}
    // -->
    </script>
    
    [COLOR="red"]<a href="http://localhost/pop.php" onmouseover="NewWindow(this.href,'mywin','22','22','no','center');return false" onFocus="this.blur()">[/COLOR]YourLinkText</a>
    Code (markup):
    but this doesn't work since I can't assign 1 fixed url " it keeps changing " ...if possible this code without assigning the " <a href="http://localhost/pop.php" part.


    thank you , i hope this is clear enough
     
    ram741, Jun 24, 2010 IP
  2. clox.c

    clox.c Peon

    Messages:
    30
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #2
    can't you assign the changing part to a variable?
     
    clox.c, Jun 24, 2010 IP
  3. ram741

    ram741 Peon

    Messages:
    3
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    -------------------------------------------------
     
    ram741, Jul 9, 2010 IP