# Flash FLA and php files for mysql db

**URL:** https://forum.kirupa.com/t/flash-fla-and-php-files-for-mysql-db/58924
**Category:** programming
**Created:** [July 27, 2004, 3:38am UTC](https://forum.kirupa.com/t/flash-fla-and-php-files-for-mysql-db/58924 "2004-07-27T03:38:36Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![vld](https://avatars.discourse-cdn.com/v4/letter/v/3ab097/32.png) [@vld](https://forum.kirupa.com/u/vld)
#### Post date: [July 27, 2004, 3:38am UTC](https://forum.kirupa.com/t/flash-fla-and-php-files-for-mysql-db/58924/1 "2004-07-27T03:38:36Z")

</div>

The mysql database & table are created  
(I’ve just starting teaching myself php.)  
I’ve uploaded the FLA (homeInfo.fla) which shows what I’m trying to do.  
Am I even close?

THIS IS MY homeInfo.php file:  
\<?

//check for required fields  
if (!isset($firstNameHome) || !isset($lastNameHome) || !isset($emailHome) || (!isset($websiteHome) || !isset($referredByHome) || !isset($addressHome) || (!isset($cityHome) || !isset($stateHome) || !isset($zipHome) || empty($countryHome) || (!isset($landLineHome) || !isset($cellHome) || !isset($faxHome) || (!isset($and1Home) || !isset($and2Home) || !isset($and3Home) || empty($firstNameHome) || empty($lastNameHome) || empty($emailHome) || empty($websiteHome) || empty($referredByHome) || empty($addressHome) || empty($cityHome) || empty($stateHome) || empty($zipHome) || empty($countryHome) || empty($landLineHome) || empty($cellHome) || empty($faxHome) || empty($and1Home) || empty($and2Home) || empty($and3Home)) {  
print “&result=Fail”;  
print “&errorMsg=” . urlencode(“sorry - all fields must be filled out - please try again”);  
exit;  
}

//set up database and table name  
$db\_name = “_**";  
$table\_name = "**_\*”;

//connect to MySQL and select database to use  
$connection = @mysql\_connect (“_ **", "** _\*”, “\*\*\*\*\*\*\*\*\*\*\*”) or die(mysql\_error());

$db = @mysql\_select\_db ($db\_name, $connection) or die(mysql\_error());

//create SQL statement and issue query  
$sql = “INSERT INTO $table\_name (firstNameHome, lastNameHome, emailHome, websiteHome, referredByHome, addressHome, cityHome, stateHome, zipHome, countryHome, landLineHome, cellHome, faxHome, and1Home, and2Home, and3Home) VALUES (’$\_POST[SelecteesHomeID’, ‘$\_POST[firstNameHome’, ‘$\_POST[lastNameHome’, ‘$\_POST[emailHome’, ‘$\_POST[websiteHome’, ‘$\_POST[referredByHome’, ‘$\_POST[addressHome’, ‘$\_POST[cityHome’, ‘$\_POST[stateHome’, ‘$\_POST[zipHome’, ‘$\_POST[countryHome’, ‘$\_POST[landLineHome’, ‘$\_POST[cellHome’, ‘$\_POST[faxHome’, ‘$\_POST[and1Home’, ‘$\_POST[and2Home’, ‘$\_POST[and3Home’)”;

$result = @mysql\_query ($sql,$connection) or die (mysql\_error());

?\>

THIS IS MY hIentry.php:  
&result=okay&entries=

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [July 27, 2004, 11:25pm UTC](https://forum.kirupa.com/t/flash-fla-and-php-files-for-mysql-db/58924/2 "2004-07-27T23:25:27Z")

</div>

The FLA file (homeInfo.fla)

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [July 27, 2004, 11:54pm UTC](https://forum.kirupa.com/t/flash-fla-and-php-files-for-mysql-db/58924/3 "2004-07-27T23:54:41Z")

</div>

use the attahcments feature when you post a message to attach a file.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [July 28, 2004, 3:11am UTC](https://forum.kirupa.com/t/flash-fla-and-php-files-for-mysql-db/58924/4 "2004-07-28T03:11:37Z")

</div>

I must have used use the attachment feature incorrectly - my mistake - will try again.
