apparition
Technical User
I wrote a script to detect what version of the acrobat reader a browser has. I want to use javascript but it does not work for Internet Explorer. The only way I've found to do it is with vbscript.
Does anyone know how to detect what version of acrobat reader is installed in IE with javascript???
Here is what I have now:
<script language="javascript" type="text/javascript">
<!--
browser='OTHER';
if (navigator.appName=='Microsoft Internet Explorer')
{
browser='MSIE';
}
if (navigator.appVersion.indexOf('MSIE 3')>0)
{
browser='MSIE';
}
if (browser=='OTHER')
{
var acrmode = false
acrPlugin = navigator.plugins['Adobe Acrobat'];
if (acrPlugin.description == 'Adobe Acrobat Plug-In Version 5.00 for Netscape')
{
acrmode = true
}
}
//-->
</script>
<script language="vbscript" type="text/vbscript">
<!--
on error resume next
var acrmode
acrmode = IsObject(CreateObject("pdf.pdfctrl.5")
-->
</script>
<script language="javascript" type="text/javascript">
<!--
function acrobatCheck()
{
if (acrmode){
}
else{
if (confirm('For best results, it is recommended that you open this file with the Adobe Acrobat 5 Reader. It appears you do not have the latest version installed. Would you like to download it now?'))
{
window.location='../mit/tsd/dl_acr.htm';
return false;
}
else
{
return true;
}
}
}
//-->
</script>
Does anyone know how to detect what version of acrobat reader is installed in IE with javascript???
Here is what I have now:
<script language="javascript" type="text/javascript">
<!--
browser='OTHER';
if (navigator.appName=='Microsoft Internet Explorer')
{
browser='MSIE';
}
if (navigator.appVersion.indexOf('MSIE 3')>0)
{
browser='MSIE';
}
if (browser=='OTHER')
{
var acrmode = false
acrPlugin = navigator.plugins['Adobe Acrobat'];
if (acrPlugin.description == 'Adobe Acrobat Plug-In Version 5.00 for Netscape')
{
acrmode = true
}
}
//-->
</script>
<script language="vbscript" type="text/vbscript">
<!--
on error resume next
var acrmode
acrmode = IsObject(CreateObject("pdf.pdfctrl.5")
-->
</script>
<script language="javascript" type="text/javascript">
<!--
function acrobatCheck()
{
if (acrmode){
}
else{
if (confirm('For best results, it is recommended that you open this file with the Adobe Acrobat 5 Reader. It appears you do not have the latest version installed. Would you like to download it now?'))
{
window.location='../mit/tsd/dl_acr.htm';
return false;
}
else
{
return true;
}
}
}
//-->
</script>