By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,713 Members | 1,503 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,713 IT Pros & Developers. It's quick & easy.

ie7

P: 1
hello,
i've some problems with ie7. The dhtml menu that i've downloaded from the net doesn't work at all. I can't see it on the page.
can somebody help me?
this is my script:

function lib_bwcheck(){ //Browsercheck (needed)
this.ver=navigator.appVersion
this.agent=navigator.userAgent
this.dom=document.getElementById?1:0
this.opera5=this.agent.indexOf("Opera 5")>-1
this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom && !this.opera5)?1:0;
this.ie6=(this.ver.indexOf("MSIE 6")>-1 && this.dom && !this.opera5)?1:0;
this.ie4=(document.all && !this.dom && !this.opera5)?1:0;
this.ie=this.ie4||this.ie5||this.ie6||
this.mac=this.agent.indexOf("Mac")>-1
this.ns6=(this.dom && parseInt(this.ver) >= 5) ?1:0;
this.ns4=(document.layers && !this.dom)?1:0;
this.bw=( this.ie6 || this.ie5 || this.ie4 || this.ns4 || this.ns6 || this.opera5)
return this
}
var bw=new lib_bwcheck()




FoldNumber = 5 //How many toplinks do you have?
var stayFolded = false //Stay open when you click a new toplink?
foldImg = 1 //Do you want images (if not set to 0 and remove the images from the body)?
mainOffsetY = 10 //Vertical space adjustment between the main items, in pixels.

thank you!
luka
Feb 13 '07 #1
Share this Question
Share on Google+
1 Reply

acoder
Expert Mod 15k+
P: 16,027
You're not checking for ie7, so it is never going to work. Browser sniffing is very unreliable. I would always suggest object detection instead.
Feb 13 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.