Solved

dropbox issue

Posted on 2014-12-04
5
101 Views
Last Modified: 2014-12-04
Hello,
  My company block dropbox from within our network.

Here is the script::

<script type="text/javascript" src="https://www.dropbox.com/static/api/2/dropins.js" id="dropboxjs" data-app-key="<%=ApiKeySettings.DropboxAppKey%>"></script>

Open in new window


Is it possible to download the dropins.js file to local machine?

Thanks
0
Comment
Question by:SiemensSEN
5 Comments
 
LVL 37

Expert Comment

by:Neil Russell
ID: 40480766
If it is blocked then it is blocked.  It is blocked for a reason and you need to take that up with your IT team.
EE is not allowed to help you to get around your companies security policies I am afraid.
0
 
LVL 33

Expert Comment

by:Big Monty
ID: 40480813
check with your IT department and find out why they have it blocked. if you're working on a company application that uses dropbox, explain that to them and see if they can make an exception.

if the script itself doesn't make any connection to dropbox, then ask them to download it for you so you can put it on your system. if it does interface with dropbox, then there is no way to use it without getting your IT department involved
0
 

Author Comment

by:SiemensSEN
ID: 40480836
OK. is there a  function to test if Dropbox is allowed/blocked.  If it is not allow then don't load the javascript.. is that possible. Currently, I have to wait until it time out
0
 
LVL 33

Expert Comment

by:Big Monty
ID: 40481138
if you use jquery, you can use the getScript() function

http://api.jquery.com/jQuery.getScript/
0
 
LVL 10

Accepted Solution

by:
Hans Langer earned 500 total points
ID: 40481330
Check the domain access first and if it is ok then attach the script:

$.ajax({
  url  : 'http://www.dropbox.com',
  type : 'post',
  data : 'a=b',
  timeout:3000 //3 seconds
}).done(function(data, statusText, xhr){
  if(xhr.status==200){ //200==OK 
  //ADD SCRIPT TO YOUR PAGE
   var script = document.createElement( 'script' );
   script.type = 'text/javascript';
   script.src = 'https://www.dropbox.com/static/api/2/dropins.js';
   $("head").append( script );
  }
});

Open in new window

0

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

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

Suggested Solutions

Today I would like to talk about localizing (Internationalization) JavaScript applications. Introduction When creating an application that is going to be used by many people around the globe, it is important to remember that not everyone speak…
This article will give core knowledge of JavaScript and will head in to your first JavaScript program. I am Durvesh Naik and I am here to deal with this series of JavaScript. I will teach you JavaScript in part wise , as its quite boring to read big…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

785 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