NYCPHP Meetup

NYPHP.org

[nycphp-talk] Transitioning from Beginner to Intermediate PHP

Jake McGraw jmcgraw1 at gmail.com
Wed Jan 16 20:30:55 EST 2008


Couple of suggestions:

1. Really read the documentation available at php.net, it is the best
resource available online. At the very least, go through the the
Language Reference section (although you can ignore the sections
pertaining to PHP4). Additionally, anytime you're doing something with
a string or array, see if there is a function available for what
you're doing. I'd say 90% of the time someone has already done the
hard work and all you need to do is read the documentation. As a short
cut, typing  "http://www.php.net/foobar" into the address bar will
automatically search the PHP function list for any functions like
"foobar".

2. Learn a templateing system, my personal favorite is Smarty
[smarty.php.net] and get all of your HTML out of your PHP code. This
ties into a larger lesson for all programmers, that is learning
Model-View-Controller pattern
[wikpedia.org/wiki/Model-view-controller].

3. See how the pros do it, download Drupal [drupal.org/download] or
Vanilla [getvanilla.com] or some other Open Source PHP project and
look at some of the conventions these developers employ. You need not
review every line, but get an idea for how these people organize their
code. Install the framework and see how things work.

That is how I've done things and I feel like I'm getting there. FYI, I
started using PHP professionally about 2 years ago, but most of what I
learned, I've accumulated in the last 6 months working as the sole
developer for a major PHP application. You won't necessary move on
from a noob to pro by just reading the documentation and doing the
exercises, find something to work on (maybe write your own database
driven blog) and throw yourself into it.

Good luck!
- jake

On Jan 16, 2008 8:00 PM, B.A.S. <lists at nopersonal.info> wrote:
> Hi Everyone,
>
> I'm trying to move from being a rank beginner to an intermediate level
> of programming PHP. While practicing & trying to learn something new
> every day, I'm also reading up on security (Essential PHP Security by
> O'Reilly & Pro PHP Security by Apress).
>
> Unfortunately, I still have a really tough time trying to work out the
> logic of what I want a script to do, and my code is pretty primitive &
> verbose because of that (I have to painstakingly step through each
> little bit of logic in order to wrap my head around anything).
>
> What I should be doing to get to the next level? Should I read up on web
> application design? OOP? Just keep plugging away? What do you guys use
> when working out the logic of an application you're building? I'm
> guessing that would be some kind of flow chart?
>
> What about IDEs? Because of my HTML coding & graphic design background,
> I'm still using Dreamweaver--would I perhaps learn faster or be more
> productive using Zend Studio (or even something less expensive like
> phpDesigner)?
>
> Please forgive the numerous questions, but I'm 40+ years old and want to
> approach this professionally, not just be some hack who writes sloppy
> code for for beer & pizza money and doesn't care about the client.
>
> TIA,
> Bev
> _______________________________________________
> New York PHP Community Talk Mailing List
> http://lists.nyphp.org/mailman/listinfo/talk
>
> NYPHPCon 2006 Presentations Online
> http://www.nyphpcon.com
>
> Show Your Participation in New York PHP
> http://www.nyphp.org/show_participation.php
>



More information about the talk mailing list