Ok peeps
sorry to keep pestering u lot.
here it goes, can u fire off a function by clicking on a button on a web page. i want to execute a function that performs a sql statement and then displays the result on the same page as where it was executed from.
heres what i tried
function getlocID() {
//connection string
//select database string
sql = "SELECT id from Identities WHERE name = $name"
$sql_result = mysql_query($sql, $connection) or die("Could nt execute query");
$row = mysql_fetch_assoc($sql_result);
$name = $row[0];
return $name;
}