我一直在阅读以远离JavaScript以获取很多东西,但是我正在搞乱它并且它似乎没有用(除非我是盲目的并且错过了一些东西)
<SCRIPT LANGUAGE="text/javascript">
function testResults() {
System.out.println("Got into function");
}
</SCRIPT>
Run Code Online (Sandbox Code Playgroud)
这是我的身体:
<form action="" method="GET">
<input type="button" value="Save" name="saveType" style="margin:10px;" onClick="testResults()"/>
</form>
Run Code Online (Sandbox Code Playgroud)
从我所看到的javascipt这应该没问题......有什么建议吗?
static final ArrayList<HashMap<String,String>> arraylistobject = new ArrayList<HashMap<String,String>>();
private void populateList() {
HashMap<String,String> temp = new HashMap<String,String>();
temp.put("pen","MONT Blanc");
temp.put("price", "200 rs");
arraylistobject.add(temp);
HashMap<String,String> temp1 = new HashMap<String,String>();
temp1.put("pen","Gucci");
temp1.put("price", "300 rs");
arraylistobject.add(temp1);
HashMap<String,String> temp2 = new HashMap<String,String>();
temp2.put("pen","Parker");
temp2.put("price", "400 rs");
arraylistobject.add(temp2);
HashMap<String,String> temp3 = new HashMap<String,String>();
temp3.put("pen","Sailor");
temp3.put("price", "500 rs");
arraylistobject.add(temp3);
HashMap<String,String> temp4 = new HashMap<String,String>();
temp4.put("pen","Porsche Design");
temp4.put("price", "600 rs");
arraylistobject.add(temp4);
Run Code Online (Sandbox Code Playgroud) // Add an additional field to the checkout within a new fieldset
add_filter('eshopaddtocheckout','eshop_extras_checkout');
function eshop_extras_checkout($echo){
$echo .= ' <script>
jQuery(function($) {
$(".formGroup").hide();
$("#chooseForm input:checkbox").on("change", function() {
if($(this).is(":checked")) {
$("#" + $(this).val()).show();
}
else {
$("#" + $(this).val()).hide();
}
});
});
</script>';
$echo .= '<fieldset class="eshop eshop_extra">' . "\n";
$echo .= '<legend>Select the Approriate Form</legend>' . "\n";
$echo .= ' <div id="chooseForm">
<input type="checkbox" name="forms2[]" id="ArticlesOrderForm" value="ArticlesOrderForm"> <b>Articles Order Form </b><br>
<input type="checkbox" name="forms2[]" id="PressReleasesForm" value="PressReleasesForm"> <b> Press Releases Form </b><br> …Run Code Online (Sandbox Code Playgroud) 如何在自己的应用中实现联系人?我想,当我点击按钮时,显示我手机上的所有联系人.你能告诉我一些关于它的事吗?喜欢在什么时候发送短信.单击按钮,选择联系人并发送.
如果我们单击"添加"链接,则应将新输入添加到表单中.
此外,每个添加的输入附近应该有"删除"链接.如果我们点击它,则应删除此输入.
我该怎么做呢?