Any idea why this tag {DATE_ARTICLE} won't work?

Get help with installation and running phpwcms here. Please do not post bug reports or feature requests here.
Post Reply
indaype
Posts: 11
Joined: Tue 17. Apr 2007, 16:08

Any idea why this tag {DATE_ARTICLE} won't work?

Post by indaype »

Any idea why this tag {DATE_ARTICLE} won't work?

I created a .tmpl file under this directory template/inc_cntpart/articlesummary/list/ but it doesn't seem to work. I mean it shows the date and all but it shows not the actual date when the article was created. My site looks so funny! It has 3 articles with the same freaking dates. Did I do something wrong?

Also, how do you modify the date based on the country you're in? ... particularly GMT + 8:00 :roll:

Any help from you pro's would be greatly appreciated!
User avatar
DeXXus
Posts: 2168
Joined: Fri 28. Nov 2003, 06:20
Location: USA - Florida

Re: Any idea why this tag {DATE_ARTICLE} won't work?

Post by DeXXus »

indaype wrote:Any idea why this tag {DATE_ARTICLE} won't work?

I created a .tmpl file under this directory template/inc_cntpart/articlesummary/list/ but it doesn't seem to work. I mean it shows the date and all but it shows not the actual date when the article was created.
That tag is the equivalent of "Last Modified". If you create an article and never change it...it will remain what you are referring to (ie. creation date) BUT, if you, subsequently EDIT that article (or even just re-save it without making any changes) ...you have (in effect) updated that article and thusly, the new date is stored with the content in the database.

indaype wrote:Also, how do you modify the date based on the country you're in? ... particularly GMT + 8:00 :roll:
How about whenever you create or edit an article that you set the start date to the previous day. Wouldn't that do it? It's a LOT easier than trying to figure the number of hours difference. It's obvious you can't make a database server (that is 8 hrs behind your time) change it's timekeeping method or basis, right... and maybe it's not practical to atttempt to code some geo-IP solution that would compensate for time difference? Dunno
indaype
Posts: 11
Joined: Tue 17. Apr 2007, 16:08

Post by indaype »

I guess...this can't be helped? :(
Pappnase

Post by Pappnase »

hallo

please look into the template. then you will see wich tags work an wich not :wink:

sample.tmpl

Code: Select all

DATE        = show article date {DATE:FORMAT:LANG} or {DATE:FORMAT}
->

Code: Select all

[SPACE]<hr />[/SPACE]
<div>
	<table cellspacing="0" cellpadding="0" border="0" width="100%" summary="">
		<tr>
			<td width="150" valign="top">
				[IMAGE]<div><a href="{ARTICLELINK}">{IMAGE}</a></div>[/IMAGE]
				[CAPTION]<div align="center">{CAPTION}</div>[/CAPTION]
			</td>
			<td width="10"><img src="img/leer.gif" border="0" width="10" height="1" alt="" /></td>
			<td width="98%" valign="top">
				[TITLE]<h1 style="margin:0 0 5px 0;">{TITLE}</h1>[/TITLE]
				[SUB]<h3 style="margin:0 0 5px 0;">{SUB}</h3>[/SUB]
				[SUMMARY]<p style="margin:0"><strong>{DATE:F:DE}</strong> {SUMMARY}</p>[/SUMMARY]
				[MORE]<a href="{ARTICLELINK}">{MORE}</a>[/MORE]
			</td>
		</tr>
	</table>
</div>
johnn
Posts: 50
Joined: Mon 10. Apr 2006, 14:07

Post by johnn »

So how can we show the date the article was created (or the start date), but not last edited :(
Pappnase

Post by Pappnase »

hello

maybe this is teh right for you :-)

http://www.phpwcms-docu.de/add_on_repla ... s_en.phtml
johnn
Posts: 50
Joined: Mon 10. Apr 2006, 14:07

Post by johnn »

Pappnase wrote:hello

maybe this is teh right for you :-)

http://www.phpwcms-docu.de/add_on_repla ... s_en.phtml
Exactly, thanks :) But why can't I use it in article listing template?
It only works in article summary template.
johnn
Posts: 50
Joined: Mon 10. Apr 2006, 14:07

Post by johnn »

? anyone?
User avatar
DeXXus
Posts: 2168
Joined: Fri 28. Nov 2003, 06:20
Location: USA - Florida

Post by DeXXus »

johnn wrote:? anyone?
Probably, because that particular coding was devised a LONG time ago as an unsupported (by the phpWCMS author) set of addon replacement tags. The templating system evolved later on and support for defining the WAK tag usage (in templates) AND support for parsing those WAK tags in the templates did not get implemented.
johnn
Posts: 50
Joined: Mon 10. Apr 2006, 14:07

Post by johnn »

So, there is no way to use the creation date in templates? :?
I find it hard to believe :)
dellos
Posts: 67
Joined: Thu 25. Jan 2007, 18:18

Re: Any idea why this tag {DATE_ARTICLE} won't work?

Post by dellos »

I have still the same problem in 1.4.5 is there some solution ?? Why the date changing form creation date to editon date ??
User avatar
flip-flop
Moderator
Posts: 8178
Joined: Sat 21. May 2005, 21:25
Location: HAMM (Germany)
Contact:

Re: Any idea why this tag {DATE_ARTICLE} won't work?

Post by flip-flop »

Please have a look to:

Code: Select all

Livedate: {LIVEDATE:d.m.Y H:i:s lang=EN} / Killdate: {KILLDATE:d.m.Y H:i:s lang=EN}
Knut
>> HowTo | DOCU | FAQ | TEMPLATES/DOCS << ( SITE )
dellos
Posts: 67
Joined: Thu 25. Jan 2007, 18:18

Re: Any idea why this tag {DATE_ARTICLE} won't work?

Post by dellos »

Where to find it ?? And what to do wyth it ?? :)
User avatar
flip-flop
Moderator
Posts: 8178
Joined: Sat 21. May 2005, 21:25
Location: HAMM (Germany)
Contact:

Re: Any idea why this tag {DATE_ARTICLE} won't work?

Post by flip-flop »

Please have a look into your article list- and summary template.
>> HowTo | DOCU | FAQ | TEMPLATES/DOCS << ( SITE )
Post Reply