Am I even close? (php, mySql)

I’ve tried to work with the many tutorials out there but I’m still lost. My php seems to be working (connects to mySql) but I cant to get my query into flash. My fla has a movie clip that contains a text field with the variable name myText. Am I even close to getting this to work? Grateful for any input.

// Connect and select.
if ($dbc = @mysql_connect ('localhost', 'username', 'password')) {
if ([email protected]_select_db ('myblog')) {
die ('<p>Could not select the database because: <b>' . mysql_error() . '</b></p>');
} else {
die ('<p>Could not connect to MySQL because: <b>' . mysql_error() . '</b></p>');
// Define the query.
$query = 'SELECT * FROM blog_entries ORDER BY date_entered DESC';
if ($r = mysql_query ($query)) { // Run the query.
// Retrieve and print every record.
while ($row = mysql_fetch_array ($r)) {
print "<p>{$row['date_entered']}<br />
<b>{$row['title']}</b><br />
{$row['entry']}<br /></p>
} else { // Query didn't run.
die ('<p>Could not retrieve the data because: <b>' . mysql_error() . "</b>. The query was $query.</p>");
} // End of query IF.
mysql_close(); // Close the database connection.

onClipEvent (load) {
loadVariables("[http://localhost/blog.php](http://localhost/blog.php)?", this, "GET");