Hi
I'm having the following js problem:
A webapplication has a page with a button event that pops up a file upload
dialog.
this dialog is a form with a locally absolute URL to a webapp '/FileUpload'
as action
The problem is, as long as I'm using IE the form action is fired. When I'm
using Firefox it doesn't work. It only works when I'm using the full
quallified URL 'http://localhost:8080/FileUpload'. OK this is a workarround,
but I can not use it because the whole webapp will be installed on multiple
domains and therefore the hostname must not be static.
Here's the stripped down Javascript source:
<script type="text/javascript">
function popup(OutFilePa th,filter){
popupSrc= "<html>"
+"<form name='popupForm ' method='post' action='/FileUpload?acti on=help'
ENCTYPE='multip art/form-data'>"
+"<center><inpu t type='SUBMIT' value='Upload' name='Upload Selected
Files' /></center>"
+"</form></html>";
popupWin=window .open("javascri pt:opener.popup Src",
"pop",
"width=300,heig ht=200,resizabl e");
}
Has anyone a idea how I get it to work?
Thanks Dirk
I'm having the following js problem:
A webapplication has a page with a button event that pops up a file upload
dialog.
this dialog is a form with a locally absolute URL to a webapp '/FileUpload'
as action
The problem is, as long as I'm using IE the form action is fired. When I'm
using Firefox it doesn't work. It only works when I'm using the full
quallified URL 'http://localhost:8080/FileUpload'. OK this is a workarround,
but I can not use it because the whole webapp will be installed on multiple
domains and therefore the hostname must not be static.
Here's the stripped down Javascript source:
<script type="text/javascript">
function popup(OutFilePa th,filter){
popupSrc= "<html>"
+"<form name='popupForm ' method='post' action='/FileUpload?acti on=help'
ENCTYPE='multip art/form-data'>"
+"<center><inpu t type='SUBMIT' value='Upload' name='Upload Selected
Files' /></center>"
+"</form></html>";
popupWin=window .open("javascri pt:opener.popup Src",
"pop",
"width=300,heig ht=200,resizabl e");
}
Has anyone a idea how I get it to work?
Thanks Dirk
Comment