Hi i want to send data from php code to JavaScript and JavaScript code send themes to another php file like below:
<td>
<input type="submit" value="Edit" name="edit" id="edit"
onclick="sendToEdit(
<?php echo $row['pID']?>
,<?php echo $row['phID']?>
,<?php echo $testHistoryDate ?>
,<?php echo (string)$type ?>);"/>
when i debug with firebug i see php code make true values in the php area but when send themes to JavaScript can't send
<?php echo $testHistoryDate ?>,<?php echo (string)$type ?>);
true values and send another date for testHistoryDate
and true value for (string)$type
but fire bug make below error:
Phibrinozhen is not defined
[Break On This Error]
sendToEdit(9004, 119002, 1997, Phibrinozhen);
in the above code 1997
isn't true value
true value is:
onclick="sendToEdit(9004,119002,2010-10-03,Phibrinozhen);"
that php make but JavaScript JavaScript code
function sendToEdit(pID,phID,thDate,type)
Java
andJavaScript
are the same language and writingJavaScript
with 2 separate words...