DragonPrime - LoGD Resource Community
Welcome Guest
  • Good morning, Guest.
    Please log in, or register.
  • November 18, 2018, 02:54:41 AM
Home Forums News Downloads Login Register Advanced Search
* * *
DragonPrime Menu
Resource Pages

Pages: [1]   Go Down
Author Topic: commentary question  (Read 2154 times)
0 Members and 1 Guest are viewing this topic.
Global Moderator
Mod God
Offline Offline

Posts: 4647

Be aware of the squirrel!

View Profile WWW
« on: January 27, 2005, 08:35:39 AM »


I manually want to insert a commentary. No problem.
$sql = "INSERT INTO commentary (`section`, `author`, `comment`, `postdate`) VALUES ('".$section."', '". $session[user][acctid] ." ', ':does this and that', NOW());";
the comment gets inserted without any real problems...

But, when using relative timestamps it shows this in the commentary section I posted:
(17h21m) <dKT> Admin XChrisX says, "test"

It was exactly 5:21 PM when I posted that... So, what's wrong?? Do I have to use the PHP-date function insted of the SQL?

Running for more than three years now:
iMod God
SVN Users
Mod God
Offline Offline

Posts: 3458

If ya didn't get it by now... you're hopeless...

View Profile WWW
« Reply #1 on: January 27, 2005, 09:54:19 AM »

Your syntax is out of order... I believe...

$sql ="INSERT INTO ".db_prefix("commentary")." (postdate,section,author,comment) VALUES (now(),'".$texts['section']."','".$session['user']['acctid']."',':does this and that'")";

Try to change that around. If not, something may be fishy.

If you didn't understand anything in the above post, don't try to attempt anything suggested.

Pages: [1]   Go Up
Jump to:  

DragonPrime Notices
Play LoGD on Dragonprime

Support Us
No funds raised yet this year
Your help is greatly appreciated!
Recent Topics
DragonPrime LoGD
Who's Online
45 Guests, 0 Users
Home Forums News Downloads Login Register Advanced Search