Authored by whb

loading

... ... @@ -300,9 +300,16 @@ define('mobile', function(require, exports) {
if ($(window).scrollTop() >= $(document).height() - $(window).height() - 50) {
if (total > limit && times < total_times && page <= totalPage) {
$.ajax({
beforeSend:function() {
if($(".loading").size() == 0)
{
$(".main-layout").append('<div class="loading"><img src="'+ YohoConfig.resUrl + '/images/yohood/loading.gif'+'" /></div>');
}
},
type: "get",
url: url + "/page/" + (parseInt(ajaxPage) + 1),
success: function(data) {
$(".loading").remove();
var news_page = $(data);
if ($(".main-layout").attr("page") != news_page.attr("page") && news_page.html() != "") {
$(".main-layout").append(news_page.html());
... ...