【发布时间】:2014-04-30 09:21:48
【问题描述】:
我正在使用YouTube-like Ajax Loading Bar 加载一个 php 文件。
这是我的 Javascript
$(".ajax-call").loadingbar({
target: "#loadingbar-frame",
replaceURL: false,
direction: "right",
async: true,
complete: function(xhr, text) {},
cache: true,
error: function(xhr, text, e) {},
global: true,
headers: {},
statusCode: {},
success: function(data, text, xhr) {},
dataType: "html",
done: function(data) {}
});
这是我的 HTML
<a href="load.php" class="ajax-call">..</a>
<div id="loadingbar-frame"></div>
这是 load.php,我正在尝试加载的文件
<?php
echo 'some content';
?>
我以前没有使用过 ajax,我不确定为什么这不起作用。
【问题讨论】:
标签: php jquery ajax youtube loading