faqts : Computers : Programming : Languages : PHP

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

7 of 12 people (58%) answered Yes
Recently 6 of 10 people (60%) answered Yes

Entry

How can I pass values (images & text) from a mysql field with php into a javascript script?

Feb 21st, 2007 04:30
Articles Hosting, Matthew Wilkinson, Chukky Nze,


$result = mysql_query("SELECT column FROM table");
$vartopasstojavascript = mysql_fetch_row($result);
echo "<script>var yourvariable = '" . $vartopasstojavascript .
"';</script>";
=====
webdevelopersjournal.com/articles/pass_values.html
i hope that helps:
http://americanahost.com
http://www.qwesz.com