php explained by pratical exercises?

Soldato
Joined
7 Jan 2007
Posts
10,607
Location
Sussex, UK
Been messing with wordpress on and off for a year and wrote a couple of small scripts in php with some help but feel it is'nt sinking in.

Where can I find basic exercises and tutorials for a total beginner?

I would like to be able to do the following in time:

1) Build a 'Contact Us' form and send the message to an email address.

2)Scrape data from an rss/xml feed and place the numeric data in a mySQL database (I can do the sending data to database bit already)

3) Create additional custom boxes in wordpress write panel to pull in data from my mysql database to display on a post.

Am I jumping ahead to much?

are these tasks realistic for a beginner to attempt in the next few months?

I don't really understand the basics tbh, I just have read around the web and mashed code together to get things partially working. My worry is when the code breaks. I have little knoweldge on how to repair anything. So, I want to start from scratch, from the ground up, properly commenting my code so I understand what I/it is doing.
 
At least you have realised that you shouldn't just go copy & pasting code from the net and using it on your site... unfortunately many people make that mistake.

There are loads of tutorials online that cover all you need. Try take a look at http://thenewboston.org/tutorials.php a lot of people like his style of teaching and he has some good practical examples.

How do you best learn?
Book on your desk?
Watching others, video?
reading online?
 
I think I need practical tutorials with explanation as I go through.

With building up of complexity as time goes on.

I have a couple of beginner PHP books, but they gibber on about stuff. I feel for programming I need to be following a tutorial as I do it then using the book to get more detail on $variables or loops etc etc, which I can use the two books for.
 
The site above has a tutorial on creating a Stock market script here http://thenewboston.org/list.php?cat=48 he used to have one on putting together a online game aswell but that doesn't appear to be there anymore.

Alternatively I like the sitepoint books you can get them at reasonable prices for the ebook version. They have one that is http://www.sitepoint.com/books/phpmysql4/ also the php anthology book provides good solutions to real world examples.

As you have some reference type books it might be worth downloading a script installing it then working out how it does what it does. This can prove to be a good way to learn.
 
the headfirst book throws you right in, first chapter is creating a HTML form and using PHP to write it to an email then a database.

Explains it as it goes as well.

The whole book is based around "learn by doing" as they offer free taster chapters on the head first website :)
 
the headfirst book throws you right in, first chapter is creating a HTML form and using PHP to write it to an email then a database.

Explains it as it goes as well.

The whole book is based around "learn by doing" as they offer free taster chapters on the head first website :)

Just downloaded there sample, it reads a lot bette than my current books, gonna guy it.

It does a form from the off which is like the contact us box i wanna do!
 
Back
Top Bottom