Basically it's just a notice. It still works but it is expecting the 2 values to pass from the previous page.

I believe it works when you hit the "Send feedback!" button and the error appears only when you first load the page.

You can add some kind of validation or a check if anything is submitted before you run line 17 to line 25.

You can try the following:

         $file = "shouts.txt";
  <form action="<?php echo $_SERVER["PHP_SELF"]; ?>" method="post">
    <input type="text" value="Gamernick" name="input_name" /><br />
    <input type="text" value="Suggestion/Feedback" name="input_text" /><br />
    <input type="submit" value="Send Feedback!" />
<hr />
  //insert new shout
  if ($_POST) {
      $input_name = $_POST["input_name"];
      $input_text = $_POST["input_text"];
      //check if form has been submitted
      if(isset($input_name) && isset($input_text) && $input_name!="Your name" && $input_text!="Your text" && strlen($input_name)>0 && strlen($input_text)>0){
        $handle = fopen($file,"a"); //open shouts file to write (append)
        fputs($handle,"$input_name|||||$input_text\n"); //insert name and shout
        fclose($handle); //close file handle

probably the $_POST['option'] comes back as a string.
change line 4 to

if (strcasecmp($a, "true")==0)

or simply echo $a and see what's the value and recreate the if-else statement.

Line 37: UPDATE not UPTADE

Yea. All you did was collecting the data input. Additional resources on mail() @

I think you can do it with

[CODE]mysql_query("UPDATE sales_roadshow1 SET evnt_title = '$this_event_title' WHERE evnt_id = '$this_event_id'");[/CODE]

Care to try this..?


var myImages = new Array("", "", "", "", ""); var i = 0; function ChangeImage() { i++; if(i == myImages.length) { i = 0; } document.getElementById("main").innerHTML = myImages[i] } - - - -


Changes in line 2, 14 and 18.

I don't quite understand in regards to the two way comms you mentioned.

function getHTTPObject() {
if (typeof XMLHttpRequest != 'undefined') {
return new XMLHttpRequest();
try {
return new ActiveXObject('Msxml2.XMLHTTP');
} catch (e) {
try {
return new ActiveXObject('Microsoft.XMLHTTP');
} catch (e) {}
return false;

var http = getHTTPObject();'POST', ''+value1+'&key2='+value2, true);

You can do the checking in the SQL statement itself.

Change $username and $email to the $_POST variable names you are using.
And change the column names or table name if they are different

$SQL = mysql_query("SELECT Username, Email from user WHERE Username = '$username' OR Email = '$email'");

if(mysql_num_rows($SQL) >= 1)
echo ("$Username and/or $Email already exist/used");

You may want to test the SQL statement externally to debug..