Page 1 of 3 123 LastLast
Results 1 to 10 of 22
  1. #1
    Join Date
    Sep 2007
    Location
    Niagara Falls, Ontario
    Posts
    377
    Plugin Contributions
    0

    Default Blank side box issue

    I have installed the Blank Side Box add-on and it seems to have a gap between the title bar and the content.
    Is there a way to get rid of the gap? I'm using the basic config for this add-on.
    The link to see what I'm talking about it www.robertensing.com

    Thanks
    Robert

  2. #2
    Join Date
    Apr 2006
    Location
    London, UK
    Posts
    10,569
    Plugin Contributions
    25

    Default Re: Blank side box issue

    When I look at the XHTML being generated for this page, it reads
    Code:
    <p></p>Get an instant 10% discount for opening an account. A "10% off your first purchase" coupon will be emailed to you as soon as you create a new account. Simply go to the "<a href="https://robertensing.com/index.php?main_page=login">Log In</a>" page and create a new account.
    Those empty paragraph tags at the beginning are what is causing your unwanted space. I suspect you meant to wrap the paragraph tags around the text.
    Kuroi Web Design and Development | Twitter

    (Questions answered in the forum only - so that any forum member can benefit - not by personal message)

  3. #3
    Join Date
    Sep 2007
    Location
    Niagara Falls, Ontario
    Posts
    377
    Plugin Contributions
    0

    Default Re: Blank side box issue

    Quote Originally Posted by kuroi View Post
    When I look at the XHTML being generated for this page, it reads
    Code:
    <p></p>Get an instant 10% discount for opening an account. A "10% off your first purchase" coupon will be emailed to you as soon as you create a new account. Simply go to the "<a href="https://robertensing.com/index.php?main_page=login">Log In</a>" page and create a new account.
    Those empty paragraph tags at the beginning are what is causing your unwanted space. I suspect you meant to wrap the paragraph tags around the text.
    Actually, the only paragraph tags left are the ones in the heading and the gap is still there.
    All I did was follow the directions and put the text exactly where your instructions told me to put the text.
    Here is the actual code as it is now:
    .
    .
    $content .= '<p>' . Instant_10%_Discount . '</p>';
    $content .= 'Get an instant 10% discount for opening an account. A "10% off your first purchase" coupon will be emailed to you as soon as you create a new account. Simply go to the "<a href="https://robertensing.com/index.php?main_page=login">Log In</a>" page and create a new account.';

    $content .= '</div>';
    ?>

  4. #4
    Join Date
    Apr 2006
    Location
    London, UK
    Posts
    10,569
    Plugin Contributions
    25

    Default Re: Blank side box issue

    The header text is actually being picked up from your language file, not from the bit of code that you have just posted.

    That code is invalid. and everything between the paragraph tags is being ignored, which is why you get an empty paragraph.

    Upon reflection, though it would probably be a good idea to wrap your other text in paragraph tags as although not strictly necessary, Internet Explorer prefers it and some of the bugs in version 6 are associated with text wrapped in div tags only.
    Kuroi Web Design and Development | Twitter

    (Questions answered in the forum only - so that any forum member can benefit - not by personal message)

  5. #5
    Join Date
    Sep 2007
    Location
    Niagara Falls, Ontario
    Posts
    377
    Plugin Contributions
    0

    Default Re: Blank side box issue

    Quote Originally Posted by kuroi View Post
    The header text is actually being picked up from your language file, not from the bit of code that you have just posted.

    That code is invalid. and everything between the paragraph tags is being ignored, which is why you get an empty paragraph.

    Upon reflection, though it would probably be a good idea to wrap your other text in paragraph tags as although not strictly necessary, Internet Explorer prefers it and some of the bugs in version 6 are associated with text wrapped in div tags only.
    I'm confused.
    The file that has that info is located in my ../templates/MY_TEMPLATE/sideboxes/tpl_blank_sidebox.php and with or without the <p></p> tags the space is there.
    In the laguage file there is a header and some text, but none of that is showing up on the site. That file is located at ../languages/english/extradefinitions/blank_sidebox_defines.php

  6. #6
    Join Date
    Apr 2006
    Location
    London, UK
    Posts
    10,569
    Plugin Contributions
    25

    Default Re: Blank side box issue

    Unless you have changed code in the template that you're not showing us, the header for the blank sidebox is held in the constant BOX_HEADING_BLANK_SIDEBOX, which is output between header tags by tpl_blank_sidebox.php and defined in blank_sidebox_defines.php.

    The line
    $content .= '<p>' . Instant_10%_Discount . '</p>';
    is causing most of your blank space since you have no constant defined called Instant_10%_Discount and so this is treated as NULL by PHP. To satisfy yourself that this is not the text being output, I suggest that you form it correctly i.e.
    $content .= '<p>Instant_10%_Discount</p>';
    and you will see that it duplicates the text in the title.

    When that line is then deleted, most of the space at the top will disappear. You'll still have some, and it will be equal at the top and the bottom of the box. If you wish to eliminate it, you would add the following to your stylesheet no earlier than line 140:
    #blanksideboxContent p {padding: 0 0.5em}
    Kuroi Web Design and Development | Twitter

    (Questions answered in the forum only - so that any forum member can benefit - not by personal message)

  7. #7
    Join Date
    Sep 2007
    Location
    Niagara Falls, Ontario
    Posts
    377
    Plugin Contributions
    0

    Default Re: Blank side box issue

    Quote Originally Posted by kuroi View Post
    Unless you have changed code in the template that you're not showing us, the header for the blank sidebox is held in the constant BOX_HEADING_BLANK_SIDEBOX, which is output between header tags by tpl_blank_sidebox.php and defined in blank_sidebox_defines.php.

    The line is causing most of your blank space since you have no constant defined called Instant_10%_Discount and so this is treated as NULL by PHP. To satisfy yourself that this is not the text being output, I suggest that you form it correctly i.e. and you will see that it duplicates the text in the title.
    Than'ts exactly what happened and showed me that the title was defined in a different file, I just happened to have the same text in two files (although one was ignored until I put in the correct codes.)
    Looks like I have it figured out now, thanks


    Quote Originally Posted by kuroi View Post
    When that line is then deleted, most of the space at the top will disappear. You'll still have some, and it will be equal at the top and the bottom of the box. If you wish to eliminate it, you would add the following to your stylesheet no earlier than line 140:
    If I decide to add this to my style sheet, what tag whould I use, "BOX_HEADING_BLANK_SIDEBOX" ?

    Thanks again.

  8. #8
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Blank side box issue

    No, BOX_HEADING_BLANK_SIDEBOX is a PHP constant, not an HTML tag.

    What you would add to your stylesheet is exactly what Kuroi posted:
    Code:
    #blanksideboxContent p {padding: 0 0.5em}

  9. #9
    Join Date
    Sep 2007
    Location
    Niagara Falls, Ontario
    Posts
    377
    Plugin Contributions
    0

    Default Re: Blank side box issue

    Quote Originally Posted by gjh42 View Post
    No, BOX_HEADING_BLANK_SIDEBOX is a PHP constant, not an HTML tag.

    What you would add to your stylesheet is exactly what Kuroi posted:
    Code:
    #blanksideboxContent p {padding: 0 0.5em}
    I have tried:
    #blanksideboxContent p {padding: 0 0.5em}

    I have tried:
    #blanksideboxContent p {
    padding: 0 0.5em
    }

    I have tried:
    #blanksideboxContent p {
    padding: 0 0.5em;
    }

    I've even tried:
    #blanksideboxContent p {
    padding: 0.5em;
    }

    starting on line 143 and can't seem to see any difference.
    ( I tried following the way the stylesheet.css was layed out)

  10. #10
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Blank side box issue

    If you have added a bunch of items early in your stylesheet, that line count will be wrong.

    Try adding the code at the end of the stylesheet. Or look through your stylesheet to find where the p element is styled, and make sure your new declaration is just below that.

 

 
Page 1 of 3 123 LastLast

Similar Threads

  1. Replies: 2
    Last Post: 13 Jun 2011, 04:22 PM
  2. Blank Side Box Help!!
    By rileybianca6 in forum Addon Sideboxes
    Replies: 3
    Last Post: 17 Feb 2011, 02:44 PM
  3. blank side box mod
    By Sushigal in forum Templates, Stylesheets, Page Layout
    Replies: 10
    Last Post: 7 Jan 2011, 10:07 AM
  4. blank side box 2 - doesn't like £ sign in box? shows funny symbol
    By DSCrossStitch in forum Basic Configuration
    Replies: 4
    Last Post: 28 Oct 2008, 04:30 PM
  5. Side Box Issue
    By Adds in forum General Questions
    Replies: 5
    Last Post: 10 Nov 2007, 11:08 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