Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
multiline text in span
Old 09-25-2010, 10:04 AM multiline text in span
Banned

Posts: 408
Name: mushget
Trades: 0
I have a page which is designed using CSS layout. It has a simple form where two spans are used as columns. In the 1st span, i have used float:left and width to create width of the 1st column. In the second span when i have more data (say more than 3 lines) then the third line is coming from the extreme left instead of confining to the second column.

If i specify width and float for the second column(span) also then it works. But i don't want to do that in that way.

Using display:block is also not solving the problem completely. Please help me in resolving this problem.
mushget is offline
Reply With Quote
View Public Profile Visit mushget's homepage!
 
 
Register now for full access!
Old 09-25-2010, 11:53 AM Re: multiline text in span
racer x's Avatar
Ultra Talker

Posts: 457
Name: Randy
Location: Northern Wisconsin
Trades: 0
Quote:
If i specify width and float for the second column(span) also then it works. But i don't want to do that in that way.
But that's how you do it. You float the columns and specify a width for each, otherwise the right content will always kick back to the far left side of the containing div.

Also, I would use div's for those. Why use span and then have to specify "block"? Div's are block by nature.

Also, your spans could end up inheriting other span styling in the same container as well.

A link always helps too when available.

Last edited by racer x; 09-25-2010 at 11:55 AM..
racer x is offline
Reply With Quote
View Public Profile Visit racer x's homepage!
 
Old 09-27-2010, 10:43 AM Re: multiline text in span
Banned

Posts: 11
Name: Lenard A
Location: Philippines
Trades: 0
Hi mushget, i would use lists <li> or divs to answer your question.

this way its much more organized rather than using span tag. span tags are generally used for <p> tags, on my own experience.
ilitrato is offline
Reply With Quote
View Public Profile Visit ilitrato's homepage!
 
Old 09-28-2010, 02:32 AM Re: multiline text in span
Banned

Posts: 4
Name: samalden
Trades: 0
I have a page that has been created using CSS layout. This is a simple form where the two spans are used as columns. 1 At times, I have used float: left and width to create 1 column width.
samalden is offline
Reply With Quote
View Public Profile
 
Old 09-28-2010, 10:00 AM Re: multiline text in span
Super Moderator

Posts: 1,584
Location: Kokkola, Finland
Trades: 1
Quote:
Originally Posted by ilitrato View Post
Hi mushget, i would use lists <li> or divs to answer your question.

this way its much more organized rather than using span tag. span tags are generally used for <p> tags, on my own experience.
i would have thought that <p> tags are used for <p>. you could of course use <span> within a <p>
davemies is offline
Reply With Quote
View Public Profile Visit davemies's homepage!
 
Reply     « Reply to multiline text in span
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

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





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.52353 seconds with 12 queries