Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

having a problem with <div> tags and z-index with over laying text.

Posted on 2008-10-15
3
Medium Priority
?
246 Views
Last Modified: 2012-05-05
hello,
i have created a banner with <div> tags and z-index with overlying text layer.  it shows up correct in firefox but in ie the text breaks lines after each word. does anyone see an issue with my code?
thanks
<!--BACKGROUND COLOR-->
<div style="width:369px; height:150px; z-index:1; position:absolute;"><a href="/catalog/theme.jsp?themeId=381&"><img src="10-15-08_christmas_store_feature_2.jpg" alt=" Shop 2008 Collectibles" width="369" height="150" border="0"></a></div>
<!--BACKGROUND COLOR-->
 
<!--COPY-->
<div style="width:199px; height:95px; padding-left:20px; padding-right:150px; padding-top:55px; z-index:2; font:Arial, Helvetica, sans-serif; font-size:14px; color:#FFFFFF; position:absolute;">
shop 2008 collectible items
</div>
<!--COPY-->

Open in new window

0
Comment
Question by:nooch44
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 44

Expert Comment

by:scrathcyboy
ID: 22725942
try using in CSS -- display:inline;    or display:inline-block;   to style the text giving problems.
0
 
LVL 4

Accepted Solution

by:
MattKenefick earned 2000 total points
ID: 22731770
in IE.. padding subtracts from the total width of an object as opposed to adding to it.

So when you have and object that is about 200px wide.. and you have 20px padding on left, and 150px padding on right... That only leaves 30px of space for words.. Which is why your words are breaking.
0
 

Author Closing Comment

by:nooch44
ID: 31506489
took the padding on the righ away and it did the trick...thanks
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remai…
When crafting your “Why Us” page, there are a plethora of pitfalls to avoid. Follow these five tips, and you’ll be well on your way to creating an effective page.
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question