|
Posted by Martin Clark on 03/24/06 18:25
Jim Moe wrote...
>Greg N. wrote:
>> Suppose you need a heading <h1>Huddersfield Canal Society</h1> to be
>> rendered as two lines. The result you want to see is:
>> Huddersfield
>> Canal Society
>> It can be fudged by marking it up as
>> <h1>Huddersfield<br>Canal Society</h1>
>>
[snip]
>
> Is it the two line appearance you actually want? The <br> is best for that.
> Or are you just avoiding some messy text wrapping as the viewport width
>narrows? Then you could put a in between Canal and Society. That
>whole line of text would wrap as a unit.
>
Sorry folks - I hadn't noticed that the discussion of this had moved to
a new thread!
Initially, the white text stayed on one line, so that at 800x600 it
overlapped the right-hand banner photo. Not the end of the world, but
not what I wanted. Several of the suggestions that were put forward
resulted in solutions where, at some widths, text jumped down below the
images or formed 3 lines, changing the appearance of the header area
detrimentally.
The <h1>Huddersfield</h1><h1>Canal Society</h1> solution produced the
best result up to that point, where the text stayed within the original
height of the header area and only overlapped the photo at about 700px
width, which few people would see in the normal course of events.
I didn't understand quite why Spartanicus was so angry at the
"butchering" of his code by whoever suggested that solution, but having
read this thread I now do understand that it is regarded as incorrect to
turn it into what is in effect two headings.
However, <h1>Huddersfield<br>Canal Society</h1> produces exactly the
same effect and that is what I am going with:
http://www.tamevalley.freeserve.co.uk/hcs/index.htm
I am pleased with the way the page works and hope it does not offend the
purists!
What does style="white-space:pre;" do please, as suggested by BootNic?
--
Martin Clark
Navigation:
[Reply to this message]
|