Results 1 to 2 of 2
  1. #1
    Join Date
    May 2007
    Posts
    5
    Plugin Contributions
    0

    css problem layout boxes margin padding changes to generic template

    I've been creating a style based on the generic templates
    for a new site. I could see the following in the html code of the web page:

    Code:
    <ul style="margin: 0; padding: 0; list-style-type: none;">
    This code was overriding my CSS templates. Looking further,
    I discovered the following templates have hard coded styles:
    sideboxes/tpl_ezpages.php
    sideboxes/tpl_information.php
    sideboxes/tpl_manufacturer_info.php
    sideboxes/tpl_more_information.php
    You can find them simply by searching for the hard coded text
    eg: <ul style="margin:0

    The solution is to remove the hard coded style and replace
    it with a suitable stylesheet class call.
    EG, change the lines:
    Code:
    $content .= "\n" . '<ul style="margin: 0; padding: 0; list-style-type: none;">' . "\n";
    to
    Code:
    $content .= "\n" . '<ul class="myclassname">' . "\n";
    In your stylesheet add:
    Code:
    .myclassname {
         list-style-type:none;
         margin:0;
         padding:0;
        }
    I suggest you change myclassname to something suitable.
    If you want all side boxes to share the same layout then
    you can use once style, otherwise a style for each box
    may be neccessary.

    I hope this helps saves someone some time and headscratching.

    Steve Root
    http://www.kinsbury.co.uk
    http://www.steveroot.co.uk

  2. #2
    Join Date
    Jun 2003
    Posts
    33,720
    Plugin Contributions
    0

    Default Re: layout boxes margin padding changes to generic template

    Thanks Steve. We'll have a look at that for 1.4
    Please do not PM for support issues: a private solution doesn't benefit the community.

    Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

 

 

Similar Threads

  1. I have a padding or margin issue
    By Coffinwear in forum Templates, Stylesheets, Page Layout
    Replies: 6
    Last Post: 30 Jul 2010, 04:01 PM
  2. Making changes on Layout Boxes Controller
    By BigAl49 in forum Templates, Stylesheets, Page Layout
    Replies: 5
    Last Post: 27 May 2010, 01:34 AM
  3. Padding/Margin Issues
    By Berserker in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 30 Aug 2009, 04:44 PM
  4. layout boxes controller changes language!!!
    By joudesign in forum Basic Configuration
    Replies: 1
    Last Post: 27 Jul 2009, 06:14 PM
  5. Margin-Padding??
    By mmnord in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 8 Sep 2008, 07:38 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg