Main Menu
collapse

Simple Portal Archived Forum

This is an Archive Forum.

The content in this forum may be out-of-date or have been superseded by newer information, and links in forum pages to other sites may not work.
This forum contains archives for future reference.

Visit our thread at Simple Machines Forum for current support.

SMF 2.1 users: EhPortal is a ported version of Simple Portal specifically designed for the SMF 2.1 branch.
Please visit web-develop.ca to download EhPortal and for its support.

User Info

Welcome Guest.
Please log in.

Who's Online

  • Dot Guests: 1292
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.

Recent Posts

Adding Forums Button to Nav bar by jirapon
[August 01, 2019, 09:07:12 AM]


Re: Board Icons by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 04:03:41 PM]


MOVED: Czech translation???? by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 03:04:51 PM]


Board Icons by jirapon
[July 30, 2019, 07:28:44 AM]


Re: Thankyou Simpleportal, by ♦ Ninja ZX-10RR ♦
[July 29, 2019, 09:41:29 AM]


NEED HELP? If you're looking for support with Simple Portal, look no further than the Support Board!

Block w/ Recent Topic & 1st Attached image

Started by b1gbely, August 07, 2013, 09:18:26 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

b1gbely

Hi there SP!  Noob here w/ little programming experience.  Wasn't sure if I should bump an old thread or create a new one, so here goes:

I am attempting to create a block that basically just shows the 1st attached image, and just the recent topic.

I played around with SP's Recent Image Attachment block, but didn't know how to incorporate the recent topic title.

So now I took a samozin's code from this thread:  http://simpleportal.net/index.php?topic=4118.0 (Thanks samozin) and was wondering if someone could help me get rid of those bullets, remove the vertical grey lines & display more recent topics/images & the page #s.

Not sure if I should continue down this path, or play with the  Recent Image Attachment block

$attachments = ssi_recentAttachments(10, array('jpg', 'png', 'gif', 'bmp'), 'array');

   echo '
<table style="border: 0; margin: 0 auto;">
  <tr>
    <td>
      <ul style="float: right; width: 100%;">';

foreach ($attachments as $item)
     echo '
    <li class="windowbg2"  style="text-align: center; width: 240px; height: 240px; line-height: 1.4em; border: 0px #fafafa solid;  padding: 2px; float: right;">

<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse"  width="100%">
  <tr>
    <td class="windowbg2" width="100%" colspan="2">

     ', $item['file']['image']['link'], '<br />

    </td>
  </tr>

    <td class="windowbg2" width="100%" colspan="2" height="40">
<b>
<font size="2" face="Arabic Transparent">', $item['topic']['link'], '</font></b><br /> 

    </td>
  </tr>
  <tr>
    <td width="50%">
    </td>
  </tr>
</table><br>

      </li>';

   echo '
      </ul>
    </td>
  </tr>
</table>';

b1gbely


[SiNaN]

Topic solved feature is not actually enabled in customization boards, so if you've solved your problem, it's okay. Maybe you can also share your final code in case others would find it useful as well.
And slowly, you come to realize... It's all as it should be...