How do I place a PHP variable in this link?........

Discussion in 'PHP' started by karl_murphy, May 12, 2008.

  1. #1
    The following Javascript link opens a popup window:

    <a href="javascript:MM_openBrWindow('skills/integrated/index.htm','Details','scrollbars=yes,width=660,height=440')">

    How would I place a PHP variable within it so it is available on the next page?
     
    karl_murphy, May 12, 2008 IP
  2. Agent_Smith

    Agent_Smith Well-Known Member

    Messages:
    890
    Likes Received:
    43
    Best Answers:
    0
    Trophy Points:
    145
    #2
    Where in that javascript would you like the variable to be placed?
     
    Agent_Smith, May 12, 2008 IP
  3. norfstar

    norfstar Peon

    Messages:
    1,154
    Likes Received:
    62
    Best Answers:
    0
    Trophy Points:
    0
    #3
    I'm assuming here that index.htm is a PHP file:

    <a href="javascript:MM_openBrWindow('skills/integrated/index.htm?variableName=variableValue','Details','scrollbars=yes,width=660,height=440')">
    Code (markup):
    Then in PHP:

    echo $_GET['variableName'];
    Code (markup):
    will output:

    variableValue
     
    norfstar, May 12, 2008 IP