Things I find strange:$postID = $_POST[postID]
postID ?? do you mean $postID? or is it a constant defined in one of the include files? or were you after $_POST['postID']??
$stop = "TRUE"
uhh Ii think your looking for "$stop = true" there. Also you never initialized that value to false, so just to be on the safe side, add $stop = false at the begining of your code
$result_row = mysql_fetch_array( ..... $a = $result_row["title"]
You're looking for mysql_fetch_assoc there, not fetch_array
if ($_GET[postID]
This is not a really reliable form of testing, when the input is of a mixed type you really would want to do some kind of more presiced testing than that
Most of your MySQL queries
you would want ` quotes around column & table names to imply they're literals and not commands of the query language
All of those echo lines
You can make things faster by getting rid of those extra echos, the below is perfectly valid and can be expanded to any arbitary lines:
CODE
echo('something '.$somevar.' more stuff '.
'other stuff);
About $userIDWhere did you define it? cause its certainly not on the code you've pasted. So from a logical perspective, if its not defined in one of those 2 included files, then it shouldn't have a value...
About $categoryIDI am not exactally sure about this one. But logically if it's not setting to what you've expected, it is that something with your form screwed up. Try using print_r() on the $_POST variable to see what is actually passed and if you've misspelled anything