我有一个事件监听器,我正在尝试开始工作,但似乎无法让它运行。我有一个 onclick 设置,可以切换 div 的类以提示 webkit 转换。当该转换结束时,我希望 jquery 将外部页面加载到 div 中,但它不会加载它。这是我设置的js
<script type="text/javascript">
function fullscreen_slider_load() {
var fullscreen = document.getElementById("fullscreen");
function fullscreen_done1() {
console.log("done called");
fullscreen.removeEventListener("webkitTransitionEnd", fullscreen_done1);
fullscreen.addEventListener("webkitTransitionEnd", fullscreen_done2);
$(function fullscreen_load() {
$('#fullscreen')
.html('<img src="http://www.klossal.com/loader.gif"/>')
.load('http://www.klossal.com/portfolio/space_fullscreen.html');
});
function fullscreen_done2() {
fullscreen.removeEventListener("webkitTransitionEnd", fullscreen_done2);
};
</script>
我不确定为什么它没有加载,但我能得到的任何帮助将不胜感激。