To use this website completely, it is necessary to store cookies on your computer.
 

* Navigator

Expand - Collapse

* Statistic

  • *Total Posts: 16404
  • *Total Topics: 2518
  • *Online Today: 10
  • *Most Online: 292
(12. Nov 2016, 09:37:31)
  • *Users: 0
  • *Guests: 0
  • *Spiders: 2
  • *Total: 2

  • *Yahoo!
  • *Baidu

Recent Attachments options

Started by zijo, 05. Feb 2016, 03:36:43

previous topic - next topic

0 Members and 0 Guests are viewing this topic.

Go Down

zijo

05. Feb 2016, 03:36:43
I have php portalmx block and added



ssi_recentAttachments(5);


It shows file name, posted by, downloads and file size.

Is it possible to add date and post name to be shown as well?

zijo

#1
09. Feb 2016, 01:47:58
 :-\

feline

#2
09. Feb 2016, 19:58:35
All the SSI functions are designed by SMF .. so it's better you make your question on the SMF site ..
Many are stubborn in relation to the path, a few in relation to the target.

zijo

#3
10. Feb 2016, 00:41:40
Modified SSI file. Added Post and Date. This can be used with other functions as well.

Code Select
// Give them the default.
echo '
<table class="ssi_downloads">
<tr>
<th style="text-align: left; padding: 2">', $txt['file'], '</th>
<th style="text-align: left; padding: 2">', $txt['posted_by'], '</th>
<th style="text-align: left; padding: 2">', $txt['downloads'], '</th>
<th style="text-align: left; padding: 2">', $txt['filesize'], '</th>
                <th style="text-align: left; padding: 2">Post</th>
<th style="text-align: left; padding: 2">Date</th>

</tr>';
foreach ($attachments as $attach)
echo '
<tr>
<td>', $attach['file']['link'], '</td>
<td>', $attach['member']['link'], '</td>
<td style="text-align: center">', $attach['file']['downloads'], '</td>
<td>', $attach['file']['filesize'], '</td>
                <td>', $attach['topic']['link'], '</td>
                <td>', $attach['topic']['time'], '</td>
</tr>';

Go Up