TalkPHP
 
 
Account Login
Latest Articles
» The basic usage of PHPTAL, a XML/XHTML template library for PHP
» Vulnerable methods and the areas they are commonly trusted in.
» Simple way to protect a form from bot
» The Basics On: How Session Stealing Works
» How to keep your forms from double posting data
IRC Channel
IRC Speech Bubble Join the friendly bunch on IRC...
(#TalkPHP on Freenode)

...Also available via a web interface.

See this thread for information on the TalkPHP Free Hugs Initiative™. Subject to availability.
Associates
Associates
CSS Tutorials
Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old 12-04-2008, 01:08 AM   #1 (permalink)
The Wanderer
 
Join Date: Dec 2008
Posts: 9
Thanks: 0
almac007 is on a distinguished road
Default White space appearing either sie of image in firefox - displays correctly in IE

Hi Guys,

This is my first post in this forum so hopefully i am in the right area. Basically i have picked up a web development project that has some display issues and i am desperatly been trying to fix it up for my client.

The website is http://www.thinkpharmacy.com.au

Located on the right hand side of the home page is a shopping basket which can be expanded / collapsed to view the users current items. The JQuery functionality for this is working both in IE and firefox but when the basket is expanded in firefox two white lines appear above and below the items in the shopping cart.

I am thinking that it must be css as it is a display issue not so much functionality but i am neither a javascript or css guru so i could be wrong.

If anyone in this forum has seen a problem like this one before or has any advice that could help me out as to why this is happening i would be very apprieciative.

Thanks in advance.

Almac007
almac007 is offline  
Reply With Quote
Old 12-04-2008, 02:01 AM   #2 (permalink)
La Vida es Sueño
Advanced Programmer Top Contributor 
 
Wildhoney's Avatar
 
Join Date: Sep 2007
Location: Oldham
Posts: 2,280
Thanks: 90
Wildhoney is on a distinguished road
Default

Insofar as I can see, the element box_content has a rigid height of 13px, when it should be 100% to utilise the white space above and below. Why that works perfectly in Internet Explorer, I am not sure.

Welcome to the community, my friend!
__________________
The man who comes back through the Door in the Wall will never be quite the same as the man who went out.
Send a message via AIM to Wildhoney Send a message via MSN to Wildhoney Send a message via Yahoo to Wildhoney
Wildhoney is offline  
Reply With Quote
Old 12-04-2008, 11:29 PM   #3 (permalink)
The Wanderer
 
Join Date: Dec 2008
Posts: 9
Thanks: 0
almac007 is on a distinguished road
Default

Hi Wildhoney,

Thanks for getting back to me.

Where are you seeing that it has a rigid height of 13px?

line 162: <div class="basket_body" id="box_content"></div>

and then when i look at the basket body css i see the following:

.basket_body{
width:180px;
background:url(../images/basket_body.gif);
background-position:top;
background-repeat:repeat-y;
vertical-align:top;
padding:0;

}

from what i can tell the box_content id is being referenced by the div above us on line 160.

<div align="right" style="margin-right:15px; position:absolute; margin-top:120px;"> <span id="swap"><a class="basket_text" href="javascript:;" onClick="toogle('box_content');" onMouseOver="this.className='basket_text_over'" onMouseOut="this.className='basket_text'">Expand Basket </a><img src="../images/down.gif" width="10" height="10" align="absmiddle" /></span></div>

am i going down the right track here or am i way off?

Thanks so much for your help.

Almac007
almac007 is offline  
Reply With Quote
Old 12-04-2008, 11:45 PM   #4 (permalink)
The Wanderer
 
Join Date: Dec 2008
Posts: 9
Thanks: 0
almac007 is on a distinguished road
Default

I have now added in a height element into the CSS which has fixed the whitespace at the bottom of the basket.

.basket_body{
width:180px;
height:75px; /* 125px real image size */
background:url(../images/basket_body.gif);
background-position:top;
background-repeat:repeat-y;
vertical-align:top;
padding:0;
}

now the only problem is the whitespace appearing at the top.
almac007 is offline  
Reply With Quote
Old 12-05-2008, 12:21 AM   #5 (permalink)
The Wanderer
 
Join Date: Dec 2008
Posts: 9
Thanks: 0
almac007 is on a distinguished road
Default Solved!!!

I just fixed it...

Ended up that i needed to add margin-top:0px;

to the box text and it fixed it.

.box_text{
margin-left:15px;
font-family:Arial, Helvetica, sans-serif;
font-size:10px;
color:#213F57;
margin-top:0px;

}

Wildhoney thanks for your advice and help with this.

Cheers,

Almac007
almac007 is offline  
Reply With Quote
Old 12-05-2008, 02:03 AM   #6 (permalink)
The Addict
 
CoryMathews's Avatar
 
Join Date: Nov 2007
Location: USA
Posts: 256
Thanks: 7
CoryMathews is on a distinguished road
Default

You really need to shrink the size of that page. It was 700kb+ when I loaded it. It should be under 100k tops. 700k/24k = way to long of a download for 30% of the world.
CoryMathews is offline  
Reply With Quote
Old 12-05-2008, 04:07 AM   #7 (permalink)
The Wanderer
 
Join Date: Dec 2008
Posts: 9
Thanks: 0
almac007 is on a distinguished road
Default

Yeah i know. Dont know what the go is there... they obviously havent optimised their images.

Its certainly on the to do list.

Thanks for pointing it out.

cheers,

Almac007
almac007 is offline  
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Image Reflections in PHP Rendair Advanced PHP Programming 17 11-30-2011 08:41 AM


All times are GMT. The time now is 05:59 AM.

 
     

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Inactive Reminders By Icora Web Design