killer_t
11-18-2011, 10:36 PM
Hello!
I need to split the date format in cms article, for article publish date.
I especially need the day and the month divided, how can i put this?
To explain myself well, i have to put the day in <div></div> ad month in and another <div></div>
Thank you!
--------------- Added 1321718186 at 1321718186 ---------------
Ok, get it!
Go to root of your site --> packages --> vbcms --> content --> article.php
at line 786 after
$view->publishdatelocal = vbdate(vB::$vbulletin->options['dateformat'], $this->content->getPublishDate());
add
$view->publishdatelocalday = vbdate(j, $this->content->getPublishDate());
$view->publishdatelocalmonth = vbdate(F, $this->content->getPublishDate());
$view->publishdatelocalyear = vbdate(Y, $this->content->getPublishDate());
Now in your template you can add with some style in additional.css:
{vb:raw publishdatelocalday} or/and {vb:raw publishdatelocalmonth} or/and {vb:raw publishdatelocalyear}
You can edit the format of day - month - year changing the code j F Y with this rules (http://php.net/manual/en/function.date.php)
Demo : AppleMod - Home (http://www.applemod.com/)
Like this : https://vborg.vbsupport.ru/attachment.php?attachmentid=134527&stc=1&d=1321718625
ENjoy!:up:
I need to split the date format in cms article, for article publish date.
I especially need the day and the month divided, how can i put this?
To explain myself well, i have to put the day in <div></div> ad month in and another <div></div>
Thank you!
--------------- Added 1321718186 at 1321718186 ---------------
Ok, get it!
Go to root of your site --> packages --> vbcms --> content --> article.php
at line 786 after
$view->publishdatelocal = vbdate(vB::$vbulletin->options['dateformat'], $this->content->getPublishDate());
add
$view->publishdatelocalday = vbdate(j, $this->content->getPublishDate());
$view->publishdatelocalmonth = vbdate(F, $this->content->getPublishDate());
$view->publishdatelocalyear = vbdate(Y, $this->content->getPublishDate());
Now in your template you can add with some style in additional.css:
{vb:raw publishdatelocalday} or/and {vb:raw publishdatelocalmonth} or/and {vb:raw publishdatelocalyear}
You can edit the format of day - month - year changing the code j F Y with this rules (http://php.net/manual/en/function.date.php)
Demo : AppleMod - Home (http://www.applemod.com/)
Like this : https://vborg.vbsupport.ru/attachment.php?attachmentid=134527&stc=1&d=1321718625
ENjoy!:up: