I think I have found an ugly way to do this and
will show it here. I apparently needed to alter
3 different things.
1. name the <form>
2 move the onsubmit to the <form>
definition from the <input type="button">
element
3 in the function "send()" i needed to
define global "form_object"
4 and in "send()" add "element." to the reference
for the value I wanted.
Btw, I would still like to adapt Mike's esh, though.
*******************************************
function send(form) {
if (dog) {
alert("You must select a point before clicking Submit");
} else {
var templat = Math.round(marker.getLatLng().lat()*100000)/100000 ;
var templng = Math.round(marker.getLatLng().lng()*100000)/100000 ;
var form_object = document.forms.java;
tempmess = form_object.elements.message.value;
var url = "gmapswinfo.php?Submit=foo&lat=" +templat+ "&lng="
+templng+ "&message="+tempmess;
GDownloadUrl(url,function(){});
alert("Your location has been recorded, thank you. Tell others
this link, please.");
}
}
*******************************************
echo "<form onsubmit=\"send();return false\" name=\"java\"";
echo "<input type=\"text\" ";
echo " name=\"message\" ";
echo " size=\"30\" ";
echo " maxlength=\"30\" ";
echo " /> \n";
echo "<input type=\"submit\" ";
echo " value=\"Submit\" /> \n";
echo "</form>";
*******************************************
Brian
On Oct 22, 4:21 pm, thebrianschott <[EMAIL PROTECTED]> wrote:
>
> Actually, I kind of like the way Mike does it in
> esh, but what I don't like about esh is if the user
> clicks on the map and then clicks again on the
> map at a different location, multiple markers
> with "icon:G_START_ICON"s are produced
> on the map and if the marker with an info form
> is dragged, the marker drags, but not the info
> form. I want the second click to inform the user
> that s/he needs to drag the first one, instead and
> I want the info form to move with the dragged
> marker.
>
> Can you help, please?
>
> Brian
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Maps API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/Google-Maps-API?hl=en
-~----------~----~----~----~------~----~------~--~---