Register  |  Login



Earn money by sharing your knowledge through Quomon's revenue sharing program

Question

Status: Closed Points: 75 Time: 07:32 - Mar 22, 2007  

sbjc23

Is there a way to prevent the text from wrapping using HTML and CSS?

I am looking to create a table but I dont want my links to wrap at all within a table if they are too long, is there any way to accomplish this where it just pushes the table out?

Answer Discussion
Tutorials

 

Q&A System for Websites and Corporate Collaboration

Advertisement

  • Generates significant organic traffic for websites
  • Saves companies money, resources, and time

rcastagna

Date:: Mar 22, 2007

Time:: 11:19

Hello...

Your mileage is going to vary with this one, mostly because of the way the browsers treat "containers" which both tables and table cells fall under the category of.

In order for this to work *most* of the time in *most* browsers, you're going to have to ensure that you do not have any fixed widths (either pixel or percentage) on both the table cell and the table itself.

Once you've made sure the table is as flexible as possible, you'll want to wrap your link inside a <nobr></nobr> element, and apply a style class including the "white-space: nowrap" specification in it.

Again, this is not going to be 100% in all browers because a) <nobr> is not an HTML standardized element and is only understood by some browers, and b) white-space: nowrap is an adopted CSS element, but it too is not supported by all browsers.

I hope this gets you back on track,
Ric

sbjc23

Date:: Mar 22, 2007

Time:: 12:05

Thanks Ric

Question Answered

This question has been closed, and points have been rewarded to the following experts:

rcastagna: 75

You're welcome however to comment or give additional information or if you wish, you have the ability to write a Tutorial in the Tutorial Area.

Answer this Question

New User

Email:

Upon submission of this form, you will automatically be registered as a Quomon user and we will send your login information to this address

Registered User

Username:

Password:

Forgot Your Password?

No tutorials have been submitted yet. Want to be the first?

Answer this Question

New User

Email:

Upon submission of this form, you will automatically be registered as a Quomon user and we will send your login information to this address

Registered User

Username:

Password:

Forgot Your Password?

Ask a Question

Have a new question? Ask!

You have 100 characters to use



Top HTML Experts

View More

Rank

Expert

Points

1.

rcastagna

1022

2.

jgivoni

928

3.

nidhi

875

4.

xarcus

240

5.

john2

220

6.

danmacryan

125

7.

Anpanman

75

8.

multani.sarbjit

75

9.

PeterNZ

75

10.

roger.berbel

75

Become an Expert

Register today to share your knowledge with the community and be recognized and rewarded for your contributions.


Register Here




"Psst, Quomon is a great site. Pass it on."     Tell a Friend  |   Link To Us  |   Save to Delicious  |   Digg! Digg it



Language Options

English:

www.quomon.com

Español:

www.quomon.es