title: window.open for printing and call a field through database
body: <p>sorry I have no specific title for this problem,</p>
  
  <p>I want to print a form with window.open method and this is some piece of script :</p>
  
  <pre><code>&lt;?php
  include "connect.php";
  
  $test = mysql_query("select * from dataorder order by idorder desc limit 1 ");
  
  
  if (!test)
  die ("Error... " .mysql_error());
  
  while ($row = mysql_fetch_array ($test))
  {
  echo "ID number   : $row[idorder] &lt;br/&gt;&lt;br/&gt;";
  echo "Name        : $row[name] &lt;br/&gt;&lt;br/&gt;";  
  echo "&lt;div&gt;";
  echo "&lt;input  type=button name=back    value='back'onClick='parent.location='reserve.php''&gt;";   
  echo '&lt;input  type="submit"
            class="btn btn-success"
            name="print" value="print"
         onClick="window.open("print.php?idorder="'.$row['idorder'].'","scrollwindow","top=200,left=350,width=680px,height=500")" 
          style="text-decoration:none"&gt;';
  echo "&lt;/div&gt;";
  }
  ?&gt;
  </code></pre>
  
  <p>the "print" button can appear but no response when clicked.</p>