加载HTML Jquery Mobile页面时调用函数 [英] Calling a Function On load of a HTML Jquery Mobile page

查看:76
本文介绍了加载HTML Jquery Mobile页面时调用函数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

I tried

    $('#page18').bind("load",function() {
            alert("total Type") ;
        });

    and also i tried doing this

    $('#page18').ready( function() {
            alert("total Type")

I want to call a function on Load of a Html5 Jquery Mobile page.

    I have various Div with <data-role="page">
    Each of them has Id.Now with navigation when I reach on <div id="page18"> i want to cal a function ...
        });

    But cant seem to fig it out. can anyone help me with this

推荐答案

('#page18').bind("load",function(){ alert("total Type"); }); 我也尝试这样做
('#page18').bind("load",function() { alert("total Type") ; }); and also i tried doing this


('#page18').ready(function(){ 警报(总类型") 我想在Html5 Jquery Mobile页面的Load上调用一个函数. 我有各种Div,其< data-role =" 页面" < div id page18 "
('#page18').ready( function() { alert("total Type") I want to call a function on Load of a Html5 Jquery Mobile page. I have various Div with <data-role="page"> Each of them has Id.Now with navigation when I reach on <div id="page18"> i want to cal a function ... }); But cant seem to fig it out. can anyone help me with this


文档加载/就绪时的加载
A load when the document is loaded/ready


这篇关于加载HTML Jquery Mobile页面时调用函数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆