- Joined
- Nov 12, 2002
- Location
- Rootstown, OH
The BBCODE for "code" has been updated. If you use the code tags now, there will be a button that allows you to select all, to ease the process of highlighting if you want to copy the contents of the box.
Code:
<script type="text/javascript">
function selectCode(a)
{
var e = a.parentNode.getElementsByTagName('PRE')[0];
if (window.getSelection)
{
var s = window.getSelection();
if (s.setBaseAndExtent)
{
s.setBaseAndExtent(e, 0, e, e.innerText.length - 1);
}
else
{
var r = document.createRange();
r.selectNodeContents(e);
s.removeAllRanges();
s.addRange(r);
}
}
else if (document.getSelection)
{
var s = document.getSelection();
var r = document.createRange();
r.selectNodeContents(e);
s.removeAllRanges();
s.addRange(r);
}
else if (document.selection)
{
var r = document.body.createTextRange();
r.moveToElementText(e);
r.select();
}
}
</script>