Sha256: 32a7c1e8ce01c3c00a14c66d58616ea53c13822b5e52dca987244e0b518418dd
Contents?: true
Size: 765 Bytes
Versions: 2
Compression:
Stored size: 765 Bytes
Contents
jQuery(document).ready(function($) { //Intentionally wait for window.load, not just onready, to //prevent interfering with rest of page load. $(window).bind("load", function() { $(".bento_search_ajax_wait").each(function(i, div) { div = $(div); // from html5 data-bento-ajax-url $.ajax({ url: div.data("bentoAjaxUrl"), success: function(response, status, xhr) { div.replaceWith(response); }, error: function(xhr, status, errorThrown) { var msg = "Sorry but there was an error: "; div.html(msg + xhr.status + " " + xhr.statusText + ", " + status); } }); }); }); });
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
bento_search-0.5.0 | app/assets/javascripts/bento_search/ajax_load.js |
bento_search-0.0.1 | app/assets/javascripts/bento_search/ajax_load.js |