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

* Navigator

Expand - Collapse

* Statistic


  • *Total Posts: 16430
  • *Total Topics: 2522
  • *Online Today: 5
  • *Most Online: 292
(12. Nov 2016, 09:37:31)
  • *Users: 0
  • *Guests: 0
  • *Spiders: 1
  • *Total: 1

  • *Google

* Calendar

Mo
Tu
We
Th
Fr
Sa
Su
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30

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.

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>';