Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Search | Today's Posts | Mark Forums Read
BOOK: Beginning PHP4/PHP 5 ISBN: 978-0-7645-4364-7; v5 ISBN: 978-0-7645-5783-5
This is the forum to discuss the Wrox book Beginning PHP4 by Wankyu Choi, Allan Kent, Chris Lea, Ganesh Prasad, Chris Ullman; ISBN: 9780764543647
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning PHP4/PHP 5 ISBN: 978-0-7645-4364-7; v5 ISBN: 978-0-7645-5783-5 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #11 (permalink)  
Old November 8th, 2003, 04:37 PM
Authorized User
Join Date: Oct 2003
Location: , Ok, .
Posts: 39
Thanks: 0
Thanked 0 Times in 0 Posts

I believe this is what makes learning something new very difficult.

For example, on the Sun.com site under Learning Java, I was taking their little learn java course about writing an app. Well, a year or so goes by after each lesson. After two years, finally a lesson comes out but the author decides to rewrite the code to make it more effective. I dont know why because I was still learning what we were doing originally.

Same with php. Its hard if the authors do not teach the reader properly (global variables OFF), and its even harder if the code is written incorrectly or could be written easier using something different.

As for this looping, Im just glad it works now.

Reply With Quote
  #12 (permalink)  
Old November 8th, 2003, 04:51 PM
Friend of Wrox
Points: 2,570, Level: 21
Points: 2,570, Level: 21 Points: 2,570, Level: 21 Points: 2,570, Level: 21
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Jun 2003
Location: San Diego, CA, USA
Posts: 836
Thanks: 0
Thanked 0 Times in 0 Posts

The problem, in my opinion, is that authors that write books (I've ranted about this before, so I'll keep it short) are often NOT expert programmers or writers or both.

If a programmer wants to teach you about looping, they have to come up with some sort of toy example that allows them to USE a loop. The beginning programmer is only supposed to come away with the knowledge of various loops, and how to use them.

Unfortunately, if the example itself doesn't really look like it lends (no pun intended) itself to the concept being taught, the whole thing just looks unwieldy and silly.

In the authors' defence, in regard to register_globals, NO ONE turned register_globals off in their code because PHP had it ON by default. It allowed a really slick and elegant approach to solving problems. A programmer only had to know if $logged_in was set, he didn't care where, because he was under the assumption that it came from an appropriate source.

These kinds of assumptions led a lot of programmers to write really ambiguous and security-hole-prone applications.

As with any language, PHP is evolving, and it's understandably difficult for a new programmer just learning to learn the language as it existed when most PHP4 books were written when things are so different now.

But it's not impossible. The more you stick with your learning, the more you learn about the language in it's "faulty" stages, the more the fixes and changes will make sense to you. As an experienced PHP3 programmer, learning to write code with register_globals off was immediate, because the reasons behind the change were so clear and obvious (once I read them!).

So what's the point? I guess what I'm trying to get at is DON'T let your frustrations with the evolution of a language or it's "common practices" get in the way of your learning it. When a language evolves, EVERYONE (beginning to expert) is learning it at the same time. People with a head start pick up new concepts relatively quickly, but they have the DISadvantage of breaking old bad habits, whereas newer programmers are given the benefit of learning things the "right" way from the start.

Okay, rant over.

Take care,

Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
break for-each loops, or limit amount of loops warhero XSLT 2 July 4th, 2007 02:18 AM
More than 150 Ajax links ajax JSP Basics 2 January 20th, 2007 02:46 AM
Ch5 : Form4.php pg 156-8 ... Not stepping iamdaniel BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 2 January 27th, 2006 12:58 PM
While loops and For loops in XSLT spencer.clark XSLT 1 August 5th, 2005 09:50 AM
Chapter 5 page 150 - Wondering why.... potassium Beginning PHP 3 July 27th, 2003 12:05 AM

All times are GMT -4. The time now is 04:44 PM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.