可以说这是我的HTML表单定义触发一个jQuery文件的jquery.js里面的函数:如何从一个html <form>
<form id="feedback" action="" enctype="multipart/form-data" method="post">
jQuery的文件头标记定义:
<script type="text/javascript" src="js/ajaxarchive.js"></script>
我还建立了一个输入字段中的HTML DIV作为一个按钮:
<div id ="button" class="button">
<input type="submit" name="submit" id="submit" value="Enviar" />
</div>
我有JavaScr在我的index.html中的ipt代码,我更愿意让代码在index.htm之外验证我的表单。我可以在这样的句子加我的功能 (但我宁愿想从外部文件调用我的函数):
if ($li_e.attr('class')==='cc_content_13'){
/*here I try to recieve code from the ajaxarchive.js inside functions*/
}
我为了如何定义的功能也ajaxarchive.js里面的东西一样
var formData = $('form').serialize();
submitForm(formData); <-- This is the name of the function
Whaaaat?你能花时间让这个问题可读吗? – Blender