473,405 Members | 2,154 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Flash embeded in PHP file accessing Mysql database....HELP

this is my code and what i get... i'm accessing this through this url

http://192.168.0.2/php/test2/te*****...a&subject=test

it grabs the correct stuff from the database, but doesn't put it into
flash.

this is what i have in the flash file...

onClipEvent (load) {
// assuming you have a personal web server and PHP installed
locally
loadVariables("http://192.168.0.2/php/test2/test.php", this,
"GET");
}

named the textboxes, accordingly, 'name', 'email', and 'content'


and the php....

<html>
<head><title>Flash Test</title></head>
<body>

<br><br>

<?php

//phpinfo();

error_reporting(E_ALL);

$user = $HTTP_GET_VARS['user'];
$subject = $HTTP_GET_VARS['subject'];

$link = mysql_connect('localhost', 'mailer', 'mailer321')
or die('Could not connect: ' . mysql_error());

mysql_select_db('mailer') or die('Could not select database');

$query = "SELECT * FROM email where name = '$user' and subject =
'$subject' order by id desc limit 1";
$result = mysql_query($query) or die('Query failed: ' .
mysql_error());

while ($rows = mysql_fetch_array($result)) {

$name = $rows['name'];
$email = $rows['subject'];
$content = $rows['content'];

}

print "&name=$name";
print "&email=$email";
print "&content=$content";

mysql_free_result($result);

mysql_close($link);

?>

<div align="center">

<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
WIDTH="760" HEIGHT="430" id="test" ALIGN=""><PARAM NAME=movie
VALUE="test2.swf"><PARAM NAME=quality VALUE=high>

<param name="name" value="<? echo $name ?>">
<param name="email" value="<? echo $email ?>">
<param name="content" value="<? echo $content ?>">

<PARAM NAME=bgcolor VALUE=#EEEEEE><EMBED src="test2.swf" quality=high
bgcolor=#EEEEEE WIDTH="760" HEIGHT="430" NAME="test" ALIGN=""
TYPE="application/x-shockwave-flash"
PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"></EMBED>
</OBJECT>

</div>
</body>
</html>
outputs this
&n******@test.ca&email=test&content=test

but no content in the flash text boxes....

any ideas??
Jul 17 '05 #1
1 2781
your variables are not loaded correctly into the flash movie. it has nothing
to do with php. i would ask this on a flash list. for example, flashkit.com

konstantin

"Jason" <ja***@winstorm.ca> wrote in message
news:18**************************@posting.google.c om...
this is my code and what i get... i'm accessing this through this url

http://192.168.0.2/php/test2/te*****...a&subject=test

it grabs the correct stuff from the database, but doesn't put it into
flash.

this is what i have in the flash file...

onClipEvent (load) {
// assuming you have a personal web server and PHP installed
locally
loadVariables("http://192.168.0.2/php/test2/test.php", this,
"GET");
}

named the textboxes, accordingly, 'name', 'email', and 'content'


and the php....

<html>
<head><title>Flash Test</title></head>
<body>

<br><br>

<?php

//phpinfo();

error_reporting(E_ALL);

$user = $HTTP_GET_VARS['user'];
$subject = $HTTP_GET_VARS['subject'];

$link = mysql_connect('localhost', 'mailer', 'mailer321')
or die('Could not connect: ' . mysql_error());

mysql_select_db('mailer') or die('Could not select database');

$query = "SELECT * FROM email where name = '$user' and subject =
'$subject' order by id desc limit 1";
$result = mysql_query($query) or die('Query failed: ' .
mysql_error());

while ($rows = mysql_fetch_array($result)) {

$name = $rows['name'];
$email = $rows['subject'];
$content = $rows['content'];

}

print "&name=$name";
print "&email=$email";
print "&content=$content";

mysql_free_result($result);

mysql_close($link);

?>

<div align="center">

<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
WIDTH="760" HEIGHT="430" id="test" ALIGN=""><PARAM NAME=movie
VALUE="test2.swf"><PARAM NAME=quality VALUE=high>

<param name="name" value="<? echo $name ?>">
<param name="email" value="<? echo $email ?>">
<param name="content" value="<? echo $content ?>">

<PARAM NAME=bgcolor VALUE=#EEEEEE><EMBED src="test2.swf" quality=high
bgcolor=#EEEEEE WIDTH="760" HEIGHT="430" NAME="test" ALIGN=""
TYPE="application/x-shockwave-flash"
PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"></EMBED>
</OBJECT>

</div>
</body>
</html>
outputs this
&n******@test.ca&email=test&content=test

but no content in the flash text boxes....

any ideas??

Jul 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Mirco | last post by:
Hi I have a page written with php and a MySQL Database. Now, I want to redesign the whole, but still with the Database and php. is it possible to design the page with Flash and then to put all...
30
by: Darren Gates | last post by:
hi PHP users, Here's a Flash 7 version of phpMyAdmin: http://www.tufat.com/phpflashmyadmin.php Special features include: drag-and-drop interface for InnoDB table relationships, quick record...
1
by: Sagi | last post by:
i got an html file with flash embeded in it. the flash file load with parameters like this: <OBJECT id="myFlash"...
2
by: Mariame | last post by:
Hi Everyone How to embeded a Flash file ".swf" in aspx page??? Thx in Advance
3
by: johnsonholding | last post by:
Here is the script I have in my page : <!-- Begin function popUp(URL) { day = new Date(); id = day.getTime(); eval("page" + id + " = window.open(URL, '" + id + "',...
3
by: dan | last post by:
Hi all, I have a question about flash-memory lifespan. My database consists of 1 table, the table has 50 fields of 10 bytes each, thus each record will have 500bytes. There are 1000 records in...
3
by: paolazi | last post by:
Hello I have a problem: I have a database(mysql) with the following fields: test, descr, title I want to display them into a flash file. Now my php file called list.php (which collect the...
0
by: Razorholt | last post by:
Hello there - I have written an app in Python and I have embeded the IE browser in order to display some layout - with dynamic content coming from MySql. As Python + IE browser + Flash may be...
0
by: prince23 | last post by:
hi, i am trying to develop an flash application. where they have designed the entire front end by flash. now i need to doing the functionality part like taking the data from...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.