
Welcome Guest
|
#1
|
|||
|
|||
|
Passing variable from flash to javascript then to cgi
Hi,
I can't figure this out, hope someone can help me out. I have a email-form in flash (mx 2004). I have a website at xs4all, a basic account and this provider does not allow the use of php with this account. But they do offer the use of a cgi-script (mail-a-form,they call it,you can't edit it) This is all perfectly working if you use the HTML-code they provide, most important that you use FORM METHOD="post", I tried to send the needed variable(s) directly from within flash but I got an error back the it wasn't using the FORM METHOD="post". So i thought I just pass the email variable from flash <with getUrl> to a javascript function and from there place them in this form and submit it with the same function.....; This is the code for the form in my index.html in the body: Code:
<FORM METHOD="post" ACTION="/cgi-bin/mail-a-form" NAME="emailForm"> <INPUT TYPE="hidden" NAME="to" VALUE="Me@xs4all.nl"> <INPUT TYPE="text" NAME="from" value=""> <INPUT TYPE="hidden" NAME="subject" VALUE="Formulier verstuurd vanaf leodesign.nl"> <INPUT TYPE="hidden" NAME="missing" VALUE="http://www.xs4all.nl/~accountname/missing.html"> <INPUT TYPE="hidden" NAME="nextpage" VALUE="http://www.xs4all.nl/~accountname/nextpage.html"> </FORM> Code:
<SCRIPT LANGUAGE="javascript">
function subMitEmail(emailAdress)
{
var email = emailAdress
document.forms.emailForm.from.value = email
document.forms.emailForm.submit();
window.status="je emaildress(" + email + ") is verstuurd aan Me@xs4all.nl"
};
</script> Code:
getURL("javascript:subMitEmail(" + email + "," + emailName +")", "_SELF","POST");Thanks in advance, Berry. Last edited by ugreen9 : 07-31-2005 at 04:00 PM |
«
Previous Thread
|
Next Thread
»
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| The News From Adobe on the Future of Flash Platform | FlashMove | Chit Chat Lobby | 0 | 11-10-2011 09:55 AM |
| My Flash and JavaScript don't like each other. | BlackHatHunter | Flash MX 2004 |
4 | 07-25-2006 06:15 PM |
| Flash Video Encoder Compare | flashfever2nd | New Softwares | 1 | 05-20-2006 03:46 AM |
| passing variable from php to flash | ashuraj2163 | Flash MX ActionScript |
3 | 11-30-2005 07:44 PM |
| Flash, Javascript, Do something on variable change... | Splitz | Flash MX 2004 |
7 | 04-20-2005 11:58 AM |





