[thelist] apply PRE formatting with css?
nate koechley
nate at vicksburgcollective.com
Thu Aug 30 20:41:09 CDT 2001
hey all,
i was wondering if there was a way to achieve this:
<div><pre>
source code
</pre></div>
without the <pre> tags. in other words, can I apply "pre" formatting by
using CSS? I'm tyring to find the best way to display source code on a
page. is there a best practice out there to display source code on the page?
on a related note, does anybody have a script or homesite extension form
translating all the [< ] to [ < ] (acutally, all the carets, quotes,
etc...)?
tia,
nate
<tip type="netscape DOM" author="nate koechley">
to access a nester layer in netscape, use this syntax:
NS4.* // document.PARENT_LAYER_NAME.layers[which].visibility = 'visible';
for the others (IE4, IE5,6, NS 6) the PARENT_LAYER_NAME isn't necessary
because you can access the div by name/id directly, as shown in the
following two lines:
IE4 // document.all[which].style.visibility = 'visible';
IE/NS 5/6 // document.getElementById(which).style.visibility =
'visible';
</tip>
More information about the thelist
mailing list