From: Rob H. <for...@us...> - 2002-06-17 00:51:25
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv16986/templates Modified Files: sandbox.html Log Message: fixed the "clicking update in sandbox_menu does not cause popup" bug, used javascript form variable redefinition and submit ( update is a link on the sandbox menu, not a button, which is what made this awkward and a little different from the browse_module menu ). fixing this gave me some good ideas for making browse_module's way of doing pop-ups more generic, which it can then share with sandbox menu. Index: sandbox.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/sandbox.html,v retrieving revision 1.18 retrieving revision 1.19 diff -U2 -r1.18 -r1.19 --- sandbox.html 22 Mar 2002 04:14:51 -0000 1.18 +++ sandbox.html 17 Jun 2002 00:51:22 -0000 1.19 @@ -20,5 +20,5 @@ - <form name="module" submit="<TMPL_VAR NAME=PROGNAME>" onsubmit="myOpenWindow()" target="popUp"> + <form name="module" submit="<TMPL_VAR NAME=PROGNAME>"> <input type="hidden" name="action" value="sandbox" /> <tr> @@ -48,7 +48,11 @@ </tr> -<form submit="<TMPL_VAR NAME=PROGNAME>"> -<input type="hidden" name="action" value="browse" /> - <TMPL_LOOP NAME="MODULE_LOOP"> +<form submit="<TMPL_VAR NAME=PROGNAME>" name="sandbox" target="popUp"> + <input type="hidden" name="action" value="sandbox" /> + <input type="hidden" name="Submit" value="Update" /> + <input type="hidden" name="module_name" value="0" /> + <input type="hidden" name="repo_name" value="0" /> + + <TMPL_LOOP NAME="MODULE_LOOP"> <tr> <td width="20%" align="left"> @@ -63,5 +67,5 @@ <td width="15%" align="center"> <font size="2"> - <a href="<TMPL_VAR NAME=PROGNAME>?action=sandbox&Submit=Update&module_name=<TMPL_VAR NAME="MODULE_NAME">&repo_name=<TMPL_VAR NAME="REPOSITORY">">update</a> + <a href="javascript:onClick=myOpenWindow();javascript:document.sandbox.module_name.value='<TMPL_VAR NAME=MODULE_NAME>';javascript:document.sandbox.repo_name.value='<TMPL_VAR NAME=REPO_NAME>';javascript:document.sandbox.submit();">update</a> | <a href="<TMPL_VAR NAME=PROGNAME>?action=sandbox&Submit=Delete&module_name=<TMPL_VAR NAME="MODULE_NAME">&repo_name=<TMPL_VAR NAME="REPOSITORY">">delete</a> |