开发者

How to copy one form elements into another through jsp?

I want to copy one f开发者_运维问答orm elements into another

<a href="#" onClick="copySelectedOptions(document.forms[0]['lstusr'],document.forms[0]['lstto'],false);return false;"> 

It is already written in PHP. I want it in JSP.


Your example means that you wish to copy form elements on client side. In this case the question about PHP or JSP is irrelevant: they both are server side technologies. So, just find the function copySelectedOptions implemented in javascript you used before (probably with PHP on server side that does not matter), include it into your HTML using <script> tag and use it.


First of all, I don't see how this becomes a Java / JSP / Servlet question. The copySelectedOptions function is a JavaScript function and can be easily reproduced by copying and pasting into your JSP file.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜