Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我以前使用隐藏变量来实现这一点。但出于安全原因,我想删除隐藏变量,因此我必须能够在不使用隐藏字段的情况下访问操作字段。我怎样才能做到这一点?
您可以使用以下操作字段初始化 js 变量 -
<script> var item = '<s:property value="item" />'; .... </script>
其中 Action 类有一个getItem()方法。
getItem()