Changeset 3408


Ignore:
Timestamp:
10/25/10 10:20:41 (13 years ago)
Author:
amuller
Message:

Ticket #1379 - Evita tentar abrir o applet se não tem java

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2/filemanager/js/common_functions.js

    r3386 r3408  
    8787} 
    8888function newAdvancedUpload(){ 
    89         draw_window("<iframe width=\"515\" height=\"320\" src='/filemanager/inc/uploadApp.php?id="+parseInt(Math.random()*Math.pow(10,15))+"'></iframe>"); 
    90         document.getElementById('dwindow').style.width = "auto"; 
    91         document.getElementById('dwindow').style.height = "auto"; 
     89        for (i=0; i < navigator.plugins.length; i++) 
     90                if (navigator.plugins[i].name.match('Java')){ 
     91                        draw_window("<iframe width=\"515\" height=\"320\" src='/filemanager/inc/uploadApp.php?id="+parseInt(Math.random()*Math.pow(10,15))+"'></iframe>"); 
     92                        document.getElementById('dwindow').style.width = "auto"; 
     93                        document.getElementById('dwindow').style.height = "auto"; 
     94                        return; 
     95                } 
     96        alert(get_lang("You do not have Java installed, plugin not loaded")); 
    9297} 
    9398 
Note: See TracChangeset for help on using the changeset viewer.