
|
View Full Version : Text in Firefox
myself1982 04-24-2006, 10:02 AM On my pages I have my title in H1 tag and text below it in H3 or H4, in IE it looks fine but in FF it doesn't, its all much smaller then it should be.
Is this just a FF thing?
I cant post url as its an adult site.
Thnx
well the problem is with your coding, check http://www.w3.org
myself1982 04-24-2006, 10:16 AM But it shows up properly in IE and everything else is fine in FF, I dont see how its the coding as its just a H1 and H3 tag.
Also, it isnt a big problem or anything but from SEO purposes will it matter? It shows up as H1 in IE so will that mean the bot see's it as H1 even if it doesn't in FF?
myself1982 04-24-2006, 10:49 AM This is the code thats used, btw
<h1><b><u>TEXT </u></b></h1>
<h4>TEXT HERE.</h4>
bluedreamer 04-24-2006, 02:24 PM Have you specified a font size for your <h1> tag in your style sheet?
myself1982 04-24-2006, 03:31 PM I'm not using a style sheet.
Amdac 04-24-2006, 04:27 PM But it shows up properly in IE...
It's probably the other way around. IE is usually the defective browser. The problem can be solved by setting a font size that's makes both happy.
myself1982 04-24-2006, 05:50 PM It shows up exactly how I want it to show up tho in IE.
What do you mean by font size both are happy with? Don't both/one read font sizes properly?
its all much smaller then it should be.What does that mean? How "small" should it be? The answer is: that's not up to you when you use the approaches in your example.
Basically you're blaming the browser for not reading your mind about how you want your invalid HTML to be interpreted. The solution is to use a valid approach to formatting your text.
I'm not using a style sheet.
You can still use style attributes and DIV elements to control much of how your text is displayed.
This might help: http://www.w3.org/TR/html4/struct/global.html#h-7.5.5
myself1982 04-24-2006, 06:38 PM Basically you're blaming the browser for not reading your mind about how you want your invalid HTML to be interpreted.
]
So why does it show up PERFECTLY in IE?
And how is using a H1 tag or H4 tag invalid?
: that's not up to you when you use the approaches in your example.
What? I don't understand that.
In my example I simply use the H1 or H4 tag, how is that wrong or invalid? When using that tag the text should come up the right size, it DOES in IE but doesn't in FF, not like it doesn't work in both.
So if using the H1 tag that works in IE to make my text H1 size in FF isn't valid then how is it done? You saying using the H1 tag is wrong?
So why does it show up PERFECTLY in IE?
Coincidence. The browser's programmers decide how to display headings. IE happens to be doing what you have in mind (perhaps because it's what you're used to), so to you they're doing it "perfectly," but could have just easily taken a different approach.
Neither browser is doing it "wrong," they're just doing it differently.
So if using the H1 tag that works in IE to make my text H1 size in FF isn't valid then how is it done? You saying using the H1 tag is wrong?
The point is, there is no defined "H1 size." And no defined "H4 size." You have expectations that are not met in HTML specifications -- which, though, do offer ways to achieve a level of control that would probably do what you want.
myself1982 04-24-2006, 07:06 PM Well, I am little confused I must admit.
So how do I fix it? Style sheet?
Thanks
So how do I fix it? Style sheet?
That'd be one approach. As I mentioned before, you can use style attributes inline without having to use an external style sheet if you don't want to do that for some reason. More information is on the page that I linked to.
myself1982 04-25-2006, 08:31 AM Right, think I gotcha, I put in
<HEAD>
<TITLE>... document title ...</TITLE>
<STYLE type="text/css">
H1 { font-style: italic; color: green }
H2 { color: green }
</STYLE>
</HEAD>
That correct? Obviously changing font colour etc to what I want it to be.
Thnx
bluedreamer 04-25-2006, 11:21 AM You've got it, the style sheet/CSS will control the formatting in both browers
myself1982 04-26-2006, 07:09 AM Ok, I tried that and it still didn't work so am guessing something else isn't right in the code, as I said its an adult page so anyone willing to let me PM them the link to take a quick look at it for me pls?
Thanks
Amdac 04-26-2006, 02:40 PM Try specifying a font size in the CSS code, it should overwrite the browser's default.
h1 {
font-size: 12px;
}
myself1982 04-26-2006, 05:48 PM Thanks
One question tho, whats the point of using H1 tags then if you canjust specify a font size in the first place without the tag?
One question tho, whats the point of using H1 tags then if you canjust specify a font sizeSimple enough: they're supposed to be used to indicate headings of a document, section, paragraph, whatever... not simply as a way to get different font sizes.
spiderfine 04-26-2006, 10:51 PM myself 1982, i know this seems weird to you, but you've got to understand that there are times when i'm coding that it looks perfect in ff and very wrong in ie. it just so happens that this time for you, it's the other way around. that will happen in coding html for different browsers. one thing i've learned is that ie is so easy (at times) to code for b/c it's not exactly correct - if that makes any sense - but to code for ff and say opera, you have to make sure your code is absolutely correct b/c it reads it and displays it the way it's coded. so there are no mistakes. ie has a mind of its own and alot of times that's not good. it just so happened to be good for you this time. give it some time in the future, you'll see. i speak from experience. they're not reading it wrong, only differently, that's is correct!
myself1982 04-27-2006, 12:35 PM Thanks
Got a small new problem
www.discusssport.com/test/test.html
I have sorted out the H1 and H2 tag sizes, thing is the H2 tag shows up as bold for some reason even tho I haven't bolded it?
Amdac 04-27-2006, 09:08 PM Thanks
Got a small new problem
www.discusssport.com/test/test.html
I have sorted out the H1 and H2 tag sizes, thing is the H2 tag shows up as bold for some reason even tho I haven't bolded it?
That link gives me a 404 error.
Fixago 04-27-2006, 11:13 PM You should always specify the font sizes using a style sheet, like so:
<style type="text/css">
body {
font-size:62.5%;
font-family:Verdana, Arial, Helvetica, sans-serif;
}
p {
font-size:1.2em;
padding:0;
margin:0 0 15px 0;
}
h1 { font-size:1.8em; padding:0; margin:0; }
h2 { font-size:1.7em; padding:0; margin:0; }
h3 { font-size:1.6em; padding:0; margin:0; }
h4 { font-size:1.5em; padding:0; margin:0; }
h5 { font-size:1.4em; padding:0; margin:0; }
h5 { font-size:1.3em; padding:0; margin:0; }
</style>
Give that a try, they both should look exactly the same in both browsers. I noticed that Firefox and Internet Explorer deal with paragraph and header spacing differently, one puts the spacing on top, the other on the bottom, this clears that and makes it so it looks the same in both.
|