Determine if Browser uses IFrame mode

Last post 12-19-2012, 5:51 AM by Wompi. 2 replies.
Sort Posts: Previous Next
  •  12-18-2012, 9:39 AM 75478

    Determine if Browser uses IFrame mode

    Hi,

     

    we added our own progress text with calculation about the rest time in the format hh:mm:ss like it is shown here:

    http://cutesoft.net/forums/post/63856.aspx

     

    For IE in IFrame mode the custom progress calculation is not possible because there isn't any possibility to get the file size. If I activate the built-in template for upload progress then it works slow but fine but the rest time is in seconds.

     

    Is there a possibilty to determine on server or client side if the uploader runs in IFrame mode and then show the built-in upload template?

     

    Thanks

    Mark

  •  12-18-2012, 3:45 PM 75479 in reply to 75478

    Re: Determine if Browser uses IFrame mode

    Hi,

     

    you can try the code below. It will detect the browser has the silverlight/flash or not. If not, it means the uploader will load as the htlm5/ifream mode.

     

    1. <script> 
    2. function CuteWebUI_AjaxUploader_OnBrowse() 
    3.     uploader=this
    4.     var scope=uploader.internalobject; 
    5.         if(!scope.addontype) 
    6.         { 
    7.                 alert('you must installed Flash/Silverlight or use Chrome etc..'); 
    8.                 return false
    9.         } 
    10. </script> 
     

    Regards,

     

    Ken

  •  12-19-2012, 5:51 AM 75483 in reply to 75479

    Re: Determine if Browser uses IFrame mode

    Hi,

     

    thank you very much, it is working great.

     

    Regards

    Mark

View as RSS news feed in XML