|
This will make a PM bar similair to the one SL Inspire is using. There are 2 parts for this code, one which you can modify to fit your PM likings, and the other to actually add the PM bar =P. Here's the part which you may edited, make sure it is ABOVE the other part in your headers.
<style type='text/css'> .Divi{ border:1px solid #000000; padding: 5px; width: 92%; background-color:#ffffff; position:relative; left:40px; } </style>
width: = for the width of the PM bar. background-color: = for the background color of the PM bar. left: = for the positioning of the PM bar. Headers (beneath the first part of the code) <script type="text/javascript"> /* Inspire PM Bar Created by CrazY_J Do not redistribute without the creator's permission */ function GetElem( elem ) { if( elem.nodeType != "3" ) return document.body.getElementsByTagName( elem ) }
var Cell = GetElem( "td" )[2]; var Break = GetElem( "br" )[4];
var User = ( Cell.innerHTML.match(/Hey/))? true:false; var New = ( Cell.innerHTML.match(/,\s(\d+)\s(is|are)/))? RegExp.$1:false;
/*--*/ if(User) var Ms = "<b>Welcome Back</b> - <a href='/index.cgi?action=im'>Inbox ("+New+")</a> - <a href='/index.cgi?action=notifyshow'>Monitored Topics</a>" else if(!User) var Ms = "<i>Guest Menu</i>: <a href='/index.cgi?action=register'>Register</a> - <a href='/index.cgi?action=login'>Login</a>" /*--*/
var Div = document.createElement( "div" ) var cBreak = document.createElement( "br" ); Div.className = 'Divi'; Div.innerHTML += Ms document.body.insertBefore( cBreak , Break ) document.body.insertBefore( Div , Break )
</script>
Last Edit: Jun 30, 2006 21:14:05 GMT by Chris
|
|
|