View Full Version : Need a Join and send to a friend script
tim212
01-20-2005, 04:24 PM
can anyone help?
I have one but for some reason i cant load my movie into a level
if its at level 0 it works but thats it
thanks
whats the code look like that you are using to load the SWF
tim212
01-20-2005, 06:57 PM
loadMovieNum("join.swf", 4);
tim212
01-20-2005, 06:58 PM
fscommand("allowscale", "true");
//
// set some variables
//
mailform = "subscribe.php";
confirm = "please wait for confirmation ...";
action = "send";
//
// and focus on variable fname
//
Selection.setFocus("fname");
//
// validate email function
//
function validate(address) {
if (address.length>=7) {
if (address.indexOf("@")>0) {
if ((address.indexOf("@")+2)<address.lastIndexOf(".")) {
if (address.lastIndexOf(".")<(address.length-2)) {
return (true);
}
}
}
}
return (false);
}
//
// form check
//
function formcheck() {
if ((((email == null)) || (email.length<1)) || (email == "ERROR! Address not valid")) {
email = "ERROR! Address not valid";
action = "";
}
if (!validate(email)) {
email = "ERROR! Address not valid";
action = "";
}
if (fname == null) {
fname = "ERROR! Name required";
action = "";
}
if ((validate(email)) && (email != "ERROR!") && (fname != "") && (lname != "")) {
action = "send";
loadVariablesNum(mailform, 0, "POST");
gotoAndPlay("wait");
}
}
stop();
tim212
01-20-2005, 06:58 PM
thats the script in the join movie
try
_level4.loadMovie("join.swf")
tim212
01-20-2005, 08:29 PM
no go
hum........... only thing I can suggest is what I do .... create a empty movie clip and load into that clip ........ levels are a pain ... just my 2 cents....
like this
////
// main swf
////
fscommand("allowscale", "true");
////
//create a empty box and load a external SWF
////
_root.createEmptyMovieClip("joinbox", _root.getNextHighestDepth());
_root.joinbox.loadMovie("join.swf");
////
// join.swf
////
//
// set some variables
//
var mailform:String = "subscribe.php";
var confirm:String = "please wait for confirmation ...";
var action:String = "send";
//
// and focus on variable fname
//
Selection.setFocus("fname");
//
// validate email function
//
function validate(address) {
if (address.length>=7) {
if (address.indexOf("@")>0) {
if ((address.indexOf("@")+2)<address.lastIndexOf(".")) {
if (address.lastIndexOf(".")<(address.length-2)) {
return (true);
}
}
}
}
return (false);
}
//
// form check
//
function formcheck() {
if ((((this.email == null)) || (this.email.length<1)) || (this.email == "ERROR! Address not valid")) {
this.email = "ERROR! Address not valid";
action = "";
}
if (!validate(this.email)) {
this.email = "ERROR! Address not valid";
this.action = "";
}
if (this.fname == null) {
this.fname = "ERROR! Name required";
this.action = "";
}
if ((validate(this.email)) && (this.email != "ERROR!") && (this.fname != "") && (this.lname != "")) {
this.action = "send";
this.loadVariablesNum(mailform, 0, "POST");
this.gotoAndPlay("wait");
}
}
stop();
in your join.swf code I put some this...... that will tell your code to use whats in its movie clip ..... hope it helps
|
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.