Author Topic: PHP MY SQL HELP!!!!!  (Read 1302 times)

bigmuddyfoot

  • New Member
  • *
  • Posts: 1
  • Karma: +0/-0
    • View Profile
PHP MY SQL HELP!!!!!
« on: January 31, 2009, 06:45:26 PM »
Hey Guys nd Gals

I need some HELP!! LOL i can not get this coad to work.. Here is what i got

URL to the website with the PHP file: http://www.donavonscreativeinnovations. ... 20text.php

The content in side the PHP  file
Code: [Select]
<?php
mysql_connect
("localhost""snip""snip") or die(mysql_error());
echo 
"Connected to MySQL";
mysql_select_db("donavon_text") or die(mysql_error());


$page="Home";
$query="SELECT Bodytxt FROM Text WHERE PageName='$Home';

$result = mysql_query($query);
$row = mysql_fetch_array($result) or die(mysql_error());

echo $row[0&#93;; // Welcome to my webpage
?>

Here are som post i have made
http://answers.yahoo.com/question/index ... 146AAaUwM1
http://answers.yahoo.com/question/index ... 339AA2ffLW

Here is what i need this Code to do
I need this code to get text out of the database
Here is the PHP My Admin Database view

I want it to pull data out of Just the Body text Secton of only the home page.
For what ever reason i can not get it to do this.

Can some one plz help me i know nothink about PhP i just started learning it this week.
!!!!! Thank you so much !!!!
« Last Edit: February 04, 2009, 10:44:46 AM by milesburton »

milesburton

  • Regular Member
  • **
  • Posts: 75
  • Karma: +0/-0
    • View Profile
Re: PHP MY SQL HELP!!!!!
« Reply #1 on: February 04, 2009, 10:46:06 AM »
You need to fully qualify your table name matey. include the database prefix


ie: select * from database_tablename where x=y