Goonie
05-12-2003, 12:34 AM
What HTML code do i use to show code on a webpage?
Any examples out there that i can see?
Any examples out there that i can see?
|
Click to See Complete Forum and Search --> : Html code? Goonie 05-12-2003, 12:34 AM What HTML code do i use to show code on a webpage? Any examples out there that i can see? Bullschmidt 05-12-2003, 01:12 AM My favorite is to simply change the less than character which is the first part of every tag to be < instead. nkaisare 05-12-2003, 08:47 AM Originally posted by Dave Clark You may be able to use the <PRE></PRE> tags for this, too. You still need " < and > for ", < and > respectively, don't you? Bullschmidt 05-12-2003, 01:59 PM < seems to be enough for me, and I do like to keep things simple. But no, I don't believe you'd need this if you used the <pre> and </pre> tags, but then you might lose some formating of how things look. nkaisare 05-12-2003, 02:17 PM Two examples I tried: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <title></title> <meta http-equiv="content-type" content="text/html; charset=iso-8859-1"> </head> <body> <pre><b>This is some bold text</b>.</pre> <p>As you can see, you need to enclose the text you need to be made bold within <b> and </b>. This is preferred way of making text visually bold-faced. If this text has to be emphasized, use <strong> and </strong> instead. Semantically, this means that this text is "spoken" more strongly than rest of the paragraph. Visually, both <b> and <strong> may look the same.</p> </body> </html> In the second example, I used <pre><b>This is some bold text</b>.</pre> No brainer that the latter worked. Former just made the PREformatted text boldface. webdeveloper.com
Copyright Internet.com Inc., All Rights Reserved. |