Jump to content

Submit button / Posting Variables


jdn1

Recommended Posts

Hiya Noob here :P

 

Have been using swishmax to compile a small rego form. Only i cant seem to get the submit button happening.

 

I have three fields of input text i need to post to e-mail...

I have been reading tutorials but they just dont seem right ?

 

any help would be appreciated. i can put wat i have up so far on my domain ?

Link to comment
Share on other sites

http://jdn1.8888mb.com/tourney.html (i renamed the url)  this is a flash form you may be seeing the white box because you done have a flash player installed? Allthough it is a common thing to have..?

 

what i mean is. i have 3 data entry boxes on the flash form a email, quake 4 alias , xfire tag.

 

and i want for the user to click the submit button and have the variables sent to the contact.php and then forwarded to my e-mail containg the 3 details...if that makes sense :S

 

 

 

submit button when clicked script....if  i did it right?

 

on (release) {

  q4_alias = q4_alias.text;

  Xfire = Xfire.text;

  email = email.text;

  loadVariables("contact.php",'POST');

}

 

 

contact.php

 

<?php

 

$q4_alias = $HTTP_POST_VARS['q4_alias'];

$Xfire = $HTTP_POST_VARS['Xfire'];

$email = $HTTP_POST_VARS['email'];

 

$message = stripslashes($message);

 

$sendTo = "jay_niesler@hotmail.com";

$subject = "Registration Form";

 

$msg_body = "q4_alias:  $q4_alias\n";

$msg_body .= "Xfire:  $Xfire\n";

$msg_body .= "email:  $email\n";

 

$header_info = "From: ".$name." <".$email.">";

 

mail($sendTo, $subject, $msg_body, $header_info);

 

?>

 

 

html of the flash form

 

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/html40/loose.dtd">

<html>

  <head>

    <title>tourney reg</title>

    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

    <meta name="author" content="">

    <meta name="generator" content="SWiSHmax http://www.swishzone.com">

    <meta name="description" content="tourney reg">

    <meta name="keywords" content="address, alias, email, quake, reset, submit, username, xfire">

    <!-- text used in the movie -->

    <!-- address, alias, email, quake, reset, submit, username, xfire -->

    <!-- Created by SWiSHmax - Flash Made Easy - www.swishzone.com -->

  </head>

  <body bgcolor="#FFFFFF">

    <center>

      <object

        classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"

        codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,79,0"

        id="tourney_reg"

        width="800" height="600"

      >

        <param name="movie" value="tourney reg.swf">

        <param name="bgcolor" value="#FFFFFF">

        <param name="quality" value="high">

        <param name="allowscriptaccess" value="samedomain">

        <embed

          type="application/x-shockwave-flash"

          pluginspage="http://www.macromedia.com/go/getflashplayer"

          name="tourney_reg"

          width="800" height="600"

          src="tourney reg.swf"

          bgcolor="#FFFFFF"

          quality="high"

          swliveconnect="true"

          allowscriptaccess="samedomain"

        >

          <noembed>

          </noembed>

        </embed>

      </object>

    </center>

  </body>

</html>

 

Link to comment
Share on other sites

Hmm well i dont think its that rally different from a standard form?

 

If you had a standard html form with 3 input text boxes

 

1. name

 

2. email

 

3 username

 

and upon a person entering those details and hitting the submit button those 3 data entry are to be posted to my e-mail.

(the variables get posted to text files and then the contact.php with the right code is supposed to mail them)

 

the swishmax comes with some scripts, it has a mial to script, this script opens up outlokk express so the user can send you an email. Thats not wat i want though.

 

Check this url it might give you some sorta understanding as to what i am on about.

 

http://www.swishzone.com/index.php?area=resources&tab=tutorials&do=page&action=detailed&link_id=152

Link to comment
Share on other sites

Try this instead:

 

contact.php

<?php

$q4_alias = $_POST['q4_alias'];
$Xfire = $_POST['Xfire'];
$email = $_POST['email'];

$message = stripslashes($message);

$sendTo = "jay_niesler@hotmail.com";
$subject = "Registration Form";

$msg_body = "q4_alias:  $q4_alias\n";
$msg_body .= "Xfire:  $Xfire\n";
$msg_body .= "email:  $email\n";

$header_info = "From: ".$name." <".$email.">";

mail($sendTo, $subject, $msg_body, $header_info);

?>

Link to comment
Share on other sites

OK cool i will give that a go.

 

Here another noob question for you when i upload the the html, the swishmax movie file and the contact.php file.

 

Do they just sit on my we site in the same folder and when ppl fill out the form should that script automatically post thopse variables to my e-mail ?

 

Or does the script have to be loaded or put some where special ?

 

Cheers

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.