-
Contact form not showing 'Thank You'
Hi all,
i'm using a really simple PHP contact form. It works well and sends the information to my email but it will not go to the 'Thank you' message on the next frame.
Here's the code on the submit button:
Code:
on (release) {
// send variables in form movieclip (the textfields)
// to email PHP page which will send the mail
form.loadVariables("email.php", "POST");
}
}
and here's the code on the actual Form MC
Code:
onClipEvent(data){
// show welcome screen
_root.nextFrame();
}
I think the problem might be that i'm calling the form to the stage into an empty MC. i've tried replacing _root.nextFrame with this.nextFrame but it just doesn't work.
FYI my empty MC that i'm calling my form movie into is located at _root.MCcenter.emptyMC.
thanks.
Thanks.
-
it could be that the onclipevent(data) event doesnt fire, i had a similar problem before, try tracing from that function to just see if it even gets called. If yes, and the problem is really movieclip scope then try
Actionscript Code:
//from root function nframe() { nextFrame() } MCcenter.emptyMC.nextFrameFun = nframe//or whatever location where the form movieclip is located
//in form mc onClipEvent(data){ // show welcome screen nextFrameFunc() }
-
hi skewq,
should this bit of come go on the submit button?
//from root
function nframe()
{
nextFrame()
}
MCcenter.emptyMC.nextFrameFun = nframe//or whatever location where the form movieclip is located
-
no that part is on the movieclip which's frame should change. Sorry for the typo, it should be MCcenter.emptyMC.nextFrameFunc
-
Do you mean frame 1 of the movie clip?
as it is there's the form on frame 1 and the thank you on frame 2.
Last edited by drog1998; 08-18-2010 at 01:52 AM.
-
thanks for your help.
I worked it out. It was a not linking correctly. Rather than use
Actionscript Code:
onClipEvent(data){ // show welcome screen _root.nextFrame(); }
I substituted _root. for
this._parent.nextFrame()
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|