I have some code where my site members are having some real trouble. It seems for most of them this doesn't add the info into the database, but for a lower percentage it does.
The problem is also, both of my test machines it works, so I can't figure it out. Perhaps someone here can help?
Here is a code snippet:
Code: Select all
$connection = mysql_connect($dbhost, $dbusername, $dbpassword);
// if the user filled in all the fields then go ahead
if ($_POST['animator'] AND $_POST['title'] AND $_POST['hardware'] AND $_POST['software'] AND $_POST['creationtime'] AND $_POST['rendertime']
AND $_POST['viewrecommend'] AND $_POST['descriptionofcreation'] AND $_POST['animdescription'] AND $_POST['forum_uid'] AND $_POST['new_id'])
{
$animator = stripslashes($_POST['animator']);
$title = stripslashes($_POST['title']);
$hardware = stripslashes($_POST['hardware']);
$software = stripslashes($_POST['software']);
$creationtime = stripslashes($_POST['creationtime']);
$rendertime = stripslashes($_POST['rendertime']);
$viewrecommend = stripslashes($_POST['viewrecommend']);
$descriptionofcreation = stripslashes($_POST['descriptionofcreation']);
$animdescription = stripslashes($_POST['animdescription']);
$forum_uid = stripslashes($_POST['forum_uid']);
$new_id = stripslashes($_POST['new_id']);
$sound_id = stripslashes($_POST['sound_id']);
$sound_year = stripslashes($_POST['sound_year']);
$sound_month = stripslashes($_POST['sound_month']);
$mpgfilename = "$forum_uid".".mpg";
$jpgfilename = "$forum_uid".".jpg";
echo "$animator<br>";
echo "$title<br>";
echo "$hardware<br>";
echo "$software<br>";
echo "$creationtime<br>";
echo "$rendertime<br>";
echo "$viewrecommend<br>";
echo "$descriptionofcreation<br>";
echo "$animdescription<br>";
echo "$forum_uid<br>";
echo "$new_id<br>";
echo "<br>Mpg filename will be: $mpgfilename";
echo "<br>Jpg filename will be: $jpgfilename<br>";
$Add = mysql_db_query ($dbname, "INSERT INTO current VALUES ('$forum_uid', '$forum_uid', '$sound_year', '$sound_month', '$new_id', '$title', '$animator', '$hardware', '$software', '$creationtime', '$rendertime', '$viewrecommend', '$animdescription', '$descriptionofcreation', '0', '$mpgfilename', '$jpgfilename', '0', '0', '0')");
echo "<br />Your text information has been added to the database, it's time to upload the JPG thumbnail image.<br />";
echo "Click the button to continue to the next page. There you will be able to upload your JPG and edit anything you've already typed in.";
}