I am trying to create a PHP variable from a database table with only one row and one column. So Basically, I'm trying to pass information within several pages using a database. Is this possible? I have a table called name and a column on it also called name. I only have one row on it, and I would like to select the value of that only field and assign a variable to it. How do I do this? Thanks!
Edit: I have tried:
$name = mysql_query("SELECT * FROM name ORDER BY RAND() LIMIT 0,1");
var_dump($name);
But it returns null.