Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Internet Explorer 6 Warning
#1
Hello,

Been trying to find an easy way to check the visitor's browser, warn if it is Internet Explorer 6 and present some options.

This solution works for me:

<!--[if lt IE 7]>
<div style='border: 1px solid #F7941D; background: #FEEFDA; text-align: center; clear: both; height: 75px; position: relative;'>
<div style='position: absolute; right: 3px; top: 3px; font-family: courier new; font-weight: bold;'><a href='#' onclick='javascript:this.parentNode.parentNode.style.display="none"; return false;'><img src='<?php get_theme_url(); ?>/images/ie6/ie6nomore-cornerx.jpg' style='border: none;' alt='Close this notice'/></a></div>
<div style='width: 840px; margin: 0 auto; text-align: left; padding: 0; overflow: hidden; color: black;'>
<div style='width: 75px; float: left;'><img src='<?php get_theme_url(); ?>/images/ie6/ie6nomore-warning.jpg' alt='Warning!'/></div>
<div style='width: 520px; float: left; font-family: Arial, sans-serif;'>
<div style='font-size: 18px; font-weight: bold; margin-top: 12px;'>You are using an outdated and insecure browser!<br />Our website no longer supports Internet Explorer 6 & 7.</div>
<div style='font-size: 16px; margin-top: 6x; line-height: 18px;'>Please upgrade to a modern web browser or stop browsing the internet.</div>
</div>
<div style='width: 75px; margin-top: 3px; float: left;'><a href='http://www.google.com/chrome' target='_blank'><img src='<?php get_theme_url(); ?>/images/ie6/ie6nomore-chrome.jpg' style='border: none;' alt='Get Google Chrome'/></a></div>
<div style='width: 75px; margin-top: 3px; float: left;'><a href='http://www.firefox.com' target='_blank'><img src='<?php get_theme_url(); ?>/images/ie6/ie6nomore-firefox.jpg' style='border: none;' alt='Get Firefox'/></a></div>
<div style='width: 73px; margin-top: 3px; float: left;'><a href='http://www.apple.com/safari/download/' target='_blank'><img src='<?php get_theme_url(); ?>/images/ie6/ie6nomore-safari.jpg' style='border: none;' alt='Get Safari'/></a></div>
</div>
</div>
<![endif]-->



How it would look:
[Image: ie6.png]

How to setup:

1.Download the attached file ie6.zip, extract the folder and upload it into your "theme/<theme_name>/images" folder.
2.In Admin Panel, go to Theme Management.
3.Edit header.inc.php
4.Search for </head>
In my theme.inc.php I have:
</head>
<body id="<?php get_page_slug(); ?>">
5.Right after <body id="<?php get_page_slug(); ?>"> on a new line, copy paste the solution from above.
6.Save and test.
You can test your website online using NetRenderer

Tips:
Please edit the text before going live.

Have fun and hope you find it useful.


Attached Files
.zip   ie6.zip (Size: 11.86 KB / Downloads: 4)
Reply


Messages In This Thread
Internet Explorer 6 Warning - by inteq - 2014-10-23, 12:11:43
RE: Internet Explorer 6 Warning - by shawn_a - 2014-10-24, 09:32:18
RE: Internet Explorer 6 Warning - by inteq - 2014-10-24, 14:35:24
RE: Internet Explorer 6 Warning - by paknoukri - 2015-07-05, 04:25:42
RE: Internet Explorer 6 Warning - by revotron - 2015-07-18, 21:27:40



Users browsing this thread: 1 Guest(s)