Wrox Programmer Forums
|
BOOK: Professional PHP 5 ISBN: 978-0-7645-7282-1
This is the forum to discuss the Wrox book Professional PHP5 by Ed Lecky-Thompson, Heow Eide-Goodman, Steven D. Nowicki, Alec Cove; ISBN: 9780764572821
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional PHP 5 ISBN: 978-0-7645-7282-1 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 August 17th, 2005, 04:18 PM
Registered User
 
Join Date: Jul 2003
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default Chapter 6: CollectionIterator

I got an error when I tried to use the CollectionIterator class - PHP Fatal error: Class CollectionIterator contains 1 abstract methods and must therefore be declared abstract (Iterator::valid) in class.CollectionIterator.php on line 33.

Here is my solution: It looks like the book is using PHP 5.0.0RC2, and I'm using PHP 5.0.4. One of the method names for the Iterator built-in function has changed. The book uses hasMore(), but the correct method name is valid(). If you look at the error message I got, that's what it was telling me (but, I didn't have enough experience to understand it at first).
 
Old December 14th, 2007, 05:09 AM
Registered User
 
Join Date: Oct 2006
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks man!!!!!!! :D
Your post was very helpful for me!
It works!!!!!!!!!!!!!!!!!!!!!!!






Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 2 - End of chapter exercises whizzkid1892 BOOK: Beginning PHP5, Apache, and MySQL Web Development ISBN: 978-0-7645-7966-0 1 July 30th, 2008 12:02 PM
chapter 7 - chapter 11 pelopito BOOK: Beginning CSS: Cascading Style Sheets for Web Design ISBN: 978-0-7645-7642-3 3 January 6th, 2008 11:40 AM
Generics chapter 12 difficult chapter i found ...? Larryz C# 2005 1 July 4th, 2007 09:40 PM





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