Word wrap not working in firefox, tried everything

放肆的年华 提交于 2019-12-13 07:52:58

问题


Hello I'm so utterly confused and I've searched around here for hours and tried everything, yes including rules specific for FF.

Here is my current class.

.paste_body
{
float: left;
width: 100%;
margin-top: -30px;
margin-bottom: -10px;
word-wrap: break-word;
}

Before everyone goes on and starts giving me advice could you please take the time to real time CSS edit via inspect elm in fire fox to actually correctly answer this? because I've tried it all.

The URL is: skidpaste.org/QMGm3uOX

EDIT: Keep in mind this works in every other browser.


回答1:


This happens because Firefox doesn't know where to create a line break since you don't have any spaces in your text strings. Although I tried your page in Chrome, and it "works", it certainly doesn't look very good...

Here is a link on how to deal with this in CSS:

http://css-tricks.com/almanac/properties/w/word-break/



来源:https://stackoverflow.com/questions/19869653/word-wrap-not-working-in-firefox-tried-everything

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!