Repositorio del curso CCOM4030 el semestre B91 del proyecto Artesanías con el Instituto de Cultura

_evalUrl.js 676B

1234567891011121314151617181920212223242526272829303132
  1. define( [
  2. "../ajax"
  3. ], function( jQuery ) {
  4. "use strict";
  5. jQuery._evalUrl = function( url, options ) {
  6. return jQuery.ajax( {
  7. url: url,
  8. // Make this explicit, since user can override this through ajaxSetup (#11264)
  9. type: "GET",
  10. dataType: "script",
  11. cache: true,
  12. async: false,
  13. global: false,
  14. // Only evaluate the response if it is successful (gh-4126)
  15. // dataFilter is not invoked for failure responses, so using it instead
  16. // of the default converter is kludgy but it works.
  17. converters: {
  18. "text script": function() {}
  19. },
  20. dataFilter: function( response ) {
  21. jQuery.globalEval( response, options );
  22. }
  23. } );
  24. };
  25. return jQuery._evalUrl;
  26. } );