flex and php coding example

flex+php :-> for Freshers

If you know php and don’t have any idea about flex (like me), then don’t worry here is a very understandable and easy tutorial for you.

Step 1: Close your eyes and relax for 2 minutes.

Step 2: Open your eyes.

step 3: Open Adobe Flex.

Step 4: Click on File menu -> New -> Flex Project -> project name write here login -> Next -> Next -> Finish

Step 5:In Left panel of flex window you can see login tab> click on src -> double click on -> login.mxml

Step 6: In Center panel of flex window you can see (login.mxml) > click on -> source -> delete all code that appear now (this is 3 line or more lines delete all)

step 7: copy the code given below

click here for download the code

step 8: paste the above downloaded code in login.mxml page.

step 9: ok fine till here. Again close your eyes for 2 minutes.

step 10: open php wamp server : open www folder create here a folder here with the name “flex” then create folder “jay1″ and make a file here with the name “jay2.php” the path should like this wamp/www/flex/jay1/jay2.php

Step 11: Now copy the php code given below

click here for download the code

step 12: paste the above downloaded code in jay2.php page.

step 13: Close your eyes again, relex for 2 minutes.

step 14: Now plz select the below line MYSQL/DATABASE code

[sourcecode language='css']

– phpMyAdmin SQL Dump
– version 2.10.1
– http://www.phpmyadmin.net

– Host: localhost
– Generation Time: Feb 18, 2009 at 01:28 AM
– Server version: 5.0.45
– PHP Version: 5.2.5


– Database: `flex`

– ——————————————————–

– Table structure for table `flex1`

CREATE TABLE `flex1` (
`id` int(16) NOT NULL auto_increment,
`username` varchar(256) NOT NULL,
`password` varchar(256) NOT NULL,

– Dumping data for table `flex1`

INSERT INTO `flex1` (`id`, `username`, `password`) VALUES
(43, ‘jay1′, ‘bharat1′),
(44, ‘jay2′, ‘jay2′),
(45, ‘jay3′, ‘jay3′),
(46, ‘jay4′, ‘jay4′),
(47, ‘jay5′, ‘jay5′);

step 15: Now plz paste the above line MYSQL/DATABASE code in your mysql browser and execute (means like this database)

step 16 : Ok you are near about to complete this project again once come to flex page and open login.mxml and press the key Ctrl+F11 for run the application, now enjoy project is complete.

step 17: This tutorial validate the data and alert the result that comes from php.
step 18: Thanks enjoy now, bye.
NOTE : For download flex (if you don’t have) UseThisLink

   Share on Facebook

Page views:7332