473,471 Members | 1,716 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Problem with line height when using <span> and "float:right"

97 New Member
Hi there,

I am building a small WebApp, and using a list to display country values for a specific variable. It should be like

Country A 10
Country B 4
Country C 125


So, what I have in CSS is this:
Expand|Select|Wrap|Line Numbers
  1. .variable {
  2.     font-size: 12px; 
  3.     font-weight: bold;
  4.     color: #7388a5;
  5. }
  6.  
  7. .value {
  8.     font-size: 12px; 
  9.     text-align: right;
  10.     float: right;
  11. }
and the code like this:
Expand|Select|Wrap|Line Numbers
  1. <ul>
  2.   <li>
  3.     <span class="variable">Afghanistan</span>
  4.     <span class="value">10</span>
  5.   </li>
  6. </ul>
But, when using a 1px border around the SPANs, I see that the "variable" box is a big as the name, but the "value" boxes are taller, as if there would be a BR attached to the SPAN.

What is this, and how can I solve this?

Thanks for any hints!
Jun 3 '10 #1
2 4512
drhowarddrfine
7,435 Recognized Expert Expert
I don't see this problem at all. Which browser are you using?
Jun 3 '10 #2
luftikus143
97 New Member
Ok, I stripped off all CSS code which was included in DIVs before, and started from scratch. Now it works again. Problem was related with parent-CSS.

Cheers!
Jun 3 '10 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

15
by: Sander Tekelenburg | last post by:
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The HTML specs speak of "replaced" and "non-replaced" elements, yet for the life of me I can't find an explanation of what "replaced" is supposed...
3
by: Adam Toline | last post by:
In reference to the following: http://www.bellecose.com/form.htm At the top of each column there is a box for "All". When one is checked I need to check all of (and only) those boxes...
15
by: pbd22 | last post by:
Hi. I want to create a tab with a little "active tab" arrow below it to tell the user where they are. An example is here: http://personals.yahoo.com/us/search/dashboard Does anybody know of...
3
by: laredotornado | last post by:
Hi, Below I have an unordered list that is displayed on the same horizontal plane (thanks for the help yesterday). What I am wondering now is I would like the contents of the DIV with class...
5
eragon
by: eragon | last post by:
I wrote this function to create a new file when the user posts in my forums, and its not creating a new file, can you help me? this script is not copyrighted as the last one. function...
3
by: riggy | last post by:
So, I have an order form that works fine in IE but when you enter the info in Firefox and click the Submit Button, nothing happens. I am not sure if the button is not working or if there is a error...
2
by: bips2008 | last post by:
The code seems to work fine in other browser but in IE it throws this error. This is very urgent for me and any help would be greatly appreciated For your convienence i have posted the code for the...
5
matheussousuke
by: matheussousuke | last post by:
Hello, I'm using tiny MCE plugin on my oscommerce and it is inserting my website URL when I use insert image function in the emails. The goal is: Make it send the email with the URL...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.