var sidebar_align = 'right';
var content_container_margin = parseInt('350px');
var sidebar_width = parseInt('330px');
timestamp alternative [mysql/php]
I need to store threads with a post time, and a last post time. Timestamp in MySQL did what I needed, but whenever I update a row, it updates both fields.
What would be a suitable alternative?
Please post the SQL query that you used to update the fields.
Also, in the first field using timestamp the default is NULL, and in the other, the default is 00000000000000.
UPDATE `threads` SET `lastpost`=null WHERE (`id`="'.$parent.'");
TIMESTAMP is auto-updating. You need the DATETIME type.
In order to understand recursion, one must first understand recursion.
If you feel like it, you can read my blog
Signal > Noise
Yeah. I just realized that if I switched the order of the fields with `timestamp` it would work correctly.. apparently only the first one updates.