How to change link tag: send to anchor

Questions> How to change <s:submit>to <s:a>in struts tag?

I want to send the parameters to the next page (action) by mail (not receive)

<s:form action="products" method="post" theme="simple">
  <s:hidden name="code" value="%{code}"/>
  <s:submit type="button" method="selectSale" value="see"/>
</s:form>
+3
source share
1 answer

It is not listed here, but it looks like you set 's' as the prefix for struts-html taglib, i.e.: <%@ taglib uri="/WEB-INF/struts-html.tld" prefix="s" %>

Given this, there is no tag, you will need to submit the form from a regular anchor tag using javascript yourself. See frequently asked questions about the settings .

+1
source

Source: https://habr.com/ru/post/1717470/


All Articles