Wrox Programmer Forums
Go Back   Wrox Programmer Forums > PHP/MySQL > BOOK: Professional PHP6
|
BOOK: Professional PHP6
This is the forum to discuss the Wrox book Professional PHP6 by Edward Lecky-Thompson, Steven Nowicki; ISBN: 9780470395097
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional PHP6 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 11th, 2013, 05:00 PM
Authorized User
 
Join Date: Sep 2012
Posts: 13
Thanks: 3
Thanked 1 Time in 1 Post
Question Chapter 7 - Accessor Methods

I am going through this book written in 2009 ( it is now 2013 ) so when I came across the User class presented in chapter 7, I had some questions.

My question is why didn't the authors use the PHP magic methods "__get()", and "__set()"?

Were they not available at the time of writing? Also this class uses the "eval" function. Isn't that bad practice?

EDIT: I found the following on the PHP website http://php.net/manual/en/function.eval.php

Just wondering, and if anyone can help me out that would be great.

Last edited by ericrjones1; April 11th, 2013 at 05:03 PM.. Reason: Added a link to the PHP Manual regarding the function "eval"





Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 4 Questions: The Syntax of Methods? JohnnyBGood BOOK: Beginning iOS Game Development 2 February 2nd, 2012 03:31 PM
Chapter 3 Utils methods thomas.b BOOK: Beginning Cryptography with Java 1 September 11th, 2009 11:54 PM
Chapter 7 : Wrong SQLDataProvider methods claudiotereso BOOK: Professional DotNetNuke Module Programming ISBN: 978-0-470-17116-5 1 March 4th, 2009 11:13 AM
Chapter 5 Shadowing Shared Methods ahanshew BOOK: Professional VB 2005 ISBN: 0-7645-7536-8 0 February 23rd, 2006 04:06 PM





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