To avoid my text, h-tags and pics jumping all over the place when the screen is zoomed in or out, I changed my <p> to <p style="clear:left;"> and included the h-tag in the paragraph. Works a treat in terms of fluid positioning, but it cancels out my paragraph definition in the css-file.
CSS-style code
Code:p { font-family: verdana, arial, helvetica, geneva; font-style: normal; font-size: 12pt; text-align:justify; }
HTML page code
Code:<p style="clear:left;"> <h3>Emergency plumber in Dulwich with guaranteed repairs</h3> <img src="http://www.boiler-breakdown-repair-london.co.uk/pics/modern brass stopcock.jpg" alt="repaired modern brass stopcock" width="225" height="225" style="float: left; margin: 1em 2em 1em 1em; "> <BR>Do you know anyone in <em>south east London</em> who finally managed to get a plumber to come, but had to pay a lot of money even though the problem was not solved? I guarantee that I can find the problem. That's right: guarantee, not think, try, expect, or hope. <BR>If I tell you over the phone that I can find the problem, I will, or you don't pay a penny! <BR>If these are the kind of things that you expect from <strong>emergency plumbers in Dulwich</strong>, stop searching, and put me to the test. <BR>Have you ever had it where a plumber (car mechanic, electrician or any other kind of technical chap) talked to you for 5 minutes, and you had no idea what he was on about? <BR>I know that some people are more technically minded than others, and ask frequently if things are completely clear. If they are not, I simply word them in a different way. It is your house, you should be happy with what I am doing. </p>
I can think of some makeshift ways of sorting this, but that would probably not quite considered to be neat.
What would be considered to be the correct way of doing things?



Reply With Quote







Add a border to the div and you'll see. You've set a width of 90% on the div, and margin: auto, so that centres the div on your page. However, the text doesn't extend the full width of your div, and as it's left-aligned (by default) it sits at the left side of the div. Adding text-align: center will centre it. (And I'm sure you know that using to align text is not a good idea.
)

Bookmarks