Solved

I'm trying to write a code that displays an alternate image gallery for those using IE 6 and below

Posted on 2011-03-04
3
326 Views
Last Modified: 2013-12-08
I'm trying to write a code that displays an alternate image gallery for those using IE 6 and below. Right now, I'm just testing it with a document.write command before moving on. It's (obviously) not working. Here's what I have:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>One World Circus</title>
</script>

<script type="javascript">
var browser = navigator.appName
var ver = navigator.appVersion
var thestart = parseFloat(ver.indexOf("MSIE"))+1
var brow_ver = parseFloat(ver.substring(thestart+4,thestart+7))
var test=new iesuckstest({
      wrapperid: "iesucks",
      dimensions: [490, 327],

if ((browser=="Microsoft Internet Explorer") && (brow_ver < 7))

(
document.write("Testing");
)
})

</script>
</head>

<body>

<div id="iesucks">
</div>
</body>
</html>
0
Comment
Question by:jgosney
3 Comments
 
LVL 75

Accepted Solution

by:
Michel Plungjan earned 250 total points
ID: 35042202
http://www.quirksmode.org/css/condcom.html
<script type="javascript">
var test=new iesuckstest({
      wrapperid: "iesucks",
      dimensions: [490, 327]
}
</script>

.
.
.
<!--[if lte IE 6]>

<div id="iesucks">
According to the conditional comment this is Internet Explorer equal or lower than 6<br />
</div>
<script>
document.write("Testing");
</script>
<![endif]-->

Open in new window

0
 
LVL 27

Expert Comment

by:Tolomir
ID: 35422495
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Grunt Copy file to another destination. 1 37
move widget title down 4 20
remove all history 3 31
Two wordpress questions 3 46
Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
This article will inform Clients about common and important expectations from the freelancers (Experts) who are looking at your Gig.
Viewers will get an overview of the benefits and risks of using Bitcoin to accept payments. What Bitcoin is: Legality: Risks: Benefits: Which businesses are best suited?: Other things you should know: How to get started:
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question