ActionScript 3.0 :: Email Validation Not Working Correctly
Oct 19, 2010Can anyone tell me why it it throws and error and doesn't validate when the user uses an cap letter in the email?[code]
View 2 RepliesCan anyone tell me why it it throws and error and doesn't validate when the user uses an cap letter in the email?[code]
View 2 RepliesIve been trying to get an email validation working for my form. It works great locally within flash preview, but not locally via its html window, or live. Im not a coder & am self taught to the code will be pretty shabby! (trial & error type gal!)
This is on my send btn,
Code:
on (release) {
if (form.name == null && form.email == null && form.message == null) {
errmsg = "oooh, you didnt write anything";
} else if (form.name == null) {
[code]....
When live it doesnt allow sending if the criteria arent met, but doesnt display the error messages either,
I'm in the process of testing this flash email form: [URL]. Enter '27' in the 'Go To page ' text field and click go to be able to view the form. Once you are viewing the form if you click send without entering any text/data into any field it allows you to send a blank submission. It should send you to a failure screen and tell you to start again.
The actionscript is as follows...
stop();
var senderLoad:LoadVars = new LoadVars();
var receiveLoad:LoadVars = new LoadVars();
// Adds conditional logic for the Submit button that
// validates user input.
[Code] .....
i am not sure if there is a similar thread posted already (i couldn't find one). This is a new class i just put together for a commercial project and i fugured it would be useful for anyone who needs simple email address validation. Its very small (2kb) and appears to be working pretty good. the useage looks like this:
ActionScript Code:
import classes.EmailValidator;
ActionScript Code:
[code].....
been wracking my brain trying to figure out how to install a validation component to this bit of as code. Currently I have it work with an email.php file specifically set up for my client's godaddy site. This part works so I don't want to mess with it too much. But how should I validate the fields then? anyone?
[Code]...
I seem to have a problem with my email validator. I have on my stage an input textfield with a variable of email. After echt keypress it validates the email. I found the following script:
[Code]...
I am doing some forms in Flash Cs4 with AS3. The forms are working well, but i have a code to check if people have enter information in every field.But the verification only works for 2 field. The code is exactly the same for the other but it doesn't work. Can you double check my code and maybe explain me why it doesn't work or maybe how to replace the validation code by another.The validation works only for the LastName data and Email field.Here's the code;
submit_btn.addEventListener(MouseEvent.CLICK, ValidateAndSend);
function ValidateAndSend(event:MouseEvent):void{
//validate form fields[code]........
I am doing some forms in Flash Cs4 with AS3. The forms are working well, but i have a code to check if people have enter information in every field. But the verification only works for 2 field. The code is exactly the same for the other but it doesn't work. Can you double check my code and maybe explain me why it doesn't work or maybe how to replace the validation code by another.The validation works only for the LastName data and Email field.Here's the code;
submit_btn.addEventListener(MouseEvent.CLICK, ValidateAndSend);
function ValidateAndSend(event:MouseEvent):void{
//validate form fields[code]................
I have the following which produces a trace if the user does not type an email address when testing locally, but nothing when testing outside of Flash.
[Code]...
i am working on a simple sign-in form that is going to have some simple local validation before it gets validated by the database.
I am sure this is a simple line of code but I can't seem to get the "re-type" email address field validation to work. Here is a snippit of what I currently have:
ActionScript Code:
public function main():void {
subBtn.buttonMode = true;
subBtn.addEventListener(MouseEvent.CLICK, checkData)
[Code]...
I've created a custom textInput componenet that handles it's own validation using a private validator. The validation is enabled depending on the state of the component i.e. validation is enable when the components state is "edit".However, when the state changes from edit the internal validator is set to not enabled but the validation errors on the textbox do not clear - the textInput still has the red border and on mouseover the validation errors come up. What I want to happen is that when a validator is disabled the error formatting and error messages clear from the text input control.
Does anyone have any idea how to do this I tried setting the internal validator instance to enabled = false and dispatching a new focusOutEvent as below but the validation error formatting is still applied to the textInput contrl.
_validatorInstance.enabled = false;
//clear the validation errors if any
dispatchEvent(new FocusEvent(FocusEvent.FOCUS_OUT));
[code].....
I have used a scrollpane on my new site, it scrolls but only if you click the arrows or click in the scroll bar, if you actuall try and scroll by dragging (which people would because it's long) it vanishes![URL]
View 1 RepliesI am working on a website and I would like it to have a preloader.This website is scripted using Flash CS3 and AS2.There are two scenes, one is "preloader" the other is "tsh".roblem is, the swf file does not display while it loads, then after it loads it displays the preloader for a second and jumps right into the next scene. How can I make it load the preloader scene first, then preload the "tsh" scene? - I have put this code into "preloader"Frame 1:
Code:
var loaded:Number = Math.round ((_root.getBytesLoaded()/_root.getBytesTotal())*100);
mc_slider._x = -500 + (loaded*5);
[code].....
In my flash game the font i choose looks perfectly fine on my computer (being played from a website) but when i use a computer at school or my friends computer, all the font is ALWAYS times new roman.. this happens with every game i make..
I tried switching from tlf text to classic text.... but it didn't change at all.. can someone help please? I have been facing this problem for months now.
i have a MC, which i want to float up and down fluently, so I gave it this script:
onClipEvent(load) {
var step:Number = 0;
}
onClipEvent(enterFrame) {
step+=0.1;
_y+=Math.sin(step);
}
Strangely, the object flies up after a short while, meaning it floats up and down, but more up than down, even if the script itself is pretty straightforward.
I've recently noticed that when I use tweens to fade in/out a mc or to move it along th x/y axis sometimes it doesn't work correctly. In this case I am adding a mc named B_info and some text to the stage and using a tween to fade them in. Testing the movie repeatedly I've noticed that sometimes they don't load or the alpha value is lower than it should be making the the text illegible. I've also had the same problem in the past with x, y tweens whereas the mc failed sometimes to get to the x value as it should.
Code:
Select all//_loading Info
function infoDisplay():void {
//load lines animation
var B_info:infoB = new infoB();
addChildAt(B_info, 0);
B_info.x = 552;
//this is TWEEN 1
var fadeIn:Tween = new Tween(B_info, "alpha", None.easeNone, 0, .5, .8, true);
[Code] .....
I am loading external swf files into a single container( Instance: contents). when I test the movie inside flash it works fine but when I use the generated swf outside flash one of the swf files don't unload the way it is supposed to and therefor the other swfs can't load either. The swf file that dose not unload, contains videos using xml with a list component. Actually I used the tutorial from this website (Flash Video Basics). Here is the code I am using. It is probably kind of crude but I don't understand why it works only when I test the movie.
Code: Select allstop();
aboutArtist.onRelease = function() {
waveBar.gotoAndPlay(2);
[code]...
So I followed the 3D Carousel tutorial, the first part of it and the coding worked fine, but the reflection is not working properly. I used a .PSD file and followed the instructions step by step. I added the action script code in the end, but when I take a look at the preview, the reflection image is displayed just like the original picture. Is the .PSD format a problem?
View 1 RepliesI have a swf loading an external SWF which is a video player. The video player loads fine into the SWF, but if I hit full screen it goes full screen but I cant see anything. Its all black. I can still see the "hit escape to exit" bubble thing.If I embed the video player by itself(ie. ISNT loaded into a swf) the full screen function works fine.
View 3 RepliesThe page I created can be found here: [URL]
The login info should be "letmein77"
This is my AS (2.0):
Code:
loginbutton.onPress = function() {
if (password == "letmein77") {
gotoAndPlay("correct");}
else {
[Code].....
I don't work much with input variables (my focus is more in animation/design than forms and scripting) in my flash movies and i've been scratching my head for days now.
The first scene will have an embedded movie clip and artwork as a background for approximately 150 frames, the next scene (Scene 2) then appears (in the first and only frame) which has the following (AS2) setInterval on it (to play a swf file on a movie clip - the swf lasts a little over 2 minutes. Hence, 122000 milliseconds below):
Code:
mc_demos.loadMovie("swf/aquira.swf");
stop();
[code].....
I'm creating a project with a number of different sections. I've created a index menu with invisible buttons on that takes you to the different sections. This works fine. In each section I wonted a means to get back to this index, so created a index button that is present throughout each section. I've put the event handler in the actions layer on the same frame that the button instance is on (frame 15).
[Code]....
I'm using a version of the pause sound code found on the adobe/page, but it's not resuming the sound from the pausePoint. I have the pause/play function tied to the stage so that my external swfs pause as well. Here's a clip of my code,This is the load audio with swf part:
var fl_Loader_5:Loader;var fl_ToLoad_5:Boolean = true;var channel:SoundChannel = new SoundChannel();var snd:Sound = new Sound();var req_1:URLRequest = new URLRequest("audio/Introduction.mp3");
[code]......
I'm working in pure as3 (no creative suite or xml). I have a sprite. It draws a large rectangle and then a slightly smaller rectangle. I want to change the color of the slightly smaller rectangle when I hover the mouse over it. Right now though it will either not respond (I can plainly have the mouse over the rectangle and nothing happens) or it is slow to respond. In addition the collision area of the rectangle seems a bit off, ie it responds more frequently when I have the mouse on the upper left corner of the rectangle than when I have the mouse elsewhere on it.
[Code]...
I wrote a login system using flex and php, but for some odd reason the php echos back both "true" and "false". why this is happening?
?php
echo "<?xml version="1.0" encoding="utf-8"?>";
//include("connect.php"); // used for your connection to the database.
[code]....
I'm wanting to create a simple red flash effect which entails a red flash suddenly appearing and fading away on screen.
I'm currently doing this by creating a red box as big as the screen and made it a movieclip. I'm then decrementing this movieclips alpha value from 100 to 0 but ofcourse, it's not as simple as that.
It seems that any alpha value greater than 0 makes the object have 100% alpha. So what's going on? How should I do it?
So I have this movie clip with some buttons in it. Two of the buttons (forward and backward) move the movie clip forwards or backwards one frame at a time - this works fine. However the other two buttons (fast forward and rewind) are suppose to move the movie clip forwards or backwards 25 frames at a time (so they always go to 25, 50, 75, 100, etc.) - but here's the problem.
Say for example I'm at frame 150. I press the fast forward button and I'm at frame 175. Now I hit backward and I'm at 174. Now I hit fast forward again to get back to 175 - however my movie clip is jumping ahead to 200, skipping 175 completely - not what I want. I'm just using the gotoAndStop(frame#); commands and have no clue why this is happening. I want the fast forward and rewind buttons to always hit the next 25 increment, not skip the closest one.
I am trying to get my flash buttons working. When I click on them they open a new window and none of the graphics show up. I need it to open in the same window and I have no idea why the graphics aren't linking. They are on my computer not on a server. In addition I need to add multiple buttons to the action script without messing up the entire movie. It seems when I try and add event listeners for the other buttons it won't play at all.want it to go to a page outside of the flash movie. This is a swf placed in Dreamweaver the buttons need to go to other site pages.
View 0 RepliesI am trying to get my flash buttons working. When I click on them they open a new window and none of the graphics show up. I need it to open in the same window and I have no idea why the graphics aren't linking. They are on my computer not on a server. In addition I need to add multiple buttons to the action script without messing up the entire movie. It seems when I try and add event listeners for the other buttons it won't play at all. This is a swf placed in Dreamweaver the buttons need to go to other site pages.
View 1 Repliesso I tried getting this custom scrollbar to work, but the bounds must be screwed up.Whenever I click on the scroller, it shoots halfway down the screen...it then thinks that the middle of the screen is the top bound and the bottom of the screen is the lower bound
ActionScript Code:
// Scroll My Content function - AS3
function scrollMyContent () {
[code]....