[Javascript] submit to 2 adresses

Joost Kahmann J.Kahmann at fcj.hvu.nl
Wed Jun 11 08:43:42 CDT 2003


Hi Again

This is my test version:

<SCRIPT LANGUAGE="javaScript">
<!--
function opSturen()
	{ 
		var nr = f_int.Studentnummer.value
		var domein = "@student.fcj.hvu.nl"
		var nrAdres = nr + domein

		f_int.action = 'mailto:' + nrAdres ; 
		f_int.submit() ;  
		alert("Een afschrift gaat naar " + nrAdres) ;
		nogEens() ;
	}

function nogEens()
	{
		var aAdres = "http://send.formmailer.com/"

		f_int.action = aAdres ;
		f_int.submit() ;
	}
// -->
</SCRIPT>
<FORM  NAME="f_int"  METHOD="post" ACTION="return opSturen">
<INPUT TYPE=button NAME=Button VALUE=" Verstuur naar het bedrijfsbureau  " onclick="opSturen(f_int)">

[URL = http://www.svj.hvu.nl/annex/test/submittes3.htm]

The trouble is function nogEens() is working the way it should be: a thanks page is shown. But there's no email delivered at the nrAdres. 
Without nogEens() the first email delivery works smooth.
[if testing: nrAdres = 3200200 at student.fcj.hvu.nl]

Am i on the right track?

Joost

> ----------
> From: 	Daniel Buus
> Reply To: 	[JavaScript List]
> Sent: 	vrijdag, 6 juni 2003 10:48
> To: 	javascript at LaTech.edu
> Subject: 	Re: [Javascript] submit to 2 adresses
> 
> Hello =)
> 
> Why not just create an extra page, "formhandler.html", let it collect the
> form data and process it whichever way you want.
> 
> Then you'd just use "action=formhandler.html".
> 
> Probably not the most clever way, but it'd work =)
> 
> Alternatively, you could make a javascript function to read the form data
> when the submit button is clicked, and have it process it. Like:
> 
> <INPUT TYPE=button NAME=Submit VALUE="Submit" onclick="processData()">
> 
> and write the function
> 
> function processData() {
>     // Code for http://send.formmailer.com/
>     // Code for #@student.fcj.hvu.nl
>     // Other code to say "thanks" or whatever ;)
> }
> 
> 
> Daniel
> --------------------
> There are 10 kinds of people: Those who know binary and those who don't.
> _______________________________________________
> Javascript mailing list
> Javascript at LaTech.edu
> https://lists.LaTech.edu/mailman/listinfo/javascript
> 
> 


More information about the Javascript mailing list