i need a very small basic help:)
Posted: Wed Sep 20, 2006 2:31 pm
hawleyjr | Please use
and its not working , who can help me fixing it ? (seems its not understanding the "mysql_fetch_array" and i dont know php to fix it .. i just want to pring this:s anyone can help?
HawleyJR: Please Review our forum rules!
hawleyjr | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
i just want to print on a page something that is found in my database, i usedCode: Select all
define("LOG_USERNAME","root");
define("LOG_PASSWORD","*****");
define("DBname","sql_tables");
mysql_connect("localhost","root","*****");
mysql_select_db(DBname);
$query = "SELECT UserName, CustID, Email FROM customer WHERE UserName=a";
$result = mysql_query($query);
while($row = mysql_fetch_array($result, MYSQL_ASSOC))
{
echo "Name :{$row['UserName']} <br>" .
"Subject : {$row['CustID']} <br>" .
"Message : {$row['Email']} <br><br>";
}and its not working , who can help me fixing it ? (seems its not understanding the "mysql_fetch_array" and i dont know php to fix it .. i just want to pring this:s anyone can help?
HawleyJR: Please Review our forum rules!
hawleyjr | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
[quote="[url=http://forums.devnetwork.net/viewtopic.php?t=30037]Forum Rules[/url] Section 1.1"][b]2.[/b] Use descriptive subjects when you start a new thread. Vague titles such as "Help!", "Why?" are misleading and keep you from receiving an answer to your question.[/quote]
[quote="[url=http://forums.devnetwork.net/viewtopic.php?t=30037]Forum Rules[/url] Section 1.1"][b]1.[/b] Select the correct board for your query. Take some time to read the guidelines in the sticky topic.[/quote]