Submit action with URL link (non-s:from submission)

Source: Internet
Author: User

In our daily development, not all suitable for form submission, such as in the wireless network domain, using form submission will cause some phones can not parse the label, this time, our lovely URL link submission will be more widely used

1. standard WML1.0 form submission Format

< anchor> submit

        << Span style= "color: #3f7f7f; font-family: ' Courier New '; font-size:10pt; " >go href= "<s:url value= "/wap/postparams.action method= "get" >

        << Span style= "color: #3f7f7f; font-family: ' Courier New '; font-size:10pt; " >postfield name= "param1" value =

        << Span style= "color: #3f7f7f; font-family: ' Courier New '; font-size:10pt; " >postfield name= "param2" value =

        << Span style= "color: #3f7f7f; font-family: ' Courier New '; font-size:10pt; " >postfield name= "Struts.token.name" value= />

        << Span style= "color: #3f7f7f; font-family: ' Courier New '; font-size:10pt; " >postfield name= "Struts.token" value= "${sessionscope[' Struts.token ']}" />

</Go>

</anchor>

2. <a href= "" ></a> and <s:url/> complete link effect

<a href= '

<s:url action="Postparams">

<s:param name="param1" value="#stu. Id" />

        <s:param name= "Struts.token.name" value= "Struts.token" />

<s:param name="Struts.token" value= "${sessionscope[' Struts.token ']}" />

</s:url> '>

Submit </a>

3 . <s:a/> and <s:url/> together to complete the link submission

< id= "Tourl" action= " Postparams " namespace= "/wap" >

     <s:param name= "param1" value = "%{param1}"

     <s:param name= "param2" value = "%{param2}"

     <s:param name= "Struts.token.name" value= />

     <s:param name= "Struts.token" value= "${sessionscope[' Struts.token ']}" />

< /s:url>

<s:a href= "%{tourl}" > submit </s:a

The above three methods in the wireless Internet development process is very practical, specific to see personal hobbies, of course, if you do WEB development, you can also directly use <s:form/>

Submit action with URL link (non-s:from submission)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.