JohnBee
12-15-2004, 08:20 PM
I know there are many blinking PM hacks out here I scanned through them all
but what I cannot find is a hack that makes the words "Private Messages"
on the navbar blink in the event of a new PM.
A much simpler mod than the blinking bar or blinking background really
but I cannot get it to work.
Does anyone know how to make it work?
I have some java script for it and I can easilly get it to display anywheres on the forum homepage but I cannot get it to replace the original PM stats
line I don't know how do to that.
Heres my header script info.
<SCRIPT LANGUAGE="JavaScript">
window.onerror = null;
var bName = navigator.appName;
var bVer = parseInt(navigator.appVersion);
var NS4 = (bName == "Netscape" && bVer >= 4);
var IE4 = (bName == "Microsoft Internet Explorer"
&& bVer >= 4);
var NS3 = (bName == "Netscape" && bVer < 4);
var IE3 = (bName == "Microsoft Internet Explorer"
&& bVer < 4);
var blink_speed=100;
var i=0;
if (NS4 || IE4) {
if (navigator.appName == "Netscape") {
layerStyleRef="layer.";
layerRef="document.layers";
styleSwitch="";
}else{
layerStyleRef="layer.style.";
layerRef="document.all";
styleSwitch=".style";
}
}
//BLINKING
function Blink(layerName){
if (NS4 || IE4) {
if(i%2==0)
{
eval(layerRef+'["'+layerName+'"]'+
styleSwitch+'.visibility="visible"');
}
else
{
eval(layerRef+'["'+layerName+'"]'+
styleSwitch+'.visibility="hidden"');
}
}
if(i<1)
{
i++;
}
else
{
i--
}
setTimeout("Blink('"+layerName+"')",blink_speed);
}
// End -->
</script>
Heres my if statement code, obviously not in the right place in my navbar
template:
<if condition="$bbuserinfo['pmunread']">
<!-- Blinking text START -->
<div id="prem_hint" style="position:relative; left:0; visibility:hidden" class="prem_hint">
<font color="#FF0000"><b>Private messages</b></font>
</div>
<script language="javascript">Blink('prem_hint');</script>
</script>
</if>
Any help would be greatly apreciated on this mod.
thanks all in advance.
but what I cannot find is a hack that makes the words "Private Messages"
on the navbar blink in the event of a new PM.
A much simpler mod than the blinking bar or blinking background really
but I cannot get it to work.
Does anyone know how to make it work?
I have some java script for it and I can easilly get it to display anywheres on the forum homepage but I cannot get it to replace the original PM stats
line I don't know how do to that.
Heres my header script info.
<SCRIPT LANGUAGE="JavaScript">
window.onerror = null;
var bName = navigator.appName;
var bVer = parseInt(navigator.appVersion);
var NS4 = (bName == "Netscape" && bVer >= 4);
var IE4 = (bName == "Microsoft Internet Explorer"
&& bVer >= 4);
var NS3 = (bName == "Netscape" && bVer < 4);
var IE3 = (bName == "Microsoft Internet Explorer"
&& bVer < 4);
var blink_speed=100;
var i=0;
if (NS4 || IE4) {
if (navigator.appName == "Netscape") {
layerStyleRef="layer.";
layerRef="document.layers";
styleSwitch="";
}else{
layerStyleRef="layer.style.";
layerRef="document.all";
styleSwitch=".style";
}
}
//BLINKING
function Blink(layerName){
if (NS4 || IE4) {
if(i%2==0)
{
eval(layerRef+'["'+layerName+'"]'+
styleSwitch+'.visibility="visible"');
}
else
{
eval(layerRef+'["'+layerName+'"]'+
styleSwitch+'.visibility="hidden"');
}
}
if(i<1)
{
i++;
}
else
{
i--
}
setTimeout("Blink('"+layerName+"')",blink_speed);
}
// End -->
</script>
Heres my if statement code, obviously not in the right place in my navbar
template:
<if condition="$bbuserinfo['pmunread']">
<!-- Blinking text START -->
<div id="prem_hint" style="position:relative; left:0; visibility:hidden" class="prem_hint">
<font color="#FF0000"><b>Private messages</b></font>
</div>
<script language="javascript">Blink('prem_hint');</script>
</script>
</if>
Any help would be greatly apreciated on this mod.
thanks all in advance.