'0'){ $result1 = pg_Exec ($conn, "select * from mboard"); $rows1 = pg_numrows($result1); $id = ($rows1 + 1); } $now = date("F j, Y, g:i:s a"); if ($pic2){ $query4 = "insert into mboard (subject,id,message,name,date,repid,ip,pic) values ('$subject','$id','$message','$name',current_timestamp,'$repid','$REMOTE_ADDR','$pic2_name')"; } else { $query4 = "insert into mboard (subject,id,message,name,date,repid, ip) values ('$subject','$id','$message','$name',current_timestamp,'$repid', '$REMOTE_ADDR')"; } $result = pg_Exec ($conn, "$query4"); if ($pic2 != "none"){ if (@copy($pic2, "/www/htdocs/therock/mboard/pics/$pic2_name")){ } else { echo "There was a problem uploading the picture. That particular filename may already exist. Try renaming the picture and attempt to post again."; } @unlink($pic2); header("Location: mboard.html"); } //end if picture if (!$result) { echo "There was an error, please try again."; echo $message; exit; } header("Location: mboard.html"); } ?>
"; echo "Enter your name:
Enter the subject:
Enter the message:
Image (optional):

"; exit; } ?> '0'){ $result1 = pg_Exec ($conn, "select * from mboard"); $rows1 = pg_numrows($result1); $num = doubleval(9000 + $rows1); $repid = $num; } $now = date("F j, Y, g:i:s a"); if ($pic2 != "none"){ $query4 = "insert into mboard (subject,id,message,name,date,repid,ip,pic) values ('$subject','$id','$message','$name',current_timestamp,'$repid','$REMOTE_ADDR','$pic2_name')"; } else { $query4 = "insert into mboard (subject,id,message,name,date,repid, ip) values ('$subject','$id','$message','$name',current_timestamp,'$repid', '$REMOTE_ADDR')"; } $result = pg_Exec ($conn, "$query4"); if ($pic2){ if (@copy($pic2, "/www/htdocs/therock/mboard/pics/$pic2_name")){ } else { echo "There was a problem uploading the picture. That particular filename may already exist. Try renaming the picture and attempt to post again."; } @unlink($pic2); header("Location: mboard.html"); } //end if picture } ?>
Please fill out the form to submit your message to this message board.
"; echo "Enter your name:
Enter the subject:
Enter the message:
Image (optional): "; echo "
"; ?>