Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3

Thread: netscape....:-(

  1. #1
    New to the CF scene
    Join Date
    Oct 2003
    Location
    San Sebastian
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    netscape....:-(

    Hello, I´m new at this forum. I have some trouble with netscape, in fact, I don´t know how can I do the same alert, window.confirm, window.open and other functions that work fine with IE into NS. Could anyone help me , please?
    Any help will be welcome.



    //There are 10 kind of people who know binary: who knows it, and who doesn´t know.//

  • #2
    Regular Coder
    Join Date
    Sep 2002
    Location
    Surrey, UK
    Posts
    119
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Need to have a little example of what's going wrong. Those functions are perfectly functional in netscape.

  • #3
    New to the CF scene
    Join Date
    Oct 2003
    Location
    San Sebastian
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts
    var agt=navigator.userAgent.toLowerCase();
    var ie = (agt.indexOf("msie") != -1);
    var ns = (navigator.appName.indexOf("Netscape") != -1);
    var win = ((agt.indexOf("win")!=-1) || (agt.indexOf("32bit")!=-1));
    var mac = (agt.indexOf("mac")!=-1);

    if (ie && win) { pluginlist = detectIE("Adobe.SVGCtl","SVG Viewer")
    + detectIE("SWCtl.SWCtl.1","Shockwave Director")
    + detectIE("ShockwaveFlash.ShockwaveFlash.1","Shockwave Flash")
    + detectIE("rmocx.RealPlayer G2 Control.1","RealPlayer")
    + detectIE("QuickTimeCheckObject.QuickTimeCheck.1","QuickTime")
    + detectIE("MediaPlayer.MediaPlayer.1","Windows Media Player")
    + detectIE("PDF.PdfCtrl.5","Acrobat Reader")
    + detectIE("ADView.Adviewer.1","Autodesk Express Viewer Control"); }



    if (ns || !win) {
    nse = ""; for (var i=0;i<navigator.mimeTypes.length;i++) nse += navigator.mimeTypes[i].type.toLowerCase();
    pluginlist = detectNS("image/svg-xml","SVG Viewer")
    + detectNS("application/x-director","Shockwave Director")
    + detectNS("application/x-shockwave-flash","Shockwave Flash")
    + detectNS("audio/x-pn-realaudio-plugin","RealPlayer") + detectNS("video/quicktime","QuickTime")
    + detectNS("application/x-mplayer2","Windows Media Player") + detectNS("application/pdf","Acrobat Reader")
    + detectcNS("application/dwf","Autodesk Express Viewer");
    }

    function detectIE(ClassID,name) { result = false; document.write('<SCRIPT LANGUAGE=VBScript>\n on error resume next \n result = IsObject(CreateObject("' + ClassID + '"))</SCRIPT>\n'); if (result) return name+','; else return ''; }
    function detectNS(ClassID,name) { n = ""; if (nse.indexOf(ClassID) != -1) if (navigator.mimeTypes[ClassID].enabledPlugin != null) n = name+","; return n; }

    pluginlist += navigator.javaEnabled() ? "Java," : "";
    if (pluginlist.length > 0) pluginlist = pluginlist.substring(0,pluginlist.length-1);

    function fullwin(targeturl){
    window.open(targeturl,"","fullscreen,scrollbars")
    }


    self.moveTo(0,0);self.resizeTo(screen.availWidth,screen.availHeight);

    function displayWindowInfo() {
    alert("plug in Flash instalado");
    }

    if (pluginlist.indexOf("Acrobat Reader")!=-1){
    alert("Comprobación de plug-in Acrobar Reader correcta.")
    }else{
    window.confirm("Para la correcta visualizacion de algunas partes del cd, es necesario que instale en su equipo la siguiente aplicación: AcroReader51_ESP.exe")
    open("controles/AcroReader51_ESP.exe")
    //window.reload
    }
    if (pluginlist.indexOf("Windows Media Player")!=-1){
    alert("Comprobación de plug-in Windows Media Player correcta.")
    }else{
    window.confirm("Para la correcta visualizacion de algunas partes del cd, es necesario que instale en su equipo la siguiente aplicación: MPSetup.exe")
    open("cotroles/MPSetup.exe")
    }
    if (pluginlist.indexOf("Shockwave Flash")!=-1){
    alert("Comprobación de plug-in Shockwave Flash correcta.")
    }else{
    window.confirm("Para la correcta visualizacion de algunas partes del cd, es necesario que instale en su equipo la siguiente aplicación: Install Flash Player 6.exe")
    open("controles/Install Flash Player 6.exe")
    }
    if (pluginlist.indexOf("Autodesk Express Viewer")!=-1){
    alert("Comprobación de plug-in Autodesk Express Viewer correcta.")
    }else{
    window.confirm("Para la correcta visualizacion de algunas partes del cd, es necesario que instale en su equipo la siguiente aplicación: ExpressViewerSetup.exe")
    open("controles/ExpressViewerSetup.exe")
    }
    if((pluginlist.indexOf("Acrobat Reader")!=-1)&&(pluginlist.indexOf("Windows Media Player")!=-1)&&(pluginlist.indexOf("Shockwave Flash")!=-1)&&(pluginlist.indexOf("Autodesk Express Viewer")!=-1)){
    window.close('detector de plugins.htm')
    fullwin ('presentacion.htm','scroll:no')
    }else{
    window.open("detector de plugins.htm","self")

    }




    That´s the entire code I´m using. I load an .htm from a .js, but when I try it whit netscape, it stops and does nothing. I don´t know what´s wrong, do you?


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •