Multi-field Form To Be Sent Via Asp
Hello!
I know that there are several tutorials that show how to make forms but I'm having a heck of a time making one work.
I need to create a form that has 10 input fields in it and have that info sent to an email address via asp.
Does anyone have a multi-field form along with an mail.asp that I can look at?
thanks!
FlashKit > Flash Help > Flash Newbies
Posted on: 05-16-2006, 05:05 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
[MX] Radio Button Toggle Field (hide/visible) For Multi Lang Form
I developed a form and have a field for nicknames I have then field hidden and want the field to display once the yes value radio button is selected. problem is unless i use a submit it won't work. which makes no sense because then the user can't go back and add the name. what am i doing wrong? the code is below
password = pwcode;
_root.pw.restrict = "0-9";
_root.pw.maxChars = 4;
nickname._visible = true;
if (radiogroup=yes) {
nickfld = "Enter Nickname";
nickname._visible(true);
} else if (radiogroup=no) {
nickfld = "";
nickname = "";
nickname._visible(false);
}
stop();
my other issue is i created the form so depending on which flag you click on it will display in the appropriate language. i created variables fra1-5 and eng1-5 for the different text. is there a way i can code so i don't need to keep typing fra1 fra2 fra3 or eng1 eng2 eng3 can i do something like
lang = fra (or eng)
so the variable code be lang+1 so if i wanted to add a language and the appropriate text later instead of typing ita1 (for italian) lang could equal ita and for consistency with the naming scheme would always be the same.
so instead of typing eng1, fra1, or ita1 it would be lang and that variable would name the file or value that should be used in it's place.
i guess that's a long winded way to ask is it possible?
Form Field Validation, Specially Email Field. Any Ideas?
Hi. I have a simple flash form designed for my website i have all things done but i am not getting the idea how to validate the "Email" field like you validate it in JavaScript for an "@" and a "." to be present in the finally submitted form. I need to do it in ActionScript as the other form validation is done in it as well. Please let me know if you can help. Thanks
Help Multi User Name & Pass For Input Text Field
Here is a copy of the code Im using but I cant seem to ad more usernames or passwords. Please help, many thanks.
on(release, keyPress "<Enter>" ){
if(userEnter.text == "member" && passwordEnter.text == "8871"){
_root.gotoAndPlay("success");
} else {
_root.errorMessage.gotoAndPlay("start");
}
}
Form Field Validation, Specially Email Field. Any
Hi. I have a simple flash form designed for my website i have all things done but i am not getting the idea how to validate the "Email" field like you validate it in JavaScript for an "@" and a "." to be present in the finally submitted form. I need to do it in ActionScript as the other form validation is done in it as well. Please let me know if you can help. Thanks
Scrolling Dynamic Multi-text-field XML Driven MovieClip
I have created a movie clip which contains 3 dynamic text fields (title, body, date). Together this group of fields represents one item of content. These fields are populated from an XML file which results in multiple items of content. This is accomplished by iterating through the XML and for each node uses the attachMovie function to stick another instance of the clip on the stage for each group of content. Note that the body text fields are dynamically sized to fit the length of the content.
The problem is the overall height of the clip is larger than the stage, as a result I am attempting to create a scrolling mechanism without luck. I have tried using the scrollpane comp. in MX and tried to do some masking but regardless of which method I try the movieClip is displayed with out respecting the bounds of the pane/mask and is not controllable by the scroll buttons.
Does someone have an idea on how to do this? If so your help would be appreciated.
Multi-page Flash Form ?
i want to setup a form in a single
flash file, with 3 sections.
once the user fills out the first section,
they click continue, and
fill out the next section of the form.
to do this, i'll need to hold
variable values per field on each
section of the form,
as the user clicks continue to move
on.
im not sure how to hold variables like
that in flash. im familiar with
php, but im not sure if that will help.
does anyone know of any tutorial
which uses a feature like this?
or does anyone have any other suggestions on how to accomplish this?
Creating A Multi-page Form
I am trying to create a flash form on a website that is on several pages. The form is too big too fit on one page, so I added a continue button. It says goto and play (the frame that the next page is on). The problem is, When you go to the next page, the data inputed in the previous page is lost. Does any one know a better way of accompplishing this?
Thanks
INFERNOAPBTS
AS2 - Multi File Upload Form Help
hi guys,
I have been working on the multi upload form over the past couple of days.
It's a variation of stuff i have found about the net.
The form has to buttons. One for single file uploads and one for multi file uploads.
The single file upload button works as it is supposed to but the multi file upload but although does upload all selected files it does not fire off any events.
I think i might have over looked something. Could someone have a look at the code below and see if they spot anything obviuos.
Thanks
ActionScript Code:
import flash.net.FileReference;
import flash.net.FileReferenceList;
var listenerSingle:Object = new Object();
var listenerMulti:Object = new Object();
var imageFileSingle:FileReference = new FileReference();
var imageFileMulti:FileReferenceList = new FileReferenceList();
imageFileMulti.addListener(listenerMulti);
imageFileSingle.addListener(listenerSingle);
//
var count:Number = 0;
var list:Array = new Array();
//
import works.PathManager;
import works.ButtonCellRender;
var folder:String = PathManager.secureVar();
var folderID:String = folder.slice(5);
//----------------------------------------------------------
files_dg.addColumn("Thumb");
files_dg.addColumn("Name");
files_dg.addColumn("Size");
files_dg.addColumn("Status");
files_dg.addColumn("Remove");
files_dg.getColumnAt(0).resizable = false;
files_dg.getColumnAt(1).resizable = false;
files_dg.getColumnAt(2).resizable = false;
files_dg.getColumnAt(3).resizable = false;
files_dg.getColumnAt(4).resizable = false;
files_dg.getColumnAt(0).width = 102;
files_dg.getColumnAt(1).width = 180;
files_dg.getColumnAt(2).width = 60;
files_dg.getColumnAt(3).width = 120;
files_dg.getColumnAt(4).width = 210;
var col:Object;
var col2:Object;
col = files_dg.getColumnAt(4);
col.cellRenderer = "ButtonCellRenderer";
col2 = files_dg.getColumnAt(0);
col2.cellRenderer = "imageCellRender";
//----------------------------------------------------------
//------------------------------------------------------------------------
listenerSingle.onSelect = function(selectedFile:FileReference):Void {
files_dg.addItem({Name:selectedFile.name, Size:Math.round(selectedFile.size / 1000) + " kb", Status:"Uploading", Remove:"Remove"});
selectedFile.upload(PathManager.PATH_2_PHP + "f8upper.php?rnd=" + folderID);
butSingle.enabled = false;
butSingle._alpha = 40;
};
listenerSingle.onOpen = function(selectedFile:FileReference):Void {
//
};
listenerSingle.onComplete = function(selectedFile:FileReference):Void {
files_dg.editField(count,"Status","Upload complete");
files_dg.editField(count,"Thumb",PathManager.URL_PATH + "temp/" + folderID + "/" + selectedFile.name + PathManager.secureVar());
butSingle.enabled = true;
butSingle._alpha = 100;
files_dg.rowHeight = 102;
count++;
};
butSingle.onRelease = function() {
imageFileSingle.browse([{description:"Image", extension:"*.jpg;"}]);
};
butMulti.onRelease = function() {
imageFileMulti.browse([{description:"Image", extension:"*.jpg;"}]);
};
listenerSingle.onHTTPError = function(file:FileReference, error:Number) {
statusArea.text = "HTTP error: with " + file.name + ":error #" + error;
};
listenerSingle.onProgress = function(file:FileReference, bytesLoaded:Number, bytesTotal:Number):Void {
trace("here")
var percentDone = Math.round((bytesLoaded / bytesTotal) * 100);
files_dg.editField(count,"Status","Uploading: " + percentDone + "%");
};
//------------------------------------------------------------------------
listenerMulti.onSelect = function(file:FileReferenceList) {
butMulti.enabled = false;
butMulti._alpha = 40;
list = file.fileList;
for (var i:Number = 0; i < list.length; i++) {
trace("// onSelect:" + list[i].name);
files_dg.addItem({Name:list[i].name, Size:Math.round(list[i].size / 1000) + " kb", Status:"Uploading", Remove:"Remove"});
list[i].upload(PathManager.PATH_2_PHP + "f8upper.php?rnd=" + folderID);
}
};
listenerMulti.onOpen = function(file:FileReference):Void {
trace("multi opened")
//
};
listenerMulti.onHTTPError = function(file:FileReference, error:Number) {
trace("HTTP error: with " + file.name + ":error #" + error)
};
listenerMulti.onProgress = function(file:FileReference, bytesLoaded:Number, bytesTotal:Number):Void {
trace("// onProgress with bytesLoaded: " + bytesLoaded + " bytesTotal: " + bytesTotal);
for (var i:Number = 0; i < list.length; i++) {
if (list[i].name == file.name) {
var percentDone = Math.round((bytesLoaded / bytesTotal) * 100);
files_dg.editField(count,"Status","uploading: " + percentDone + "%");
}
}
};
listenerMulti.onComplete = function(file:FileReference) {
trace("onComplete: " + file.name);
for (var i:Number = 0; i < list.length; i++) {
if (list[i].name == file.name) {
files_dg.editField(count,"Status","Upload complete");
files_dg.editField(count,"Thumb",PathManager.URL_PATH + "temp/" + folderID + "/" + file.name + PathManager.secureVar());
count++;
}
}
butMulti.enabled = true;
butMulti._alpha = 100;
files_dg.rowHeight = 102;
};
//------------------------------------------------------------------------
finBut.onRelease = function() {
if (validateUpload()) {
_parent.imgUp.tInfo.htmlText = "( <font color='#cc0000'>" + imgCount + "</font> ) Images attached.";
_parent.upper._visible = false;
} else {
trace("Make sure all uploads are complete");
}
};
function validateUpload():Boolean {
for (i in files_dg.dataProvider) {
if (files_dg.dataProvider[i].Status != "Upload complete") {
break;
return false;
} else {
imgCount = i;
return true;
}
}
}
function removeME(who) {
files_dg.removeItemAt(who);
}
bg.useHandCursor = false;
stop();
Multi-Line, Word Wrap Dynamic Text Field Question...
Hi gang -
I have Dynamic Text Field that receives info via .asp. The text field is set to Word Wrap and MultiLine. In my test environment I have a .txt file named the same as my .asp page which provides data to display in the field. When I test movie, the information appears as intended with multiple lines of text, no problem. When I put it "live" it grabs the info by .asp no problem, but the textfield is not honoring the word wrap/multiline settings, on the PC (which is odd in and of itself, Mac displays properly so I know the text gets into the Flash). It is basically only displaying what can fit on one line of a multi-line text field. (The display field is large enough to handle 3 lines of text.) Now I have used this process in dozens of sites doing the same thing, the same way. For some reason, which I cannot ascertain, this textfield is not working on the PC and I can't figure out why.
Has anyone else had a similar problem? I'm at a loss atm so any help is much appreciated.
Collecting Data From A Multi-Page Form
We are interested in learning how to create a multi-page form. There are 3 steps to our form.
Step 1. Application Form with text fields - name, phone, address, etc.
Step 2. Choose topics from a list of check boxes/radio buttons
Step 3. Another application form
All of the data entered in steps 1-3 needs to be collected on another page after clicking a button at the end of each step. From that collected page the user needs to be able to hit submit and send it to a Server which houses ASP scripting cababilities which will then email the page to an end source.
We would be willing to pay for "serious" help with this.
Thank you all.
Multi-page Survey Form Sent To CGI Script
I am writing a multi-page survey form that has different components on it - check boxes, radio buttons and text fields -- that is spread out on 4 pages. that is then sent to a cgi script for processing and an email is sent from there.
I am running into a couple of issues:
1) how do I make sure data from one page is sent to end?
2) how do I get the values of the check boxes?
3) how do I get the values of the radio buttons?
That's it for now....
Thanks for the help.
Collecting Data From A Multi-Page Form
We are interested in learning how to create a multi-page form. There are 3 steps to our form.
Step 1. Application Form with text fields - name, phone, address, etc.
Step 2. Choose topics from a list of check boxes/radio buttons
Step 3. Another application form
All of the data entered in steps 1-3 needs to be collected on another page after clicking a button at the end of each step. From that collected page the user needs to be able to hit submit and send it to a Server which houses ASP scripting cababilities which will then email the page to an end source.
We would be willing to pay for "serious" help with this.
Thank you all.
Action Script For Multi Frame Contact Form?
Hello I'm a newbee,
I have made a contact form to get working on http://www.pedicuresalonhannie.nl This contact form is made in an one frame setup using sendbutton script:
Code:
on (release) {
getURL("javascript:openNewWindow('bedankt.php','_blank','GET','height=175,width=300,toolbar=no,scrollbars=no,resizable=yes')");
_parent.name="";
_parent.email="";
_parent.message="";
} and a php script Code:
<?php
$name = $_GET['name'];
$email = $_GET['email'];
$message = $_GET['message'];
$recipient_email = "info@pedicuresalonhannie.nl";
$subject = "Email van website Pedicure Hannie " . $email;
$headers = "From: " . $name . " <" . $email . ">
";
$headers .= 'Content-type: text/html; charset=iso-8859-1';
$content = "<html><head><title>Contact formulier</title></head><body><br>";
$content .= "Naam: <b>" . $name . "</b><br>";
$content .= "Email: <b>" . $email . "</b><br><br>";
$content .= "Vraag: <b>" . $message;
$content .= "<br></body></html>";
mail($recipient_email,$subject,$content,$headers);
?>
<html>
<head>
<script language="JavaScript">
function openNewWindow(URLtoOpen, windowName, windowFeatures) { newWindow=window.open(URLtoOpen, windowName, windowFeatures); }
</script>
<title>Bedankt voor uw email.</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="site_flash/style.css" rel="stylesheet" type="text/css">
<body>
<table cellpadding="0" cellspacing="0" border="0" width="100%" style=" height:100%;">
<tr>
<td width="50%" class="bg_left"><img src="site_flash/images/spacer.gif" width="1" height="1" alt=""></td>
<td width="766" class="bg_top"><table border="0">
<tr>
<td width="170" align="center"><img src="picture_library/Logohanniewit.png" width="250" height="131"></td>
</tr>
<tr>
<td align="center"><span style="margin-top:60px;color:#ffffff;font-size:11px;font-family:Tahoma;font-weight:Bold">Uw email is verzonden. Bedankt.</span></td>
</tr>
</table></td>
<td width="50%" class="bg_right"><img src="site_flash/images/spacer.gif" width="1" height="1" alt=""></td>
</tr>
</table>
</body>
</html>
<script>resizeTo(300, 250)</script>
WORKS GREAT!
But now I'm working on this website contact form http://www.cow-design.nl and this contact form is placed in multyframes. The input boxes are made of movies. The movies are given a name like c1, c2, c3 etc. I can't give the inputboxes a VAR, because if I do so, al the boxes are given the same VAR value. The reset button is working fine with this code
Code:
on (rollOver) {
gotoAndPlay(2);
}
on (releaseOutside, rollOut) {
gotoAndPlay(11);
}
on (press) {
_parent.c1.gotoAndPlay(8);
_parent.c2.gotoAndPlay(8);
_parent.c3.gotoAndPlay(8);
_parent.c4.gotoAndPlay(8);
_parent.c5.gotoAndPlay(8);
}
The send button is missing the on (release) script and I've tried this one:
Code:
on (rollOver) {
gotoAndPlay(2);
}
on (releaseOutside, rollOut) {
gotoAndPlay(11);
}
on (press) {
getURL("javascript:openNewWindow('http://www.cow-design.nl/bedankt.php','_blank','GET','height=175,width=300,toolbar=no,scrollbars=no,resizable=yes')");
_parent.c1.gotoAndPlay(8);
_parent.c2.gotoAndPlay(8);
_parent.c3.gotoAndPlay(8);
_parent.c4.gotoAndPlay(8);
_parent.c5.gotoAndPlay(8);
}
The email is comming to my inbox, so the php script is working, but there is not data? How do I send the data from the input boxes to my email?
I hope I have explained my problem here properly. I get used to make flash sites in one frame setup, but I don't know how to get things working in this setup.
Kind regards,
Marcel Severein
Multi-line Text Field Auto Line Break
When a Dynamic Multiple line text field is used in Flash CS3, it has a very annoying feature that auto inserts a line break at the end of inserted text. It also auto inserts a line break if no text is entered too.
I'm having a problem with this because the text is being saved from flash to a text file on the desktop. With every multi-line text field there's a nasty looking line break.
Any way of "turning off" this auto-line-break-at-the-end feature?
Trying To Pass Text From Form Text Field To A Flash Dynamic Text Field
Hi, I was hoping someone might enlighten me as to how/if I can do this...
Currently I'm using javascript which works fine to pass text from textfield A to textfield B:
Code:
window.onload=function()
{
document.forms.form1.shirtText.value=document.forms.form1.KitGroupID_16_TextOption_38.value
}
Is there a way to pass the textfield A text to a dynamic text input (flash) as I'd like to use the font embedding flash offers. I can make it work when loading a value from a txt file but I'm not sure how to access the value identified above as KitGroupID_16_TextOption_38 and make it appear in a dynamic input box. Eventually I might want to have 3 font choices for the user but I'd like to just see if I can get this working properly first.
Your help/advice would be greatly appreciated,
-Scott
Multi Loaded Vars To Multi MC's...Banging My Head Against The Wall
OK I'm banging my head against the wall because this is probably too simple, and I've been working on too many things lately *L*
OK so I've loaded a bunch of vars... let's say var1, var2, var3...var6 from a txt file.
Now I want to send each var to a MC whit similar names - but1, but2, but3...but6
code:
varsFile.onLoad = function(success:Boolean) {
trace("loaded");
for (i=0;i<=6; i++) {
buttonClip.but[i].htmlText = varsFile.var[i];
}
};
I've tried a bunch of different syntaxes, but can't seem to get it to work... HELP!!!!!! LOL
Thanks!!!!
Tab Key To Next Form Field
I have a form-like interface. I want to polish it off by setting it up to allow the user to press the tab key to advance to the next input text field. It seems that there should be a tutorial for this, but I can't find one. Any suggestions?
Form Field
Hi
How do I apply a script like this to a Form text-field?
<input type="text" value="Newsletter" onFocus="clearText(this)">
This javascript is placed in the header of the HTML-file
<script>
function clearText(thefield){
if (thefield.defaultValue==thefield.value)
thefield.value = ""
}
</script>
The script empties the textfield as the user clicks it!
The textfield has the varible letterField applied to it in the Flash-file.
Lars
Form Field Value And No Value
How can I do this in flash. You know how in html forms you can do this:
PHP Code:
onblur="this.value='enter email address';" onfocus="this.value='';"
What I have are some form fields that have some text in it as a defalut value then when the person sets focus in the form field the value disappears. Now if the place a value in the form field then move to the next form field thus losing focus on the first form field. I would like the info they input in there to remain there. But if nothing was placed show the default value. I know how to do it in html but not in flash. Pleez help. Would love to do some flash forms.
Creating Multi-buttons To Open Multi-jpegs
I am a newbie to action-script and flash. I have Flash 6.
I am using a template built in flash and there is a sub page that has numerous
buttons with roll-over effects that were pre-built. BUT they don't point to anything yet.
I want the viewer to be able to click on a button and have each one open a different Jpg in a window next to the rows of labeled buttons.
I imagine this is pretty simple...Perhaps you know of a specific tutorial within this flash help site that addresses this?
Or if there are a few things that you can communicate to help me...that would be awesome!
Thank you!
Field Focus In A Form
Hello, I have a form that contains a back button, when you click the back button the movie goes to frame one where data can be input again. What I am trying to do is get the form to focus on a certain field when it goes to frame one again. I have tried Selection.setFocus and it doesnt seem to be working. the form clip is a movie placed on _level0. This is the code I am using for the back button. What am I doing wrong?
on (release, keyPress "<Left>") {
gotoAndStop (1);
Selection.setFocus("_level0.fname");
Searcher
Form Field InFocus
Hello,
I have a form and want the first text entry field to be in focus when the flash movie loads. ie, when the user starts to type in, the cursor is already in the first box.
Thanks.....Rob
Single Field Form
i've got a script and form that works perfectly with .php
now i want to create a SIMPLE form with just one field that will collect email addresses from visitors (like a newsletter sign up type thing). all i need is a single input text field, a send button, and the script and .php to make it all work.
i thought i had it, but i can't get it to work at all. is there an easy way to do this or does someone have one already made and working that i can take a look at?
thanks,
Clint
Form Field Question
I have a form with three input fields... in frame one i would like to have buttons that direct the cursor to the appropriate field in subsequent frames.
example:
i have a three buttons
email, name, message...(they go to frame 2,3,4 respectively)
i would like to click the email button and have it go to the input text field that is for the email address...
or click name and go to name field
and so on...
i have the tab order correct where it tabs through correctly.
but when i click name... it still goes to the input field for email..
which is the one on top...
is this possible
Problem With Form Field
Hi all
I have a problem with a php flash form processor i downloaded from this website
the flash form works fine and i get the email with all the fields information...
but in the "comments" field of the form - set as multiline - if you hit the "enter" button while writing the text only the first line will arrive in the mail...the rest is ignored by the php form processing file...
can you help me solve this?
here is the php code used...
<?
/************************************************** ****
**
** Flash Mx PHP Mailer
**
** By - David Khundiashvili
************************************************** *****/
/************************************************** *****
Enter your site details below!
************************************************** *****/
// Enter your contact email address here
$adminaddress = youremail@yoursite.com;
// Enter the address of your website here include http://www.
$siteaddress =http://www.yourwebsite.com;
// Enter your company name or site name here
$sitename = "yourcompany";
/************************************************** *****
No need to change anything below ...
************************************************** *****/
$date = date("m/d/Y H:i:s");
if ($REMOTE_ADDR == "") $ip = "no ip";
else $ip = getHostByAddr($REMOTE_ADDR);
if ($action != ""):
mail("$adminaddress","Info Request",
"A visitor at $sitename has left the following information
First Name: $fname
Last Name: $lname
Email: $email
Telephone: $telno
The visitor commented:
------------------------------
$comments
Logged Info :
------------------------------
Using: $HTTP_USER_AGENT
Hostname: $ip
IP address: $REMOTE_ADDR
Date/Time: $date","FROM:$adminaddress");
mail("$email","Thank You for visiting $sitename",
"Hi $fname,
Thank you for your interest in $sitename!
Cheers,
$sitename
$siteaddress","FROM:$adminaddress");
$sendresult = "Thank you for visiting <a href = "$siteaddress" target = "_blank"><u>$sitename</u></a>. You will receive a confirmation email shortly. ";
$send_answer = "answer=";
$send_answer .= rawurlencode($sendresult);
echo "$send_answer";
endif;
?>
check the $comments field...the problem happens there...only the first line will be read but if you hit enter and type more all the other text will be ignored...
thanks!
Reseting Form Field
I've created a simple form with one input field for viewers to submit an email address to join a mailing list. It works great, the only problem is after they click the submit button, the input field (message) doesn't reset OR my dynamic text field (mailstatus) thanking them for joining. Can anyone help?
this is the actionscript for my button:
on (release) {
subject = "Mailing List";
this.loadVariables("http://www.djbreak.com/simplemail.php", "POST");
}
this is my php script:
<?php
$email ="breakgetnice@aol.com";
$subject = $HTTP_POST_VARS['subject'];
$message = $HTTP_POST_VARS['message'];
mail($email, $subject, $message);
echo "mailstatus=Thank you for joining!&thescript=done&";
?>
Why This Form Field Does Not Work
i set up text feld set it to dynamic
then attached the scroll bar
and still i can not see the scroll bar just the whitefield where the scroll should be
can someone tell me what i am doing ewrong
Only 1st Field In Form Clears
Hello and thank you.
I am using Flash 8 to make an email form.
I have 5 fields but only the first field clears when you click
on the clear button.
This is the action script that I have. Any ideas?
on (rollOver) {
gotoAndPlay("s1");
}
on (releaseOutside, rollOut) {
gotoAndPlay("s2");
}
on (release) {
_parent.your_name="Name:";
_parent.your_phone="Phone:";
_parent.your_email="Email:";
_parent.your_weddingdate="Wedding Date:";
_parent.your_message="Message:";
}
Flash Form Field To ASP
I am using cs2 (flash 8 action script 2).
I want to take a field and send it to an asp page to use the information for a search.
It seems to recieve it in the asp page, (only it is huge---literally-see attached)
The field is named Qzip
My Flash Action Script is:
on (release) {
getURL("http://www.4manscramble.net/content/courses/search.asp", "_self", "POST");
}
My asp code isnote this is the basics as the real search is a ton of trig code)
strZIPCode = Request("Qzip")
If strZIPCode = "" then
Response.Write "<font color=red >We are sorry the zipcode wasn't read right. We have sent this issue to our team. Feel free to try again</font>"
strZIPCode = "44024"
Else
Response.Write "the zipcode is: "&strZipCode&""
End If
DatabaseQuery = "SELECT Latitude, Longitude FROM ZIPCodes WHERE ZIPCode =" & strZIPCode & " "
Response.Write ("<br>The Query ="&DatabaseQuery&"<br>")
Dim rsZIPCodes: Set rsZIPCodes = CreateObject("ADODB.Recordset")
rsZIPCodes.Open DatabaseQuery, dbConn
If rsZIPCodes.EOF Then
'ZIP Code does not exist - report to user...
Response.Write "<font color=red >We could not find that zip code. Feel free to try again</font>"
Else
do the search
//////////////////////////
at this point it seems the data passed but reall it hasn't.
If I use a regular form text field. No problem
Drop-down Form Field In AS3
Hey all,
Is it possible to make a drop-down form field w/in AS3? I don't need to send any data externally or anything -- so I don't need (I assume) any PHP code.
The selected value from the field is simply going to change a variable in the timeline.
Thx
How Do I Validate This 3 Field Form?
Here is my function checkForm.
3 Fields - Name, Message & Email
Name = This should be more than 1 character
Message = This should be more than 1 character
Email = This is booleon set (True or False)
If these 3 Fields meet up to this criteria - I would like it to proceed to the else statement I have below.
I would like a method of validation which is alot more effective than the one used below:
ActionScript Code:
function checkForm() {
var myName = _root.pages_mc.nameField.text;
var myMessage = _root.pages_mc.messageField.text;
var myEmail = _root.pages_mc.emailField.text;
//VALIDATE NAME & MESSAGE FIELD
if (myName == ""){
_root.pages_mc.errorField.text = "Please fill out your name";
Selection.setFocus(_root.pages_mc.nameField);
} else if (checkEmail(myEmail) == false){
_root.pages_mc.errorField.text = "You have entered an invalid email address";
} else if (myMessage == ""){
_root.pages_mc.errorField.text = "Please leave a message";
Selection.setFocus(_root.pages_mc.messageField);
} else if (myEmail == ""){
_root.pages_mc.errorField.text = "Please write your email address";
Selection.setFocus(_root.pages_mc.emailField);
} else {
_root.pages_mc.errorField.text = "";
myXML.firstChild.appendChild(myXML.createElement("entry"));
myXML.firstChild.lastChild.attributes.myName = myName;
myXML.firstChild.lastChild.attributes.myEmail = myEmail;
myXML.firstChild.lastChild.appendChild(myXML.createElement("myText"));
myXML.firstChild.lastChild.lastChild.appendChild(myXML.createTextNode(myMessage));
myXML.sendAndLoad("processXML.php", receiverXML);
}
}
I've tried it running the function above and it seems to process the else statement when the if statements say otherwise. So a better method would be really helpful.
Referencing A Value Within A Form Field
Hey all...
Within my org. we have a set of variables that we can use within our .asp forms that are stored on a DB but can be called within our forms. Basically when a user longs into their machine and opens up one of our html/asp forms their user information Name/department/title/phone/branch address are auto populated within the 'profile' section at the top of the form. Below is an example of the code used:
<td width="450"><input name="UserName" type="text" id="UserName" value="<%=g_emp_fullname%>" size="50" maxlength="100">
Instead of building forms via html/asp I would like to try and build a 'smart' form via flash and pass all of the variables collected to a processessing .asp page that generates the email.
What I can't figure out is how to, within flash, reference the...value="<%=g_emp_fullname%>" , within the Flash form fields so the values come up.
I would like Flash to auto-recognize the values just like my .asp page did.
Any ideas on code referencing within Flash is greatly appreciated as always!!
Regards,
SKURGE
Form Field Focus?
Hi, I was wondering how to make a form field in flash that has text already in it when the form loads, and when the user clicks the field that text dissapears so they can enter their text.
I've also seen these forms that will put the initial text back if no text is entered and the user clicks a different text field.
Can anyone point me in the right direction? Thanks.
Form Field Validation And ASP
Hello
I have a simple Flash contact form with name,email, message, etc fields and would like ASP - not Flash - to validate the fields. So if a site visitor completes the form and presses 'submit' while having omitted the @ sign, for example, from his email address, then ASP would tell Flash to display something like 'Please complete the email address field'.
I have some ASP (VB Script) which does this, but how do I pass it to Flash, and how would I get Flash to display it in a simple dynamic text box next to the form? And what happens if more than one field has been incorrectly completed?
Many thanks for any help.
_Postman
Get Form Field Values
Hey Guys,
I'm trying to grab the values of two text fields called "userinput" and "passinput" then turn them into variables.
This is what I have
on (release, keyPress "<Enter>") {
var user = (w.e code i use to grab the value);
var pass = (w.e code i use to grab the value);
then the rest of my code continued blah blah blah
}
If you could help me this would be great.
Referencing A Value Within A Form Field
Hey all...
Within my org. we have a set of variables that we can use within our .asp forms that are stored on a DB but can be called within our forms. Basically when a user longs into their machine and opens up one of our html/asp forms their user information Name/department/title/phone/branch address are auto populated within the 'profile' section at the top of the form. Below is an example of the code used:
<td width="450"><input name="UserName" type="text" id="UserName" value="<%=g_emp_fullname%>" size="50" maxlength="100">
Instead of building forms via html/asp I would like to try and build a 'smart' form via flash and pass all of the variables collected to a processessing .asp page that generates the email.
What I can't figure out is how to, within flash, reference the...value="<%=g_emp_fullname%>" , within the Flash form fields so the values come up.
I would like Flash to auto-recognize the values just like my .asp page did.
Any ideas on code referencing within Flash is greatly appreciated as always!!
Regards,
SKURGE
Form: Active Field
Hy guys!!!
I have made a form with 7 input text boxes.
What i want: when i play the movie i want the first input text box to be "active" (as i have clicked with the mouse in it).
It's attached variable is: "name" .
I don't want to add an animated line outside the text box...
Regards,
http://www.inwww.ltd.uk
Focusing On Form Field
Im building a site with Flash MX and need to simulate the use of the DOS prompt.
In order for this to work, I need the input filed at the prompt to get focus right away. I dont want the user to be forced to mouse click on the field in order to start typing.
Any help would be great.
[AS]add A Form Into Text Field
Hi, I just wondering if I can add a form into a text field, is there anyway to do it? any component or tutorial on this? thank you~
Form Field Out Of FOCUS
I made a form in flash with focus to change the highlight color but i can't set to multiples field
texto=new Array (ncto,cidade)
texto.onSetFocus = function(oldFocus) {
texto.background = true;
texto.backgroundColor = 0x9DCECC;
text.border = true;
texto.borderColor = 0x336699;
texto.textColor = 0x336699;
};
texto.onKillFocus = function(newFocus) {
texto.background = true;
texto.backgroundColor = 0xffffcc;
text.border = true;
texto.borderColor = 0x336699;
texto.textColor = 0x336699;
};
what should be worng?
thanks
molotophy
Highlight Form Field
how can I make a highlight form field.
like when the mouse click in the filed to type the box change color.
thanks in advanced
molotophy
How To Validate A Form's Text Field
I'm not very good with scripting, and am having a problem with a simple form that has 3 states: the form itself; an "invalid" error frame; and a "thanks" frame for successful submissions.
I need to setup 2 conditions for a field, in which the user types in their name. it's named "lotusnotesID".
if the field has any blank spaces, it should goto the "invalid" frame that displays an error message and asks them to retype their ID. if the field doesn't have any periods between their name (e.g. john.m.smith) they should goto the "invalid" frame and retype their ID.
my actions are set up in a button within the form. it reads as follows:
on (press) {
if (lotusnotesID == "Key.SPACE" ne "." ne "") {
gotoAndStop ("invalid");
} else {
loadVariablesNum ("http://creativeservices.accenture.com/client.stage/sfmoma/cdontsMail.asp", 0, "POST");
gotoAndStop ("thanks");
}
}
as far as I can tell, it's setup correctly. the problem is that when I test it, the submit button will take me to the "invalid" frame if the text field contains a space, or is missing a period, or is blank, but once I'm in the "invalid" frame and retype the ID correctly, it won't submit properly and goto the "thanks" frame. also, if I type the name correctly initially, it works fine.
am I using the correct operators? any ideas?
thanks very much,
dan
eeth22@yahoo.com
Attachment Field In A Dynamic Form
I have a CD interface created in flash 5 and a form inserted in it. I want to know if it's possible to add an attachment field with the "Browse" button in the form popop, for allowing the user to attach a file before sending his request..
any idea ?.. a browse button for browsing his HD to attach the file..
thanks for ur time..
Flash Form - File Field
Does anyone know how to create a file field in flash (the the field that has a text box accompanied by a "Browse... " button next to it). I want the user to be able to locate a file and upload it via flash. Thanks!
Code For CC Field In Email Form?
Hello all,
I'm making a simple form that will generate an email in Outlook with the info you filed out.
Here is the code:
email = "";
mailto = "mailto:" add name add "<" add email add ">";
name = "Enter Name";
subject = "Subject of Email";
However, I also want to define who the email will go to in the CC. Anyone know how to do this?
I imagine its pretty simple but i can't get it to work for some reason.
Thanks in advance,
S.
|