TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,973
  • Latest: NonStop
Stats
  • Total Posts: 196,231
  • Total Topics: 21,353
  • Online today: 515
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 0
  • Guests: 222
  • Total: 222

Recent article block

Started by wildenborch, June 17, 2013, 05:07:38 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

wildenborch

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

ZarPrime

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

wildenborch

#2
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) my request can be ignored.

Best regards,
Wildenborch





ZarPrime

OK, good.  Well then, we will mark this one solved and move it to the Support board. O0

ZarPrime

This website is proudly hosted on Crocweb Cloud Website Hosting.