View Single Post
Old 2018-04-20, 11:48 AM   #36
Greenguy
The Original Greenguy (Est'd 1996) & AVN HOF Member - I Crop Pics For Thumbs In My Sleep
 
Greenguy's Avatar
 
Join Date: Feb 2003
Location: Blasdell, NY (shithole suburb south of Buffalo)
Posts: 41,758
Send a message via ICQ to Greenguy
Quote:
Originally Posted by Toby View Post
You have to do it in two sections. First for the new, then for the filler, in order to be able to specify different sort order parameters for the two. That's where the fillvar comes into play for the second section, so that it can compute the number of fill galleries needed based on how many new were found in the first section.

Visibly it will appear to be one section, but it requires two separate sections of code in the template.
Isn't that what this is?

Code:
<table style="text-align:center;" align="center" cellpadding="0" cellspacing="0" width="100%">
<tr>
{* Load 52 galleries *}
{galleries
var=$galleries
type=permanent
format=any
getnew=true
allowused=false
description=true
preview=true
amount=52
previewsize=180x180
category=Latina
sponsor=any
order=date_approved DESC
reorder=date_approved DESC}

{* Load filler galleries if 52 galleries were not available in the previous galleries section *}
{galleries
var=$fillergalleries
fillvar=$galleries
type=permanent
format=any
getnew=true
allowused=true
description=true
preview=true
amount=52
previewsize=180x180
category=Latina
sponsor=any
order=RAND()
reorder=RAND()}

{* Place the filler galleries at the end *}
{intermix var=$galleries from=$galleries,$fillergalleries location=end}

{* Display loaded galleries as thumbnails in a 4 per row format *}
{foreach from=$galleries var=$gallery counter=$counter}
<td align="center" valign="top" style="text-align:center;" width="25%">
<a href="{$gallery.gallery_url|htmlspecialchars}" title="{$gallery.description|htmlspecialchars}"><img src="{$gallery.preview_url|htmlspecialchars}" width="180" height="180" border="2" alt="{$gallery.description|htmlspecialchars}"></a><br><br>
</td>
{insert counter=$counter location=+4 max=48}
</tr><tr>
{/insert}
{/foreach}
</tr>
</table>
__________________

Promote POV Porn Cash By Building & Submitting Galleries to the Porn Luv Network
Greenguy is offline   Reply With Quote