Solved

Simple CSS positioning issue

Posted on 2012-03-23
4
186 Views
Last Modified: 2012-03-24
I am at a loss on how to do this.  It seems so simple.  I have three lines of text.  The middle line also contains an image that is a bit higher than the line height.  I do not want the image to increase the line height.  I want it to creep into the space of the line below it.  

Here is my sample mock up.
http://realpersona.com/test/line.html

Please give suggestions.
0
Comment
Question by:Thread7
  • 2
4 Comments
 
LVL 30

Expert Comment

by:LZ1
ID: 37757085
Try this:
<img src="btn_edit.jpg" align="top">
0
 
LVL 1

Author Comment

by:Thread7
ID: 37757805
Well good idea, but that just made the line gap at the bottom instead of the top of line #2.
http://realpersona.com/test/line_top.html
0
 
LVL 30

Expert Comment

by:LZ1
ID: 37758077
I'm not sure what you mean by

>> I do not want the image to increase the line height.  I want it to creep into the space of the line below it.  

Unless you position it absolutely, the entire line will have to make room for the image vertically.
0
 
LVL 17

Accepted Solution

by:
jrm213jrm213 earned 500 total points
ID: 37758304
For that specific example the best I can come up with without really messing with your layout is

 
<img align="top" src="btn_edit.jpg" style="vertical-align: bottom; margin-bottom: -6px;">

Open in new window

0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying 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

Suggested Solutions

Learn by example how to specify CSS selectors for Selenium WebDriver test automation software.
Get to know the ins and outs of building a web-based ERP system for your enterprise. Development timeline, technology, and costs outlined.
The viewer will get a basic understanding of what section 508 compliance can entail, learn about skip navigation links, alt text, transcripts, and font size controls.
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

856 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