SitePoint Sponsor |
|
User Tag List
Results 1 to 5 of 5
Thread: Pop-up form submission
-
Aug 14, 2001, 16:32 #1
- Join Date
- Apr 2001
- Location
- Springfield, IL
- Posts
- 34
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Pop-up form submission
I'm having a few problems... none are caused by my browser, so they are proving hard to troubleshoot. A user has pointed a couple out to me.
I have this code as part of a script:
(I have inserted hard breaks to make the post look better)
----------------------------------
window.open("http://www.site.com/loading.htm","confirmation","screenX=10,screenY
=10,left=0,top=10,toolbar=0,location=0,status=0,menubar=0,scrollbars
=1,resizable=0,width=250,height=250");
document.subForm.submit();
----------------------------------
"subForm" targets "confirmation". The user is getting two windows instead of one. One contains the initial window document and the other contains the form action. Also, she says they are both big... the size (of at least one) should be 250x250. She is running AOL 6 and IE 5.5 on the related computer.
Perhaps a timeout would help the 2 window situation? Why are the windows big and not 250x250? If you know what's going on please let me in on it.
This same user has a laptop that runs AOL 4 and IE 4 (she thinks). On that computer the form is submitting to one window, but none of the data is making it to the new window. I am guessing this has to do with the way I have the "form" and "table" tags within the javascript document.write statements. Does anyone know a good web page on this subject? OR What else the problem might be?
Ok, next issue!I am trying to submit a form using Netscape 4.03. When the submit button calls the related function I receive: "subForm is not defined". Here is the line that is throwing the error:
----------------------------------
eml = subForm.email.value;
----------------------------------
The final problem is regarding the same form. When I hit the submit button in N6... nothing happens.
Like I said, I am not experiencing any of these errors in my regular browser ( IE 5.01 ). (good browser... want a treat boy? submit the form. GOOD browser!)
Thanks for any help,
MichaelLast edited by Michael-from-Earth; Aug 14, 2001 at 16:36.
-
Aug 14, 2001, 17:44 #2
- Join Date
- Feb 2000
- Location
- where the World once stood
- Posts
- 700
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Hi Michael from Earth,
Since you haven't posted enough code, all of this is conjecture.
1) Netscape 4: you didn't close a tag -- either the </form>, or a </td>
2) aol/ie -- you are using a submit button and the document.formname.submit() -- although aol is an IE-cripple, it doesn't seem to operate the same with submissions -- kill the "doc....submit()" Someone at JavascriptCity had a similiar problem
3) nn6 -- i have no idea -- what does the error message say?
VinnyWhere the World Once Stood
the blades of grass
cut me still
-
Aug 14, 2001, 17:46 #3
- Join Date
- Oct 2000
- Location
- Austin, TX
- Posts
- 1,438
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
I don't know about the AOL stuff to get it to work in netscape you'll need to reference forms from the document object: document.subForm.email.value
ck :: bringing chris to the masses.
-
Aug 28, 2001, 15:54 #4
- Join Date
- Apr 2001
- Location
- Springfield, IL
- Posts
- 34
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Haven't had time to post, but I am back now!
Originally posted by Anarchos
I don't know about the AOL stuff to get it to work in netscape you'll need to reference forms from the document object: document.subForm.email.value
Originally posted by Vincent Puglia
Hi Michael from Earth,
Since you haven't posted enough code, all of this is conjecture.
Originally posted by Vincent Puglia
1) Netscape 4: you didn't close a tag -- either the </form>, or a </td>
Originally posted by Vincent Puglia
2) aol/ie -- you are using a submit button and the document.formname.submit() -- although aol is an IE-cripple, it doesn't seem to operate the same with submissions -- kill the "doc....submit()" Someone at JavascriptCity had a similiar problem
Originally posted by Vincent Puglia
3) nn6 -- i have no idea -- what does the error message say?
Vinny
Remaining Issues
User is running AOL 4.0
1) User is getting 2 pop-up windows instead of one upon form submission.
The 1st window contains the document specified by "window.open".
The 2nd window contains the action of the form submitted.
2) None of the form data is making it to the new window. OR Maybe it is making it to the extra window and not the window containing the form action document.
Code
Here is an example of the type of code involved.
(I have inserted hard breaks to make the post look better)
function reportProblems()
{window.open("http://www.site.com/interface/loading.htm","report_window",
"screenX=10,screenY=10,left=0,top=10,toolbar=0,location=0,status=0,
menubar=0,scrollbars=1,resizable=0,width=400,height=400");
document.reportForm.submit();}
mem_id = "xxxxxx";
document.write("<a href='javascript:reportProblems()'
onMouseover='window.status=\"Report Problems\"; return true;'>
Report Problems<\/a>");
document.write("<form name='reportForm'
action='http://www.site.com/interface/report_problem.asp'
method='post' target='report_window'><input type='hidden'
name='hostname' value='" + location.hostname + "'><input
type='hidden' name='browser' value='" + navigator.appName + "'><input
type='hidden' name='browser_version' value='" + navigator.appVersion
+ "'><input type='hidden' name='browser_codename' value='" +
navigator.appCodeName + "'><input type='hidden' name='user_agent'
value='" + navigator.userAgent + "'><input type='hidden'
name='mem_id' value='" + mem_id + "'><input type='hidden' name='host'
value='" + location.host + "'><input type='hidden'
name='page_location' value='" + location.href + "'><\/form>");
Thanks for any constructive input.
-MichaelLast edited by Michael-from-Earth; Aug 28, 2001 at 15:59.
-
Oct 8, 2001, 13:47 #5
- Join Date
- Apr 2001
- Location
- Springfield, IL
- Posts
- 34
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Still dealing with these issues...
Is there anyone out there who has had similar experiences with AOL and found a solution?
Regards,
Michael
Bookmarks