- From: Toby Inkster <tobyink@goddamn.co.uk>
- Date: Wed, 21 Aug 2002 17:31:34 +0100
- To: www-html@w3.org
- Message-Id: <20020821173134.0a6bd5ab.tobyink@goddamn.co.uk>
On Wed, 21 Aug 2002 17:19:49 +0200 Lorenzo De Tomasi <lorenzo.detomasi@libero.it> wrote: | How can I make a border that is 50% of the page and centered? | and 50% of the page and left aligned? This is in XHTML 1.1 and according to the draft of XHTML 2, should be valid there as well. It's not pretty though! (Tested in Opera 6.03, Mozilla 1.1b) <?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-GB"> <head> <title>Example</title> <style type="text/css"> div.centreRule { border-top: 3px solid black; width: 50%; position: absolute; left: 25%;} div.leftRule { border-top: 3px solid black; width: 50%; position: absolute; left: 0%;} </style> </head> <body> <p>Here is some text followed by a centred division.</p> <div class="centreRule"></div> <p>Here is some text followed by a left division.</p> <div class="leftRule"></div> <p>And here is some more text.</p> </body> </html> -- Toby A Inkster BSc ARCS PGP: http://www.goddamn.co.uk/tobyink/node.cgi?id=12 Web Page: http://www.goddamn.co.uk/tobyink/ IM: AIM:inka80 ICQ:6622880 YIM:tobyink Jabber:tobyink@a-message.de There's a little picture of ED MCMAHON doing BAD THINGS to JOAN RIVERS in a $200,000 MALIBU BEACH HOUSE!!
Received on Wednesday, 21 August 2002 13:08:41 UTC