• Alright so I want one certain page on a website to emulate under the style of IE7 but the rest of the site to emulate IE8. How do I do this through the meta tags? I was trying the following with no results:

    if(is_page('IE7 page')){
     <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7,chrome=1">;
     }
    else{
     <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8,chrome=1">;
     }

    What exactly am I doing wrong and how do I implement this correctly? Any help will be greatly appreciated! ??

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hello,
    Try this:

    if(preg_match('/MSIE 7.0/i',$_SERVER['HTTP_USER_AGENT']))
    {
    	// Codes for just ie7
    } else {
    	// other versions of ie and other browsers
    }

    Thread Starter ZackVee

    (@zackvee)

    <head>
    if(preg_match('/MSIE 7.0/i',$_SERVER['HTTP_USER_AGENT']))
    {
    <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7,chrome=1"> // Codes for just ie7
    } else {
    <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8,chrome=1">        // other versions of ie and other browsers
    }

    Didn’t seem to work, it just added the above text to the header bar. I realize I forgot to mention this is in the head content.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Setting custom meta only on one page?’ is closed to new replies.