Erstellungsdatum des Artikels falsch

If you've problems with unsupported - non official ;-) - functionalities use this forum please.
Post Reply
Posts: 33
Joined: Thu 7. Dec 2006, 22:10
Location: Düren, Germany

Erstellungsdatum des Artikels falsch

Post by digidotter » Wed 4. Jul 2007, 22:43

Ich nutze den RT {WAK_ARTICLE_CREATED:SHORT} in einem Template, welches das Erstellungsdatum von Artikeln in einem Teaser-Content ausgeben soll. Leider wird nicht das Erstellungsdatum dieses jeweiligen Artikels ausgegeben, sondern das Erstellungsdatum des Artikels, in welchem der CP Teaser liegt. Das ist recht unerquicklich, da dann überall das gleiche Datum steht und es mit dem eigentlichen Beitrag nichts zu tun hat.
Kann jemand helfen? :?:
Der Tag hat 24 Stunden, deshalb schlafe in der Nacht!

User avatar
Oliver Georgi
Site Admin
Posts: 9482
Joined: Fri 3. Oct 2003, 22:22
Location: Dessau

Post by Oliver Georgi » Sun 8. Jul 2007, 08:51

dies gehört hier nicht rein, da kein offizieller RT. Also an den Autor wenden und im Hacks Bereich nachfragen.


Last edited by Oliver Georgi on Sun 8. Jul 2007, 13:20, edited 1 time in total.
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Kleintierpraxis am Georgengarten

Posts: 168
Joined: Sat 6. Nov 2004, 15:29
Location: Duesseldorf near Cologne ;-)

Post by kubens » Sun 8. Jul 2007, 13:14

I had not expected that anybody is still using this RT :lol: I checked your issue. If you have the article id then you can use the the RT inside a teaser template:

Code: Select all

But as far as I was able to point out the article id is not available. I personally do not like to modify original source, because this will prevent that you can update to next versions by a simple mouse click. However you can achieve this by a little enhancement of the original source which I checked in a fresh installed 1.3.3 and it works.


Code: Select all

// line 218
$content['alink']['tr'][$key]	= str_replace('{ARTICLELINK}', 'index.php?aid='.$row['article_id'], $content['alink']['tr'][$key]);

// add this line  
$content['alink']['tr'][$key]	= str_replace('{ARTICLEID}', $row['article_id'], $content['alink']['tr'][$key]);

Code: Select all

<div style="margin:15px 0 15px 0;background-color:#E6E9F0;padding:7px;width:250px;">

		<h3>{WAK_ARTICLE_CREATED:SHORT:{ARTICLEID}}:<a href="{ARTICLELINK}">{TITLE} &raquo;</a></h3>
		[IMAGE]<div style="float:left; margin:2px 5px 2px 0">{IMAGE}[CAPTION]<p>{CAPTION}</p>[/CAPTION]</div>[/IMAGE]
		<p>{DATE:d/m/y:EN}[SUBTITLE] <b>{SUBTITLE}.</b>[/SUBTITLE]
		{SUMMARY} <a href="{ARTICLELINK}">&raquo;</a></p>

	<hr style="margin:7px 0 7px 0;padding:0;height:0;border:0;border-bottom:1px dotted #CCCCCC;clear:both" />

	<div style="clear:both;height:1px"></div>


Post Reply