Facebook  Twitter 

SMFHacks.com

+-

SMFHacks.com

+- User Information

Welcome, Guest.
Please login or register.
 
 
 
Forgot your password?

+- Forum Stats

Members
Total Members: 4257
Latest: Alex998.
New This Month: 1
New This Week: 0
New Today: 0
Stats
Total Posts: 43295
Total Topics: 7523
Most Online Today: 344
Most Online Ever: 2482
(April 09, 2011, 07:02:45 pm)
Users Online
Members: 0
Guests: 199
Total: 199

Author Topic: About Layout Options  (Read 5585 times)

0 Members and 1 Guest are viewing this topic.

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16452
    • View Profile
Re: About Layout Options
« Reply #15 on: May 22, 2019, 08:05:22 pm »
Try this instead
Code: [Select]
// Max Items per row
$maxrowlevel = 4;

$rowlevel = 0;
while($row = $smcFunc['db_fetch_assoc']($dbresult))
{

$totallistings  = Classifieds_GetListingTotals($row['ID_CAT']);
if ($rowlevel == 0)
echo '<tr>';


if($row['imageurl'] == '' && $row['imagefilename'] == '')
echo '<td colspan="2" class="windowbg"><a href="' . $scripturl . '?action=classifieds;cat=' . $row['ID_CAT'] . '">' . parse_bbc($row['title']) . '</a> ' . (!empty($modSettings['class_showrss_bycat']) ? '<a href="' . $scripturl . '?action=classifieds;sa=rss;cat=' . $row['ID_CAT'] . ';type=recent"><img src="' . $modSettings['class_url'] . 'rss.png" alt="rss" /></a>' : '') . '</td>';
else
{
if($row['imagefilename'] == '')
echo '<td class="windowbg2"><a href="' . $scripturl . '?action=classifieds;cat=' . $row['ID_CAT'] . '"><img src="' . $row['imageurl'] . '" border="0" alt=""  /></a></td>';
else
echo '<td class="windowbg2"><a href="' . $scripturl . '?action=classifieds;cat=' . $row['ID_CAT'] . '"><img src="' . $modSettings['class_url'] . 'catimgs/' . $row['imagefilename'] . '" border="0" alt=""  /></a></td>';


echo '<td class="windowbg"><a href="' . $scripturl . '?action=classifieds;cat=' . $row['ID_CAT'] . '">' . parse_bbc($row['title']) . '</a> ' . (!empty($modSettings['class_showrss_bycat']) ? '<a href="' . $scripturl . '?action=classifieds;sa=rss;cat=' . $row['ID_CAT'] . ';type=recent"><img src="' . $modSettings['class_url'] . 'rss.png" alt="rss" /></a>' : '') . '</td>
';
}


if($rowlevel < ($maxrowlevel-1))
$rowlevel++;
else
{
echo '</tr>';
$rowlevel = 0;
}
}

if($rowlevel !=0)
{
echo '</tr>';
}
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline ajac63

  • Jr. Member
  • **
  • Posts: 69
    • View Profile
    • "blag-it" Forum
Re: About Layout Options
« Reply #16 on: May 23, 2019, 04:14:49 am »
Great, you certainly know your stuff!  Works exactly how I had it in mind and has also given me a good insight into how php works. 

 

Related Topics

  Subject / Started by Replies Last post
4 Replies
5672 Views
Last post May 09, 2009, 02:28:47 am
by jacci
6 Replies
6070 Views
Last post May 18, 2009, 07:19:48 am
by propyl
8 Replies
7117 Views
Last post February 25, 2010, 01:45:37 pm
by SMFHacks
5 Replies
6862 Views
Last post August 30, 2013, 08:44:22 am
by SMFHacks
1 Replies
3767 Views
Last post June 25, 2014, 12:06:25 pm
by SMFHacks

+- Recent Topics

Please Help! by SMFHacks
April 17, 2024, 08:04:55 am

Rate own images by fvlog19
April 11, 2024, 10:56:53 am

Tidy Child Boards on 2.1.4 by SMFHacks
April 04, 2024, 03:54:12 pm

Problems SMF 2.0.19 > 2.1.4 SMF Gallery Pro - Recents Images to overall header by Michel68
March 30, 2024, 12:41:08 pm

Can't DROP 'id_member'; check that column/key exists Datei: by SMFHacks
March 30, 2024, 11:58:20 am

No thumbnails on new uploads by Tonyvic
March 29, 2024, 06:26:18 am

Display the Contact Page for guests by SMFHacks
March 27, 2024, 10:55:43 am

is it possible to add support for odysee.com by fvlog19
March 21, 2024, 08:47:51 am

Request for admin notification by davejo
March 10, 2024, 01:31:59 am

I need help with torrent upload by Ineedsmfhelp
March 09, 2024, 10:01:13 pm

Powered by EzPortal