TinyPortal

Development => Support => Topic started by: wildenborch on June 17, 2013, 05:07:38 PM

Title: Recent article block
Post by: wildenborch on June 17, 2013, 05:07:38 PM
Hi,

My recent article block shows the date and time and of course the title of the article.
Is is possible to only show the date and not the time.
I don't want to adjust the date/time settings because that's also changes the date/time of the forum.

Here is the code I'm using

case 'dl-stats7':
$it = array();
$it = art_recentitems('15','date');
if(sizeof($it) > 0)
{
foreach($it as $item)
{
echo '<span class="smalltext"><img src="http://www.dyane.nl/tp-images/icons/bullet3.gif" > <a title="'.$item['date'].'" href="'.$scripturl.'?page='.$item['id'].'">'.$item['subject'].'</a>
</span><br />';
}



Link to my site: www.dyane.nl
SMF version 2.04
TP version 1
Dutch
Title: Re: Recent article block
Post by: ZarPrime on June 18, 2013, 07:15:06 AM
wildenborch,

Have a look at this page for examples of how to format date strings in php --> http://php.net/manual/en/function.date.php

ZarPrime
Title: Re: Recent article block
Post by: wildenborch on June 18, 2013, 09:50:18 AM
Zarprime,

I now realize that my message is missing some important information.
The code is in the tpsubs template. In fact it is the default article block.

My apologies for not being clear.

Since I have already found another solotion (another block code (http://www.tinyportal.net/index.php?topic=31110 (http://www.tinyportal.net/index.php?topic=31110)) my request can be ignored.

Best regards,
Wildenborch




Title: Re: Recent article block
Post by: ZarPrime on June 18, 2013, 03:39:04 PM
OK, good.  Well then, we will mark this one solved and move it to the Support board. O0

ZarPrime