Form Action PUT not sending variables

F

ft310

I have a form
<td ID="but" width="20%" style="height: 30px; vertical-align: top ;">
<form class="frmform" name="close01" action="index.htm"/>
<p style="text-align: center; margin-top: 0; margin-bottom: 0">
<button class="frmclose" onClick="retreat() ;" name="closer"
style="height: 97%">Close</button>
</p>
</form>

<form class="frmform"
name="buttons"
target="_blank"
method="POST"
action="geodirect.php"/>

<label class="frmlabel" for="addr"><br>Enter Address:</label><br>
<input class="frmaddr" name="addr" size="50"/></input><br>&nbsp;<br>
<input type=submit class="frminput" onClick="return tohere() ;"
name="GoTo" value="and go TO Meeting"><br>&nbsp;<br>
<input type=submit class="frminput" onClick="return fromhere() ;"
name="GoFrom" value="or FROM Meeting"><br>&nbsp;<br>
<input type="hidden" name="startaddress" size="200" value="">
<input type="hidden" name="endaddress" size="200" value="">
<input type="hidden" name="meetingaddress" size="200"
value="">
<input type="hidden" name="coordinatesline" size="20"
value="">
&nbsp;<br>
</form>
</td>

None of the variables are reaching geodirect.php

I am at lose on how to go about dealing with this -- may I have
suggestions
 
R

Rik

I have a form
<td ID="but" width="20%" style="height: 30px; vertical-align: top ;">
<form class="frmform" name="close01" action="index.htm"/>
<p style="text-align: center; margin-top: 0; margin-bottom: 0">
<button class="frmclose" onClick="retreat() ;" name="closer"
style="height: 97%">Close</button>
</p>
</form>

<form class="frmform"
name="buttons"
target="_blank"
method="POST"
action="geodirect.php"/>

Euhm, a self closing form tag? Try without the /
 
F

ft310

I am at a loss too. Where is the accompanying script? What are those
onClick (sic) handlers calling?


Here is the scripts -- If you tell me I have a script error at this
point I will be sad, very say.

function tohere()
{
processaddr('TO') ;
}

function fromhere()
{
processaddr('FM') ;
}

function processaddr(directn)
{
if (document.buttons.addr.value.length > 0)
{
if (directn == 'TO')
{
document.buttons.startaddress.value = document.buttons.addr.value ;
document.buttons.endaddress.value = myCoord[4] + "," + myCoord[5] ;
}
else
{
document.buttons.startaddress.value = myCoord[4] + "," +
myCoord[5] ;
document.buttons.endaddress.value = document.buttons.addr.value ;
}

document.buttons.meetingaddress.value = myCoord[2] + "," +
myCoord[3] ;
document.buttons.coordinatesline.value = myCoord[4] + "," +
myCoord[5] ;

alert('str add ' + document.buttons.startaddress.value) ;
alert('end add ' + document.buttons.endaddress.value) ;
alert('mtg add ' + document.buttons.meetingaddress.value) ;
alert('coord ' + document.buttons.coordinatesline.value) ;

return true ;
}
}
 
F

ft310

You don't know if you have a script error at this point? Anyway, another
poster spotted a flaw in your HTML. You should have validated the HTML
first and if it still didn't work at that point, you should have tested it
without the script (which you should do anyway.) And when posting HTML, you
should include all functions referenced in inline event handlers, otherwise
it is impossible to test it.


David, thank you very much for your valued insights into the current
state of software evolution.
 
R

Rik

Rik, thanks -- that was definitely not necessary -- I took it out and
there was no change.

It was neccessary, it was invalid HTML. Now, if things still not work,
consider 2 options to further our search:

1. Use FireBug in Mozilla (or other javascript tools) to check the flow
after the onclick events.

2. If that doesn't work, put it up on a location reachable for us and give
us the URL. I'm not in the habit of setting up other peoples webpages
myself to give them free advice about their problems. I'm glad to help
out, but make it easy for the people who are willing to spend time on you.
 
F

ft310

It was neccessary, it was invalid HTML. Now, if things still not work,
consider 2 options to further our search:

1. Use FireBug in Mozilla (or other javascript tools) to check the flow
after the onclick events.

2. If that doesn't work, put it up on a location reachable for us and give
us the URL. I'm not in the habit of setting up other peoples webpages
myself to give them free advice about their problems. I'm glad to help
out, but make it easy for the people who are willing to spend time on you.

Rik, I appreciate your input and I think agree with you. I've had this
issue for some time now and was looking for an approach as everything
I could think of was yielding nothing.

Your remarks were constructive and necessary -- the /> should not have
been there -- I had discredited it but one can never know.

In all cases though, this discussion reach a new low real quick and I
am looking for other more civil avenues.

I've been doing this for over 47 years; We all have baggage; I'm just
not in the mood to haul someone elses.

Again thanks and Good Luck to you.

Frank
 
D

Dr J R Stockton

In comp.lang.javascript message <[email protected]
It would be appreciated if you fixed this page. I don't care for the
opening JavaScript error in IE7 (among other things.)

Interesting. I normally use IE6; IE7 is on another machine here.

IE6, Firefox 2.0.0.4, and Opera 9.21 all seem happy with the page.

IE7 does assert Line 378 Char 31 Invalid argument Code 0 but
line 378 and its neighbours are an innocent HTML paragraph.

I introduced an error on line 356, which *is* script, and its line
number was correctly given.

I removed it, and added extra blank lines at about line 369; line 378
was still reported as wrong.

It would be appreciated if you would fix IE7 !!!



What do others see when loading that page?
 
R

Rik

In comp.lang.javascript message <[email protected]

What do others see when loading that page?

Works OK, there is an error report in MSIE 7 indeed though.
The error is in the Cuffs() function, MSIE 7 reports it's in the HTML but
clearly it's the javascript file. It bugs on:

HREF = DLJ.href

On link no. 289 to be precise, where further processing is halted.

There, it appears there is the first 'encountered. Indeed, if
all are removed or alter into for instance 'the error disappears.
 
D

Dr J R Stockton

Wed said:
Works OK, there is an error report in MSIE 7 indeed though.
The error is in the Cuffs() function, MSIE 7 reports it's in the HTML but
clearly it's the javascript file. It bugs on:

HREF = DLJ.href

On link no. 289 to be precise, where further processing is halted.

There, it appears there is the first 'encountered. Indeed,
if all are removed or alter into for instance 'the error
disappears.


On my system, the form news://... does work, but the (notoriously
standards-compliant) newsreader gives an error warning "not a valid
newsgroup name".


The offending line in js-index.htm is Number 1103 :

1101 <li>IT :
1102 <a href=":
1103 <a href="1104 FAQ</a> versione 0.9 - 06/11/2004. Also posted in the newsgroup

and it's the only line matching / on the site.

No doubt that's a form I wasn't really thinking of when writing Cuffs.

However, at present I can't see what to do about that statement (it would
be acceptable to do a loop continue there; but how to recognise the
need?).
 
R

Rik

On my system, the form news://... does work, but the (notoriously
standards-compliant) newsreader gives an error warning "not a valid
newsgroup name".

Which is offcourse right, it _should_ be without the //... Maybe
MSIE 7 doesn't really recognize but just doesn't do weird stuff it
does do with actual I do not know the exact nature of the
problem, I just know where it is :)
The offending line in js-index.htm is Number 1103 :

1101 <li>IT :
1102 <a href="
:
1103 <a href="1104 FAQ</a> versione 0.9 - 06/11/2004. Also posted in the newsgroup

and it's the only line matching / on the site.

No doubt that's a form I wasn't really thinking of when writing Cuffs.

It should not matter AFAIK, but even assigning the DLJ.href to HREF gives
the error, very weird behaviour.
However, at present I can't see what to do about that statement (it would
be acceptable to do a loop continue there; but how to recognise the
need?).

....
DLJ = document.links[J];
if(typeof DLJ.href != 'string') continue;
HREF = DLJ.href;
....

That seems to work with the old links.
 
D

Dr J R Stockton

Thu said:
However, at present I can't see what to do about that statement (it would
be acceptable to do a loop continue there; but how to recognise the
need?).

...
DLJ = document.links[J];
if(typeof DLJ.href != 'string') continue;
HREF = DLJ.href;
...

That seems to work with the old links.


Installed. Seems OK with IE6, IE7, and the new Firefox 2.0.0.5 and
Opera 9.22. Thanks.

There is however a related problem - neither by the link, nor by any
other means so far tried, have I actually been able to get that FAQ.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,898
Latest member
BlairH7607

Latest Threads

Top