title: how to use quotes in php code with html tags
body: <p>Hi i want to use html code in php while command that generates html codes in every loop but i don't know how to use quotes in php code to send true values to java script!<br>
  this is my code in php  </p>
  
  <pre><code>&lt;?php
  include 'Connect.php'; 
  if(match($_POST['pId'], "/^[\d]+$/") ){
  $pId = $_POST['pId'];
  $result = mysql_query("select pName, pID, phName, phID, testHistoryDate, type, testAnswer from patient join reception using(pID) join physician using(phID) join testHistory using(rID) join test using(tID) where pID = $pId",$connection);
  }
  else
  die("Insert true value");
  while($row=mysql_fetch_array($result)){
  echo "&lt;tr&gt;&lt;td&gt;";
  echo $row["pName"].'&lt;/td&gt;';
  echo '&lt;td&gt;'.$row["phName"].'&lt;/td&gt;';
  echo '&lt;td&gt;'.$row["testHistoryDate"].'&lt;/td&gt;';
  echo '&lt;td&gt;'.$row["type"].'&lt;/td&gt;';
  $type =  $row['type'];
  $testHistoryDate = $row['testHistoryDate'];
  ?&gt;
  &lt;td&gt;
  &lt;span id='spryTanswer'&gt;
  &lt;input type='text' name='tAnswer' id='tAnswer' value='&lt;?php echo $row['testAnswer']; ?&gt;' /&gt;
  &lt;/span&gt;
  &lt;/td&gt;
  &lt;td&gt;
  &lt;input type='submit' value='Edit' name='edit' id='edit' onclick="sendToEdit('&lt;?php echo $row['pID'] ?&gt;','&lt;?php echo $row['phID'] ?&gt;', '&lt;?php echo $row['testHistoryDate'] ?&gt;', '&lt;?php echo $row['type'] ?&gt;')" /&gt;
  &lt;/td&gt;
  &lt;/tr&gt;
  &lt;?php } ?&gt;
  </code></pre>
  
  <p>java script code that get these values and send themes to another php code.  </p>
  
  <pre><code>&lt;script type="text/javascript" src="jquery.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript"&gt;
  function sendToEdit(pID,phID,thDate,type) 
  {
  testAnswer = $("#tAnswer").blur().val();
  testAnswer = $("#tAnswer").change().val();
  var info = 'pId='+pID+'&amp;phId='+phID+'&amp;testAnswer='+testAnswer+'&amp;thDate='+thDate+'&amp;type='+type;
  $.ajax({
  type:"GET",
  url:"edit-testAnswer.php",
  data:info,
  success:function(){
  }
  });
  return false;
  }
  &lt;/script&gt;
  </code></pre>