pocobueno1388
Members-
Posts
3,369 -
Joined
-
Last visited
Never
Everything posted by pocobueno1388
-
What are you trying to change? If you updated something via the database, it should have gone through.
-
Updating multiple fields in a db with one query.
pocobueno1388 replied to refiking's topic in PHP Coding Help
Did you actually try to execute the query with mysql_query()? Try this: <?php $change = "UPDATE gatable SET (r1g1,r1g2,r1g3,r1g4,r1g5,r1g6,r1g7,r1g8,r1g9,r1g10,r1g11,r1g12,r1g13,r1g14,r1g15,r1g16) VALUES ('$r1g1','$r1g2','$r1g3','$r1g4','$r1g5','$r1g6','$r1g7','$r1g8','$r1g9','$r1g10','$r1g11','$r1g12','$r1g13','$r1g14','$r1g15','$r1g16')"; $result = mysql_query($change)or die(mysql_error() . "<p>With Query $change"); ?> Copy and paste the error if you get one. -
Have a quick look! Fire Performers Web Site
pocobueno1388 replied to Fearpig's topic in Website Critique
The layout isn't very appealing at all, it just looks like someone threw it together. It passes as usable, but it isn't amazing or anything. -
Honestly, I think it needs a whole new layout. A site like this isn't going to be as successful without a professionally made design thats appealing.
-
In my opinion it is way way too simple. You need to add some CSS in there to spice it up. There is so much more you can do and still achieve the "simple" look. The current design is just completely unappealing.
-
Can you select and insert at the same time.
pocobueno1388 replied to EchoFool's topic in PHP Coding Help
You need to use mysql_insert_id(). So try: <?php $UPDATE2 = mysql_query("INSERT INTO posts (Postmessage,postedby,CreatedOn,ThreadID) VALUES ('$Post','{$_SESSION['Current_User']}','$Date', mysql_insert_id())")or die(mysql_error()); -
Which means you are going to have to put backsticks around the word "update" as well.
-
You still didn't add the die statement to the end of your query...that is what is going to give you the error you need. mysql_query($sql)or die(mysql_error() . "<p>With Query<br>$sql");
-
I didn't even catch the "date" field. You can put backsticks (`) around it and it will be fine. $sql = "INSERT INTO `updates` (`date`, update) VALUES ('$date', '$updatecontent')";
-
Try: SELECT * FROM food WHERE id=$user->ID AND item_name='apple' LIMIT 1
-
You need to try and catch the error at the end of your query: mysql_query($sql)or die(mysql_error());
-
Thats strange, after the "With Query:" part it was supposed to show your query, and it came out blank...unless you left that part out. to clean a variable for database insertion you want to use mysql_real_escape_string() on it. It will probably solve your problem if you do that to all the variables.
-
Do this and copy and paste what you see: <?php $sql = "UPDATE Profiles SET City = '$row[city]', Headline = '$row[name]', LookingFor = '$lf', DescriptionMe = '$desc', DateOfBirth ='$bd', Zip= '$row[zipcode]' WHERE ID='$row[member_id]'"; $result = mysql_query($sql)or die(mysql_error() . "<p>With Query:<br>$query");
-
The error being?
-
Data truncated at first space in input box
pocobueno1388 replied to cotarider's topic in PHP Coding Help
They said if they echo it in another place in the script they get the full value, so I don't think thats the problem. -
Data truncated at first space in input box
pocobueno1388 replied to cotarider's topic in PHP Coding Help
Do you have a character restriction on your input box? -
You keep forgetting to press solved, lol ;P
-
It's because this site filtered out the closing of the link code. Change it to this: echo "You must <a href=\"$variable4\">Click Here To Go To The Lodge Website</a> to view this page";
-
All you need to do is use double quotes echo "You must <a href=\"$variable4\">Click Here To Go To The Lodge Website[/url] to view this page";
-
Yes, you can. Here is an example: <?php $table = "table_name"; $query = mysql_query("SELECT * FROM $table")or die(mysql_error()); ?> Make sure you have that or die(mysql_error()) at the end of your query.