Forum Moderators: coopster

Message Too Old, No Replies

Showing my Ignorance: A Windows Guy Learning PHP

The basics of using a database in php4

         

RedBaron

5:53 pm on Sep 29, 2004 (gmt 0)

10+ Year Member



Hello all, I'm really going to show my ignorance here. I'm an classic ASP programmer; however, the .NET thing has convinced me to start learning PHP. I have Windows XP on my computer. My hosting can handle php4 (Appache Server).

I want to learn how to implement a database using php. Before I would create a database using Access, upload the database to the server (different server) and then manipulate it using ASP and SQL.

My question in this long winded post is... How do I create a database to upload my PHP enabled server. Is there an equivalent to Access or something?

I told ya I was going to show my ignorance. I'm a complete noob to this. I'm a Microsoft kinda guy, but wanting to change my ways.

Robino

5:58 pm on Sep 29, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member




That post wasn't long-winded at all. You're obviously new here.

The most common db used w/ PHP is MySQL.

I would also recommend using a db interface management tool like PHPmyAdmin.

Just search, "mysql" at sourceforge.net and you'll find it.

mincklerstraat

6:03 pm on Sep 29, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You'll probably have to have a database 'created' which means, simply, that there's a place where you can put all the database info that you want to 'make'. Your host can do this for you - or maybe you can do it via your hosting admin panel. It'll have a name, and then you can add a user and a password for this database. You will want to keep this info handy because you'll need it in php so you can connect to the database in php. 'Create' technically just means making a new empty database, with no table structure or anything. Then you'll want to get some kind of tool that puts the database there - like phpmyadmin, for example, very easy to install and easy to use. Your host may already have that installed for everybody to use. If you have cpanel, try clicking on 'mysql' and there might be a link there to phpmyadmin.

You'll first want some kind of database structure - you know, the empty tables with various fields in them - you can make this with phpmyadmin and then it directly 'makes' these in your database on the server. Or you can use some kind of 'frontend' program, like mysqlcc available from mysql.com, which does this on your own local computer. When your info here is ready, you make a 'sql dump', and this can then be uploaded via phpmyadmin and that adds those tables and info stuff to your database.

Then you'll probably use php and just your browser to populate the rest of the database.

RedBaron

6:20 pm on Sep 29, 2004 (gmt 0)

10+ Year Member



Thanks for the help guys. Will mysqlcc or MySQL run on Windows XP or is that a Linux program? Thanks again.

brakthepoet

6:40 pm on Sep 29, 2004 (gmt 0)

10+ Year Member



From the MySQL website [mysql.com]
Cross-Platform Support. MySQL is available on more than twenty different platforms including major Linux distributions, Mac OS X, UNIX and Microsoft Windows.

That does include the MySQL Control Center, along with the database and other MySQL-related programs.

There are a number of fantastic tutorials out there for setting up Apache, PHP, and MySQL together on a WinXP box. Do a few searches on your favorite search engine and you're bound to come up with one that suits you.

<edit>oops - left out a line</edit>

henry0

10:57 pm on Sep 29, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Red Baron
I just published here a tutorial that will answer all of your questions

Install Apache, PHP, MySQL and PHPmyAdmin on XP [webmasterworld.com]

give a try and report

cheers

Henry