App Framework选择器类似于jquery
范例:
$settings=$(div_settings); var $login_li=$settings.find("#settings_user");var $user_modify_password_div=$(user_modify_password_panel); $user_modify_password_div.find("input[name=old_password]").val(""); $('#uib_login input[name=password]').val("");
?
<!-- af> af Selector --> <div id="af1" class="panel" title="$()" data-nav="menu_AppFramework"> <span id="aftest2">This is some html</span> <br /> <br /> <a class="button" onclick="alert($('#aftest2')[0])">Click to get Object</a> <br /> <br /> <a class="button" onclick="alert($('#aftest2').html())">Click to get Content</a> </div>
?
var addTips= function () { $title=$("#add_tip_off_panel input[name=title]"); $content=$("#add_tip_off_panel textarea[name=content]"); $contacts=$("#add_tip_off_panel input[name=contacts]"); $contactWay=$("#add_tip_off_panel input[name=contactWay]"); alert($title.val()); alert($content.val()); alert($contacts.val()); alert($contactWay.val());}
?
?
?