You need to sign in to do that
Don't have an account?
Marris
IE 8 Conditional Statement error
Hi all,
I code the comment for IE8 in visualforce page as follows
<!--[if lt IE 8]> <link rel="stylesheet" href="{!URLFOR($Resource.Styles,'/css/portal.css')}"/> <![endif]--> <!--[if IE]> <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script> <![endif]-->
It works well but <!--[if lt IE 8]> <![endif]--> <!--[if IE]> displays in the top of the page.
Please Provide me a solution
Thanks
Marris
Hi all
Previously i coded the comment like this
But it doesnt work that IE 8 CSS doesnt executed. So Please provide me a solution
Thanks
Marris
Hello Marris,
I think you could detect the browser using jQuery.
Link : jQuery Browser Detection
And for including the Javascipt or CSS file you would need to create a file and attach it to the needed place for eg:head, body, any other tag.
for example on adding the Script to page, refer :
http://javascript.about.com/library/bladdjs.htm
Include Js or CSS .
Hello Rahul
My code below works well for IE8 browser but in my page i seen this tag <!--[if lt IE 8]> <![endif]--> <!--[if IE]> at top. Can you please provide me a solution for not getting this tag at top. Code is as follows
Thanks
Marris
Hi Marris,
I tried to use your code to debug whether its going in the if loop or not.
but this does not work for me, try alerting the conditions and check if the if condition is executed or not..