diff options
author | jsdelfino <jsdelfino@13f79535-47bb-0310-9956-ffa450edef68> | 2008-08-04 20:28:49 +0000 |
---|---|---|
committer | jsdelfino <jsdelfino@13f79535-47bb-0310-9956-ffa450edef68> | 2008-08-04 20:28:49 +0000 |
commit | ff9b4c1eb95ff546aba7d325c6579c69757f6799 (patch) | |
tree | ea1cdef4a82787674453fc16137e52880c93cbb2 /java/sca/modules/domain-manager/src/main/resources/files-gadget.html | |
parent | b4384d70fc8c4dc583f0677a94372efa054d6516 (diff) |
Fixed Javascript warnings, use elementByID() to get references to UI elements instead of referencing global variables directly.
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@682495 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/sca/modules/domain-manager/src/main/resources/files-gadget.html')
-rw-r--r-- | java/sca/modules/domain-manager/src/main/resources/files-gadget.html | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/java/sca/modules/domain-manager/src/main/resources/files-gadget.html b/java/sca/modules/domain-manager/src/main/resources/files-gadget.html index b5f36782b7..e1c337f327 100644 --- a/java/sca/modules/domain-manager/src/main/resources/files-gadget.html +++ b/java/sca/modules/domain-manager/src/main/resources/files-gadget.html @@ -54,10 +54,13 @@ </body> <script type="text/javascript"> - var gadget = gadget(window, document); - //@Reference var files = new Reference("files"); + + var gadget = gadget(window, document); + + var filesElement = elementByID(gadget, 'files'); + var uploadFileForm = elementByID(gadget, 'uploadFileForm'); function getFiles() { files.get("", getFilesResponse); @@ -74,7 +77,7 @@ '<a href=\"' + location + '\">' + id + '</a></td></tr>'; } list += "</table>"; - gadget.getElementById("files").innerHTML = list; + filesElement.innerHTML = list; } } @@ -93,7 +96,7 @@ } function uploadFile() { - gadget.uploadFileForm.submit(); + uploadFileForm.submit(); } getFiles(); |