Weborum Webmaster Forum > Never Used PHP before where do i start?
Help - Search - Members - Calendar
Full Version: Never Used PHP before where do i start?
Weborum Webmaster Forum > TUTORIAL ARCHIVE - tutorials & scripts to save you scouring the internet. Please feel free to add your own. > PHP Tutorials & scripts
Daniel8_9_3
ok finally i have an account with SSI includes, i want to do some things to make my site interactive namely some polls, maybe an email list, rate it, change themes etc.

i dont know anything about PHP and i cant make heads or tails of it right now, so where do i need to start to understand PHP?

guestbooks can be done in PHP to right?
bassrek
I've always found w3schools provides great step-by-step lessons:
http://www.w3schools.com/php/default.asp

Yes, you can do guestbooks in PHP, too. It's best done when you have access to a database, and I see from your other post that you have MySQL availability, too.
Daniel8_9_3
yeah i have MySql to i figured i would start with php for now i want to learn some basic stuff.

back to the books i go shades2.gif
Josh
Your host does support php then?

SSI and PHP are in now way alike.

I suggest getting PHP and MySQL Web Development by Luke Welling and Laura Thompson.
That's a great book and it's worth all of the money.
Daniel8_9_3
what about preinstalled scripts bassrek , im assuming that there are ready made scripts for PHP that can be used.

is this correct?

PHP is just the sciripting language used client side to retrieve data from the database namely MySql right?

so all the php work would be inserting the scripts into my html document and then setting the parameters in MySql right?
Daniel8_9_3
all i have done so far is make a database in MySql.

ohmy.gif im scared to touch anything hahaha biggrin.gif
bassrek
There are tons of premade PHP scripts at http://www.hotscripts.com/PHP/index.html. Check out the w3schools link or the book Josh mentioned for getting started tuts.

PHP is actually run on the server. You can go back and forth between PHP and HTML in your document, but you have to save the file as .php for it to do its magic, including retrieving data from a database - typically MySQL, but not limited to it (unless by your host biggrin.gif)

One of the most common tasks in PHP is creating a connection to a database, forming a query (grab a list of users from a table, for example), and looping through the recordset. It's inside the loop where you would add your HTML formatting to display it on your site.

Daniel8_9_3
i read over that tutorial this morning but i didnt understand it much im gonna have to read a book or something and just experiment with it, I have 2 MySql databases on my account and Perl which i guess means CGI, what do you think would be easier to learn PHP or CGI.

I dont want to be a programmer im going to school for Communication Designs i.e. graphic arts so mostly visual stuff, however i want to know something that would enable me to do some server side stuff but only for a few things like forms, polls, and maybe if i can figure it out switching themes.

bassrek
I've only done a little with Perl, but to me, PHP's syntax is easier to pick up on. Of course, everyone is different. Some think Perl is easier, some ASP etc. It's worth a look at Perl if you have the ability to use it. Something about it may just click for you.

BTW, Perl and CGI aren't technically the same. CGI (Common Gateway Interface) is is a standard for external gateway programs to interface with information servers -- ie HTTP servers (form data, etc.) -- so technically PHP and ASP use CGI. But when the web was in its infancy, perl was the de-facto standard for CGI processing. On top of that, perl scripts a lot of the time had to be saved as a .cgi file and had to be placed (still?) in the cgi-bin directory, so now people tend to use CGI/Perl interchangable as if they were the same. Probably more info than you wanted, but I figured I'd throw that in anyway biggrin.gif
Daniel8_9_3
interesting well i need to figure out which is best for what i need and which would be less work.

plus i need to figure out how to use the MySql database i made on MySql database but i dont want to mess with it just yet for fear of messing something up.

My account has the PHPmyadmin and the same thing for MySql so ive been playing around and exploring them.

dont worry about too much info the more the better dude.

I could take a class at the community college it wouldnt count towards my degree though and they tend to bombard you with more info than you can retain.
Josh
A book works great.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2010 Invision Power Services, Inc.