Jump to content

[SOLVED] NOBR width in Firefox


lemmin

Recommended Posts

What object, exactly, am I applying that CSS to?

 

I looked around and found that Firefox won't apply dimensions to objects that are displayed inline, which my nobrs are. To get around it, I set them to display as blocks and floated them next to eachother. I really hate floating things, but I can't find any other way to make this work in both IE and FF without using a table.

Link to comment
Share on other sites

What the hell is <no br /> anyway? It is one of the many stupid html tags invented. If you don't want the the text to wrap, then you make that div large enough, tell it to nowrap, or you set overflow to the appopriate level. I never found a need to use <no br /> 's. I can see why firefox has problems displaying this for you. <no br /> is an inline object (obviously) and making it display: block; is just nonsense.

Link to comment
Share on other sites

If you don't want the the text to wrap, then you make that div large enough

Firefox won't apply dimensions to objects that are displayed inline

 

Your solution is fine until I want to put the divs next to eachother; actually, the nobrs would work just the same until I want to do that. If I used a div, the code would be exactly the same except I would have to add more styles. Disregarding a tag because you have never heard of it is just nonsense.

Link to comment
Share on other sites

Yea, pretty much. I just want two objects to be inline and still be able to size them. In Internet Explorer, you put the objects inline and then size them to accomplish that, as one might expect; this doesn't work in Firefox, though. Anyway, like I said, I got around it by floating them as blocks, which is the same method that the website you linked to uses, but I never liked doing that. It seems to be the only way to keep this kind of layout cross-browser compatible, though.

 

Thanks for the help, guys.

Link to comment
Share on other sites

Disregarding a tag because you have never heard of it is just nonsense.

 

But disregarding it because it isn't valid code is entirely reasonable.

 

And <no br> is invalid code. There's a reason only IE uses it - IE is a non-standards compliant browser.

Link to comment
Share on other sites

Disregarding a tag because you have never heard of it is just nonsense.

 

I have heard of it before. I am disregarding it for a good reason. I design within the web 2.0 expectations and standards. In doing so, I separate by content - html - and presentation - css. <no br> is not content. It is something that visually changes the text, to make it more pleasing to the eye. Therefore, this should go striclty under the css file. You need to understand that although it works in IE and you only may need to fudge a few things here and there to make it in FF, this is NOT a semantic way to go around doing it. - You can make a turd shine brighter, but it still is a turd.

 

Typically, I would give you a solution now, but I'm tired of people sticking me in the back by calling my remarks 'nonsense.' I have done quite a lot of development work and have never used silly things as <no br>

Link to comment
Share on other sites

<nobr> is perfectly valid, it is just not "accepted" by w3c.

 

Which is what makes it not valid!

 

It works fine in every browser I have ever used.

 

Then why are you having this problem? You have a standards compliant browser that isn't accepting it, and you are trying to say that it's standards compliant? Sorry, I think you will have troubles convincing anyone of that.

Link to comment
Share on other sites

I'm tired of people sticking me in the back by calling my remarks 'nonsense.'

[...] and making it display: block; is just nonsense.

Do unto others?

 

Then why are you having this problem? You have a standards compliant browser that isn't accepting it, and you are trying to say that it's standards compliant? Sorry, I think you will have troubles convincing anyone of that.

You need to understand that although it works in IE and you only may need to fudge a few things here and there to make it in FF, this is NOT a semantic way to go around doing it.

What you two don't seem to understand is that the <nobr> tag works exactly as expected in both browsers. As I said before, the question wasn't intended to be about nobrs. I just wanted to know how to fix a size to an inline object in FF, which can't be done. Thanks for the help, though.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.