Hello I would like any help at all given. I'm updating information in a mysql database with php 4 using this code
<?php
include "dbvar.php";
$id = $_POST[news_id];
$title = $_POST[news_title];
$date = $_POST[news_date];
$content = $_POST[news_content];
$connect = mysql_connect($dbcon[host],$dbcon[user],$dbcon[pass])
or die(mysql_errno().": ".mysql_error());
mysql_select_db($dbcon[name]);
$query = "UPDATE $dbtable[news]
SET news_title = '$title', news_date = '$date', news_content = '$content'
WHERE news_id = '$id';";
$result = mysql_query($query)
or die(mysql_errno().": ".mysql_error());
$content = "News updated successfully.<br><a href=\"admin?page=c\">BACK TO RADIO SCHEDULE</a>";
?>
As it is there is no error, it displays the $content var and that's it. For what ever reason it wont update the information being posted to it through a form. i've tried to take out the '' around the variables but i get an error saying that i should check what the proper syntax near news_title = $title, news_date = $date, news_content = $content
Thank you for your help
Iquil