Monday, May 28, 2012

How to Make a Painless Php News Technique

Hey and welcome to my tutorial!

Now allows get begun!

Initial we can potentially want to make the table in MySQL employed to retail outlet our information in!

The SQL file appears like this:

paste that into a text document and help save it as information.sql (Don't forget to pick "All Information..."

Now allows get begun on the scheme! Initial we will make the script that gathers the information and outputs them and then we will make the script that adds the information to the database!

Phase 1:

Commence by developing a file called index.php in your webserver.

In that file we will of course start by producing the PHP opening tags like this:

Phase two:

Now we will join to our MySQL server by by using mysql_join() and mysql_pick_db() like this:

Now we are related to the database!

Phase three:

Now allows gather the information and output them! Like this:

Posted at ".$r['date']." by ".$r['author']."" echo $r['content']."" } ?>

Now we are executed with the script outputs the information!

Phase four:

Now allows make the script that inserts the information into the database! It appears like this:

now help save that as acp.php.

Now you might be executed!

Now you have a information scheme wherever you can post information from acp.php and see the information you posted on index.php!

Thank you for looking at!





No comments:

Post a Comment

Note: Only a member of this blog may post a comment.