Welcome, Guest
Username: Password: Remember me

TOPIC: [FIXED] Bug on the CREATION DATE / MODIFICATION DATE?!

Bug on the CREATION DATE / MODIFICATION DATE?! 31 Jan 2013 07:39 #6578

  • Tomaselli
  • Tomaselli's Avatar
  • Online
  • Elite Member
  • Posts: 293
  • Thank you received: 87
  • Karma: 46
If I select UNIX time, in the option of the field, the FORMAT data is stored correctly into the DB, BUT the value is WRONG.

the following code (in the model or table, it depends by the config of your component in the jcook builder):
			// New item.
			if (!intval($this->creation_date))
				$this->creation_date = $date->toSql();

and
			// Existing item
			$this->modification_date = $date->toSql();

should be simply replaced with:
			// New item.
			if (!intval($this->creation_date))
				$this->creation_date = time();

and
			// Existing item
			$this->modification_date = time();
The administrator has disabled public write access.

Re: Bug on the CREATION DATE / MODIFICATION DATE?! 31 Jan 2013 08:19 #6582

  • Tomaselli
  • Tomaselli's Avatar
  • Online
  • Elite Member
  • Posts: 293
  • Thank you received: 87
  • Karma: 46
Because then I have to add more code to make it to check if the item is new or old, etc. etc.

But I guess you are replying here to my other post :huh: :

CREATION DATE / MODIFICATION DATE with TIME

Because on this post I'm just saying that if I select an option on the builder, the feature is not working.
The administrator has disabled public write access.

Re: Bug on the CREATION DATE / MODIFICATION DATE?! 31 Jan 2013 08:45 #6583

  • JoomGuy
  • JoomGuy's Avatar
  • Offline
  • Moderator
  • Joomla Enthusiast, Lover of Cooking
  • Posts: 1115
  • Thank you received: 195
  • Karma: 64
Sorry @Tomaselli,

you are correct, I was replying to the other topic, not this one...

Post moved!

G
Need help with your Cook/Joomla Project? . PM me to find out what I can help with. NO time wasters please!!!
The administrator has disabled public write access.

Re: Bug on the CREATION DATE / MODIFICATION DATE?! 07 Aug 2013 16:42 #10713

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 987
  • Karma: 140
Fixed now.

There was still an issue with unix dates.
Coding is now a piece of cake
The administrator has disabled public write access.
The following user(s) said Thank You: Tomaselli
Time to create page: 0.071 seconds

Get Started