• Horn Player – Computer Dude – Gig Pig …
  • Home
  • About
  • Blog
  • Services
  • Contact
  • Webmail
  • Terms

Robert A. Owen - Musician - Technology Leader

Music, Technology, Rants and Funnies - Randomness at its best!

  • Blog
  • Internet
    • IIS 6
    • IIS 7.5
    • Javascript
    • Web Design
      • WordPress
      • Coldfusion
  • Support
    • MicroSoft
      • Powershell
      • Surface
      • Windows10
      • Zune
    • PC-Care
    • Software
    • Virus
      • Email Scam
    • Vista Quest
    • Windows 7
  • Pictures
    • Instagram
  • Music
  • Friday Funnies
  • General
    • CoWorking
    • Gadgets
    • Politico
    • Random – TidBit
    • Rant
    • Review
    • Site of the Week
    • Useless
    • Xbox
      • Games
You are here: Home / Coldfusion / CSS – Long URL

CSS – Long URL

June 10, 2009 By Robert Owen

This is an older post that did not make it through to the new site when I converted to WordPress. Hopefully this will still be relevant to someone out there.

CSS and the Long URL:

I was working on a webmail client a while back and had been having a few design problems. Sometimes when you subscribe to a blog, forum or usergroup the e-mails from those respective subscriptions will include an “unsubscribe url”. This Blog does. Now this URL can be really long and, in a normal email client (Outlook, Thunderbird etc) this is a non issue. But, writing a webmail client this became an issue.

In Firefox, if the url is longer than the width of the div area it would break my layout. In IE the long url would wrap to the next line as expected. The only Fix I could find for this was

#mail {
letter-spacing: normal;
vertical-align: top;
word-spacing: normal;
white-space: -moz-pre-wrap;
overflow: hidden;
word-wrap: break-word;
width: 765px;
}

The “white-space: -moz-pre-wrap” setting behaves the same as “pre”, with one exception, the line-wrapping control is returned to the browser when the browser needs it (such as the browser window boundary or something similar) Tabs, multiple spaces and existing line-feeds are also honored as well.

This didn’t completely fix my problem, it did preserve my layout but now the url extends past the boundary across other content. So, I added the “overflow: hidden” This addition is as close as I can find to make this work, with that added into the css property now anything that extends past my div boundary is hidden but the entire hyperlink is preserved.

If anyone knows of a better fix for firefox please feel free to leave a comment and let me know.

© 2009, Robert Owen. All rights reserved.

Related posts:

Default ThumbnailCFX_PFPro_Java Download – Finally Default ThumbnailGotCFM? Default ThumbnailUpload Files with Coldfusion.. It’s Simple!! Default ThumbnailSimple Pop-up Window

Filed Under: Coldfusion, Web Design Tagged With: Blog, Browser Window, Client Outlook, Css Property, Email Client, Firefox, Hidden Word, Hyperlink, Line Feeds, Lt, Mail Letter, MicroSoft, Overflow, Subscriptions, Tabs, Thunderbird, Unsubscribe, Url, Webmail Client, White Space, Word Width, Word Wrap

Robert Owen A Horn Player turned salesman, turned Computer Consultant & Horn Player, Turn Network Engineer & Horn Player, Now Technology leader & Musician.... Well, How about a Horn player who does a lot of other stuff? More about me. FacebookInstagramLinkedInTwitter

To Stay up-to-date on all of my crazy Ramblings, enter your e-mail address below.

You'll be amazed!

Recent Posts…

  • What If? – Gig Edition
  • Feedback – two way street
  • Snow-pocalypse… and Cold
  • Snow-pocalypse 2025 – part 6
  • Snow-pocalypse 2025 – part 5

Recent Comments

  • David Gray on Create a Shortcut to open in your Alternate BrowserTwelve years on, this tip remains useful. Though I…
  • Sue K on Use the Snipping Tool to Capture MenusThanks you so much! I could never figure out how t…
  • aa on Increase IIS File Upload LimitsSuperb Robert..after wasting 2 days..this is perfe…
  • León on Windows 7 error 86Funciono para Windows 7 , también descubrí que la…
  • Nicole Larkin on Use the Snipping Tool to Capture MenusNine years later and your post is still helpful. T…

[footer_backtotop]
Content Copyright © 2025 OWEN CONSULTING · All Rights Reserved · Log in