Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Specials / Columnar display

Specials / Columnar display

Locked

Views: 1,809

Results 1 to 7 of 7
This thread is locked. New replies are disabled.
16 Aug 2006, 2:04 PM
#1
kevin_miller avatar

kevin_miller

New Zenner

Join Date:
May 2006
Location:
Edinburgh, Scotland
Posts:
6
Plugin Contributions:
0

Specials / Columnar display

Does anyone know where in Zen Cart code the <br /> between rows of specials gets written?

I can see where it is writing the actual content of the seperate divs for each special but can;t figure out where the break gets scripted to split the, in my case, 3 column rows from each other.

You can see the issue I'm trying to reslove here: zen.napiers.net - the special offers list at the bottom of the page. When the specials titles and images are of differing heights some unexpected layout issues occur caused by the float:left of the divs. I need to change the <br /> between the rows to <br style="clear:both;" />

Any pointers appreciated

thanks

16 Aug 2006, 4:09 PM
#2
seethrou avatar

seethrou

Totally Zenned

Join Date:
May 2004
Location:
Hong Kong
Posts:
1,156
Plugin Contributions:
0

Re: Specials / Columnar display

Instead of adding the <br />, another approach by css.

Add the following to your stylesheet.

.categoryListBoxContents {
margin-top: 0.5em;
margin-bottom: 0.5em;
}
And set the values you perfer.

And the above only for template based on the classic template design.
.

16 Aug 2006, 4:19 PM
#3
kevin_miller avatar

kevin_miller

New Zenner

Join Date:
May 2006
Location:
Edinburgh, Scotland
Posts:
6
Plugin Contributions:
0

Re: Specials / Columnar display

Thanks for the reply. Adding margins to the individual specials in the columns and rows won't help I'm afraid. I need to have a divider between the rows which clears the floats of the above row.

It would be easy if I could just find which file the Zen code uses to place the <br /> between the rows.

thanks anyway

16 Aug 2006, 4:32 PM
#4
seethrou avatar

seethrou

Totally Zenned

Join Date:
May 2004
Location:
Hong Kong
Posts:
1,156
Plugin Contributions:
0

Re: Specials / Columnar display

Please make sure to use the OverRide for the modification! :smile:

The file are.

includes/templates/YOUR_TEMPLATE/templates/tpl_specials_default.php

In line 22 and 40:
<br class="clearBoth" />

.

16 Aug 2006, 4:45 PM
#5
kevin_miller avatar

kevin_miller

New Zenner

Join Date:
May 2006
Location:
Edinburgh, Scotland
Posts:
6
Plugin Contributions:
0

Re: Specials / Columnar display

I don't think that's the right file. Those page breaks are for separating the prev/next links at the top and bottom of the page from the main body of the specials listing.

The <br /> code I am after gets used when Zen Cart is setting up the columnar display.

Example - say you have 9 specials and have set up in the admin to display them in rows of 3. Zen Cart inserts a <br /> between each of the 3 resulting rows. I need to figure out which file inserts those <br />'s

<div width="33%">special 1</div><div width="33%">special 2</div><div width="33%">special 3</div> <br /> <div width="33%">special 4</div><div width="33%">special 5</div><div width="33%">special 6</div> <br /> <div width="33%">special 7</div><div width="33%">special 8</div><div width="33%">special 9</div>
16 Aug 2006, 4:46 PM
#6
seethrou avatar

seethrou

Totally Zenned

Join Date:
May 2004
Location:
Hong Kong
Posts:
1,156
Plugin Contributions:
0

Re: Specials / Columnar display

Oops!

Sorry, the above info. is not correct! :blush:

Please check the file:
includes/templates/YOUR_TEMPLATEt/common/tpl_columnar_display.php

Line 40

<br class="clearBoth" />

Please note, this will also affect all pages using the columnar for display.

.

16 Aug 2006, 4:55 PM
#7
kevin_miller avatar

kevin_miller

New Zenner

Join Date:
May 2006
Location:
Edinburgh, Scotland
Posts:
6
Plugin Contributions:
0

Re: Specials / Columnar display

That's it! Thanks very much. I'd removed the <br class="clearBoth" /> from my code there a few weeks ago and what has caused the confusion is that Zen Cart continues to place a <br /> there even after I removed the code.

Anyways thanks a lot for your time on this :-)