开发者

Submitting Forms form within Jquery UI Tabs using ajax

example page

I have not uploaded the css styles for JQ UI so it looks a bit 开发者_运维百科plain but I am sure you will see what I am intending to do. Most of the tabs will need to load new info from mySQL database so I am assuming that means using AJAX?

Thanks for the help


jquery ui tabs is only a nice fancy way to display any webcontent so you can either submit the form the way you would normally do it, by sending it via post to a page that handles the form request, or you cna do it with ajax

$.ajax({
  type: 'POST',
  url: url,
  data: data,
  success: success
  dataType: dataType
});

whereas data would be $('#form-id').serializeArray() for example

for more infos: jquery api

EDIT:

wrap this around your table:

<form method="POST" action="yourtargetfile.php">
     <table>.....</table>
</form>

all input fields in the form will be submitted by button press, also the submit button must be inside the form

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜