How do you parse post variables to a popup window?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • monomaniac21

    How do you parse post variables to a popup window?

    Hi I know this isnt really a php question but can anyone tell me how
    you parse post variables to a popup window, here's my code so far, im
    trying to pass the value entered into a radio button:

    <head>
    <script language="JavaS cript" type="text/JavaScript">
    var win= null;
    function NewWindow(mypag e,myname,w,h,sc roll)
    {
    var winl = (screen.width-w)/2;
    var wint = (screen.height-h)/2;
    var settings ='height='+h+', ';
    settings +='width='+w+', ';
    settings +='top='+wint+' ,';
    settings +='left='+winl+ ',';
    settings +='scrollbars=' +scroll+',';
    settings +='resizable=ye s';
    win=window.open (mypage,myname, settings);
    if(parseInt(nav igator.appVersi on) >= 4){win.window.f ocus();}
    }
    <!--
    function MM_reloadPage(i nit) { //reloads the window if Nav4 resized
    if (init==true) with (navigator) {if
    ((appName=="Net scape")&&(parse Int(appVersion) ==4)) {
    document.MM_pgW =innerWidth; document.MM_pgH =innerHeight;
    onresize=MM_rel oadPage; }}
    else if (innerWidth!=do cument.MM_pgW || innerHeight!=do cument.MM_pgH)
    location.reload ();
    }
    MM_reloadPage(t rue);
    //-->
    </script>
    </head>

    <body>
    <form name="answer" action="result. php" method="post">
    <input type="radio" name="group1" value="Milk"> Milk<br>
    <input type="radio" name="group1" value="Butter"> Butter<br>
    <input type="radio" name="group1" value="Cheese"> Cheese<br>
    <input type="submit" name="submit" value="submit" src="result.php "
    onClick="NewWin dow(this.src,'n ame','300','300 ','yes');return false" >
    </form>
    </body>

  • Jerry Stuckle

    #2
    Re: How do you parse post variables to a popup window?

    monomaniac21 wrote:[color=blue]
    > Hi I know this isnt really a php question but can anyone tell me how
    > you parse post variables to a popup window, here's my code so far, im
    > trying to pass the value entered into a radio button:
    >[/color]

    (JS and HTML snipped)

    So why ask in a PHP newsgroup then?

    Since it seems to be a javascript question, why not ask in a javascript
    newsgroup?

    --
    =============== ===
    Remove the "x" from my email address
    Jerry Stuckle
    JDS Computer Training Corp.
    jstucklex@attgl obal.net
    =============== ===

    Comment

    • Chung Leong

      #3
      Re: How do you parse post variables to a popup window?

      monomaniac21 wrote:[color=blue]
      > <body>
      > <form name="answer" action="result. php" method="post">
      > <input type="radio" name="group1" value="Milk"> Milk<br>
      > <input type="radio" name="group1" value="Butter"> Butter<br>
      > <input type="radio" name="group1" value="Cheese"> Cheese<br>
      > <input type="submit" name="submit" value="submit" src="result.php "
      > onClick="NewWin dow(this.src,'n ame','300','300 ','yes');return false" >
      > </form>
      > </body>[/color]

      Try this:

      <form name="answer" action="result. php" method="post" target="name">
      <input type="radio" name="group1" value="Milk"> Milk<br>
      <input type="radio" name="group1" value="Butter"> Butter<br>
      <input type="radio" name="group1" value="Cheese"> Cheese<br>
      <input type="submit" name="submit" value="submit" src="result.php "
      onClick="NewWin dow('about: blank','name',' 300','300','yes ');" >
      </form>

      Comment

      Working...