TimeStamp Column Problem...


Posted on 16th Feb 2014 07:03 pm by admin

I'm mad at my self and thinking I'm a little retarded. It just be some one mistake I'm missing here. I coded my self a forum, when you reply to a topic, the topic's TimeStamp column is supposed to be updated to the current timestamp. However I attempted and failed.

I put the timestamp column on "ON UPDATE CURRENT TIMESTAMP", I set the column to NULL but seems to be at the same value. The column isn't null. I don't know if I should or shouldn't do that. I'm a complete newbie at MySql(~1Month).

Code: $sql = mysql_query("UPDATE `threads` SET `last_post_user_id` = '$id', `time` = 'NULL'; WHERE `id` = '$forum_id'");

Thanks

No comments posted yet

Your Answer:

Login to answer
65 Like 22 Dislike
Previous forums Next forums
Other forums

what are '%S%', '%E%'
for example when i see Code: [Select]printf("Hello %srn", $name);
what does %s means

PHP mail() rejected by SMTP
I'm currently working on a newsletter application which is installed on a windows 2003 server runnin

Change snippet to use CURDATE
I am using time() in the snippet below, I would like to use CURDATE() and have the database setup fo

Using Windows message as a Handle
Hi,

I am writing one of my first multithreaded programs.

In one of the thread,

phpMailer not working ..........
HI,
I was playing with the phpMailer script and tried to send a smiple mail using their test scri

echo $rows help
Hi all,

Hopefully something simple that I don't know!

I have this:

Code: [Selec

Captcha problem users just refresh and it will let them auto submit again
Users will just re submit and not have to enter the new captcha.. ? Lol but if i refresh the page, t

storing results of a function - previous result overwritten with new result
I have created a function to validate input.

function validate_dimension($value,$name) {
<

Help with Password Encoding/Decoding?
Trying to design a "change password" tool. On my signup code I'm using base64_encode, now

What makes a script your own?
If someone finds a login script online, and changes some variable names around and some other minor

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash