[nycphp-talk] recommended introductory PHP text
inforequest
sm11szw02 at sneakemail.com
Thu Sep 9 12:29:54 EDT 2004
David Mintz dmintz-at-davidmintz.org |nyphp 04/2004| wrote:
>Suppose you were teaching a PHP course (10 sessions x 3 hrs) to people
>who knew only HTML. What book(s) would you recommend?
>
>
Hi David.
It seems to me there are :
1- books which try to be a paper manual (comprehensive function
reference, tables of operators, flow-control, etc)
2- books which "introduce" PHP as a language for ______ professionals
(website, database, specific database, application development, etc)
3- books of didactic examples (not worthy of production use, but
demonstrative)
4- books of real-world examples (worthy of production use, but not
demonstrative nor easy to understand)
5- books for ____ progammers to start using or switch to PHP (PHP for
HTML programmers, PHP for perl programmers, C programmers, etc)
So in your case I could see a need for type 5.html and maybe a type 1
reference.
Personally I have never found a type 5.html book I liked so i would not
use one if I were teaching that course. As far as I have seen, they
either teach PHP as a script drop-in to get dynamic with the HTML markup
(to me that's nasty) or they are too advanced in PHP (trying to use PHP
to generate every needed HTML markup string). For HTML people not well
versed in CSS, this could be disastrous (since there are overlaps in the
way CSS and PHP can be used for dynamic webpages - CSS can be data-based
markup, and PHP beginners often use PHP for data-based markup).
I would teach the subject from the outside in, first approaching the
environment of HTML (browser, server, http) and then stepping into HTML
markup (seeing how it works with the environment) and then stepping back
out to use PHP between the HTML markup and the environment for select
tasks where it makes sense. Eventually those select tasks will include
certain tasks normally considered HTML domain. This approach is
scalable, so that if you get as far as the overlap between CSS and PHP,
or approach XML, PHP deployment seems natural.
I have not seen a book that does that well *for beginners* but there are
two books I feel do this well for intermediate programmers :
Greenspan/Bulger "MySQL/PHP database applications" and Welling/Thomson
"PHP and MySQL Web Development".
If I had to give out a book, I'd want to pick one that had lasting value
(and that rules out the "comprehensive reference" books). A book like
PHP Cookbook for example... with a clear communication that it is a
reference book and not a course textbook. I hesitate to hand out
cookbooks, however, because it is so easy to produce script kiddies that
way.
Good question. Good luck.
-=john
More information about the talk
mailing list