Core PHP Programming (Anglais) Broché – 5 août 2003
|Neuf à partir de||Occasion à partir de|
Descriptions du produit
Quatrième de couverture
Fully revised for PHP 5
—Andi Gutmans, PHP 5 contributor and Zend Engine 2 co-creatorThe authoritative guide to PHP 5!Master PHP 5, the easy, high-performance solution for enterprise-class Web development!
Core PHP Programming, Third Edition is the authoritative guide to the brand-new PHP 5. Top PHP developer Leon Atkinson and PHP 5 contributor/Zend Engine 2 co-creator Zeev Suraski cover every facet of real-world PHP development, from basic syntax to state-of-the-art design patterns.
It’s all here: networking, data structures, regular expressions, math, configuration, graphics, MySQL/PostgreSQL support, XML, algorithms, debugging, and much more. Discover how to build enterprise-class applications that use PHP 5’s breakthrough object-oriented features…and leverage the extraordinary Zend Engine 2 performance improvements this book’s co-author helped to implement.Every Core Series book:
- DEMONSTRATES how to write commercial-quality code
- FEATURES nontrivial programs and examples—no toy code!
- FOCUSES on the features and functions most important to real developers
- PROVIDES objective, unbiased coverage of cutting-edge technologies—no hype!
- Accurate, thorough coverage of PHP 5 syntax, functions, and algorithms
- Step-by-step guidance for PHP 5 database integration and XML development
- Best practices for software design, debugging, and integration
Biographie de l'auteur
LEON ATKINSON is a freelance Web developer and architect who has been working with PHP since 1997. He formerly served as chief technologist for Clear Ink in Walnut Creek, CA, where he specialized in designing and implementing complex, PHP-based Web applications that automate business processes. He is author of Core MySQL.
ZEEV SURASKI is co-creator of PHP 5’s Zend Engine 2. He also wrote many of PHP’s core features, including its abstracted Web server API, thread safety, MySQL support, and output buffering. He co-founded Zend Technologies and currently serves as its chief technology officer.
Aucun appareil Kindle n'est requis. Téléchargez l'une des applis Kindle gratuites et commencez à lire les livres Kindle sur votre smartphone, tablette ou ordinateur.
Pour obtenir l'appli gratuite, saisissez votre adresse e-mail ou numéro de téléphone mobile.
Détails sur le produit
En savoir plus sur l'auteur
Commentaires en ligne
Commentaires client les plus utiles sur Amazon.com (beta)
I have been a programmer for over 6 years, but have never had the pleasure of doing anything with PHP before I started reading this book. I must say, I was totally impressed after I had finished reading Leon's book. The PHP language itself has grown tremendously over the past 8 years or so, and I can certainly see why it is so appealing to users of all levels. The author of the book, Core PHP Programming, does an amazing job explaining the nuance of PHP that any level READER can understand the topic and does whatever it is that he or she is after - which would be designing a dynamic web site in this case.
Leon starts the book with the paraphrase "...answer is that PHP is better" and goes on to explain why that is the case. His answers would compel any PHP user or potential users:
1) PHP is free
2) PHP runs on UNIX, Windows, and Mac OS X
3) PHP is modifiable
4) PHP was written for Web Page creation
5) Support for PHP is free and readily available
6) PHP is popular
7) Programming skills developed in other structured languages can be applied to PHP
By the end of page 11 (5 pages into chapter 1) the reader is hooked and wants to read on to find out what all Leon is talking about. All the key phrases are there: free, extendible, lots of supports, and ease of use.
By the end of Chapter 7 or page 160, you are ready to rock. By now, you know what PHP is all about and have learned its syntax, features, and have even looked (or hopefully written) some code.
Dynamic Function Calls ends chapter 4. This section CLEARLY shows to any programmer how powerful PHP really is and how easy it would be for anyone to utilize that power. Dynamic Function Call is very difficult to implement in Java (I don't know of any way to do in C++ actually - specially in one line of code). In one line of code PHP is able to accomplish this task. Very powerful stuff...
I was personally very impressed with the OO features of the language, which was depicted very well in chapter 6. I also need to say that Leon's introduction to Objects and Classes are very easy to understand for users new to the topic.
For the next few hundred pages, in Part II of the book - Functional Reference, various functions that PHP supports are shown and each one is explained in a great detail. Most of the functions have also been followed by an example that shows the usage each function just described. These chapters are very good reference even for the advanced users as PHP has grown so much that keeping track and memorizing of all the functions would be nearly impossible.
Leon ends the book with a section called Software Engineering. The two chapters that I liked in this section were the design and the design patterns chapters. Chapter 27, Design, is basic software engineering practices in a nutshell. Something that took me over two graduate level courses to cover, the author gives an overview in about 25 pages. I recommend this chapter to any novice programmer. The chapter on Design Patterns is simply put, great. 4 Design Patterns from the popular GoF book are described:
A reader can benefit the specific examples that are given in this chapter as they apply to Web site design and implementation. The examples given are reusable and would benefit any user of PHP.
Throughout the book the author does a very good job at showing the reader what the differences between PHP and other languages are. I think PHP would be a very good first language to learn b/c it has all the features of other popular scripting languages such as Perl and structural/OO languages such as Java and C/C++.
Core PHP is a book for serious programmers written by people who obviously know the subject inside out. The book is over a 1,000 pages long with densely packed pages. One of the authors Zeev Suraski is the co-creator of the upcoming PHP5 Zend Engine (the heart of the PHP system). The fact that it covers PHP 5 from people involved with that development give it an edge on many older books currently on shelves. The writing style is dry and factual (which is what I want from a technical book). If you have experience with other programming languages such as perl or C/C++ this book could be your rapid transition tool. I have a significant background in Java and a few years ago regarded PHP as just another scripting language that would allow trivial jobs to be done easily and give me sufficient rope to do damage when attempting bigger jobs. I was wrong, and the new features of PHP 5 may help it capture more of the hearts and minds of web developers. Unlike Java there is a shortage of good PHP books.
The tutorial section
The tutorial section covers the basics of obtaining and installing PHP both on Windows and UNIX style platforms. I would have preferred it if they had gone into more details on this subject as I seem to manage to mess up installation and configuration every time I do it under Linux. I always seem to fumble around, missing vital components and when I finally get it working I am not quite sure what it was that made it work. The brevity of the installation instructions are rather summed up by the comment "if you have ever compiled software you've found on the net you will have little trouble with this installation".
The book includes some basic tutorial material at the start but it quickly moves on to topics that would only be of interest to people who have real problems to solve. For example, before page fifty the book covers indirect references to variable names. I found this quite useful as it is something I have wondered about when using other programming languages The book covers the subject of recursion, which is a powerful technique but probably only appropriate for a fairly serious programmer.
Chapter 6 consists of about 40 pages covering PHP and Object Orientation. This is approximately 40 pages more than most PHP books. I have used th OO features of PHP4 but always felt they were a "bolt on afterthought". It looks like PHP5 has integrated OO more deeply into the core of the language. I appreciated the new features of PHP5 such as constructors and destructors, the access specifiers (public, private etc) and abstract classes. It is only a matter of time before PHP5 becomes the default version of the language, so it is a good idea to understand the ideas as soon as possible. It also means you can transfer concepts from other OO languages such as Java and C++. Because the authors are so intimately involved with PHP they were able not only to comment on the changes in syntax in PHP5 but also how it may improve performance in certain circumstances. To quote from chapter 6, "In addition to providing a more intuitive object model, the handle-based system has several additional advantages; improved performance, reduced memory consumption, and increased flexibility".
The function reference
The middle 670 pages of the book are a functional reference covering almost anything you can do with PHP, from interacting with databases to xml processing. Some of the API calls listed struck me as somewhat odd for such a section. For example the interface to the MnoGoSearch search system might be quite useful but is hardly part of every programmers essential PHP toolkit. The function reference also covers System V messages, semaphores and shared memory, hmmm might be a while before I need that information. On the more common front it covers Apache, IMAP, several XML systems and automatically creating and manipulating images and graphics. I couldn't see anything on manipulating flash movies but any geek knows that flash is the work of the devil and everything should be done on the server. The PHP community has created some excellent online documentation for the PHP function calls, but this book would make a good additional commentary for any programmer. Personally I can live with as much explanatory code examples as I can get my hands on.
PHP & Software Engineering
I know that some people do not like to see the words "software engineering" and PHP on the same page. The section on Software Engineering is interesting in that PHP is frequently regarded as a tool for Quick and Dirty style of programming. My comment on this is that Quick and Dirty programming is always dirty and never quick in the long run. This section covers the use of the language features of PHP 5 to implement classic design patterns such as the singleton and factory patterns. It seems like every programmer and his dog has written about design patterns and the Java language and it is a delight to see someone tackle this subject in PHP, particularly using the new features of the upcoming PHP 5 version.
There are some surprising omissions such as a very brief coverage of database independent API's such as adoDB and the pearDB classes. With the pearDB classes now part of the core PHP distribution this seems a surprising omission. For me database portability is important, I would like to be able to at least easily port my code between popular databases. I could find no mention of SQL Lite, one of the features due to be bundled with PHP5 when it ships.
A good comprehensive reference, not for beginners. A combination of this book, a "cookbook" style reference and the web documentation and you are set for programming anything with PHP.
What a disappointment. This is an incomplete and disorganized self-congratulatory reference.
Authors, probably paid by the page, integrate useless data separated by numberous blank pages.
Just 2 examples:
- 7 pages of the result of the command "configure --help", without comments. Completely useless.
- 4 pages to talk one page of "PHP tags"! (you know the < ?php >)
The description of the PHP functions is botched up and incomplete. Listings (samples) are numberous, but unfortunately they are rarely relevant for complex functions. Moreover the function title itself is only headed in "bold" while listings titles are bordered and shaded - it makes the whole hard to read/search.
Regarding the documentation of functions, when they're off the beaten track, usually the authors get their "joker"... << A full discusion of xxx is beyond the scope of this book >> (e.g. see the shared memory). Being a system hacker, the book often gave me the impression that the author(s) don't master what they talk about.
Self-congratulation: if you contributed to the open-source PHP, first, congratulations! PHP is a wonderful language, easy to use, easy to debug, performing well ; his numberous authors around the world deserve a big "Congratulation!". However when it comes to program PHP, one need a serious book talking in details about what we need in our daily work, as programmers. In this book you'll find tons of self-congratulory references, naming lots of people, but not actual material to help your work as a programmer. Well, if this is your intention to know more about the history of PHP, or if you belong to the list of people, go for it, you will get your [free] refill of EGO if you need that.
So let's talk about the key to the book, its index:
Thus, if you are looking for ...
M.Adler, J.Ahto, C.Alexander, T.Arntzen, S.Bakken, H.Bergius, A.Black, M.Boeren, S.Caraveo, J.Clark, E.Dijkstra, D.Eriksson, J.Gaill, A.Gutmans, C.Hagenbuch, S.Hughes, A.Isaacs, A.Karajannis, K.Koehntopp, F.Kromann, M.Matsumoto, T.May, P.Melo, T.Nishimura, L.Philips, E.Raymond, M.Rodeh, S.Ruby, R.Schwartz, D.Stenberg, Z.Suraski, G.Thomson, A.Slooten, E.Warnke, J.Zitting, A.Zmievski...
... you are lucky! They're all in the book
However if you have to *work* with PHP, don't look for instance for these important keywords, they're *not* in this book index: global, Super..., header(), strpos(), lock()...
Actually, it was so irritating not to find what I was looking for that php.net became my reference...
Hard to believe that honest people, besides the ones that contributed to PHP itself, can give more than 2 stars to this book. I believe authors have many friends :)
The authors of Core PHP Programming have found a marvelous middle ground. Toward the beginning of the book they have a great deal of light, explanatory material as they cover the basics of PHP. As they move towards more advanced topics there is less explanation and a tighter packing of information. At the same time the book has a large number of small code examples throughout, making sure that you know how to use the functions under discussion.
This is the third edition and I must admit that I had not come across it in either the first or second editions, so I have no great way of comparing them in this review. It has certainly been revised to take into account the changes for PHP 5 and examining the table of contents for the second edition on Safari I can see the that the basic structure has remained the same while the book has grown about 300 pages. The addition of Zeev Suraski as co-author can only be to the benefit of the quality of the information, particularly regarding PHP 5.
The book starts with the absolute rock bottom of PHP, the basic data types and operators through to efficiency, debugging and design patterns. Along the way it covers almost all aspects of PHP 5 with a readable reference style. The `Core' in the title of this book is a key to understanding it. If you're looking for a book with all the code required to handle session management, or user logins and security (to mention two possibilities) then this isn't the book for you. If, however, you are after a book that more than adequately explains the power and nuances of PHP and programming in the language then this is a marvelous volume.
It's broken up into 5 sections: "Programming PHP," which covers the basics of data, control flow and I/O; "Functional Reference," which is 600 odd pages broken up into 12 chapters that seems to cover every PHP function (a check of three sub chapters showed every function mentioned on the topic at PHP.net was also in the book) and does it well with good explanation and code examples; "Algorithms," which details a number of methods of performing routine tasks such as sorting, parsing and generating graphics; and "Software Engineering," devoted to design, efficiency and design patterns; and finally, there are a seven excellent appendices.
Taken as a whole it does a good job of covering the whole language and the ways of using it.
I can imagine it would make a good companion volume to my other favourite PHP volume, PHP and MySQL Web Development, which tends more towards recipes and leaves out the encyclopedic coverage of this book.
Leon Atkinson has a good web page for the book that includes a link to download all the code and examples, a link to the Prentice Hall page for those wanting an example chapter or a look at the Table of Contents and some other reviews. His site also has a page for the inevitable errata, currently blank. While I did find only one typo (not in example code) I can't claim to have read every page or run all the code examples.
I'd recommend this volume to anyone who wanted a comprehensive guide to PHP 5. It is probably useful at almost all levels.
Clearly, if you are a web programmer, knowing PHP is a big plus. A hardcore way of doing this is to use the online documentation scattered throughout the web, and learn by downloading and analysing code examples. PHP veterans, including maybe the authors, probably did this. Nothing better at the time. While it works for some, this approach is awkward to many, and is quite ad hoc. The danger is in learning quick kludges as opposed to methodically designing and coding, with a full appreciation of the language's extent. Luckily, as PHP has matured, you can turn to this book for a logical pedagogy.
The treatment is exhaustive and shows starkly how far PHP has come. For example, you can use all the major encryption algorithms (Rijndael, Serpent, DES...) as extensively and easily as though you were coding in C. On another tack, the image analysis routines now handle all the important image formats (GIF, JPEG, TIFF...). The book displays the breadth of such computing topics now available, and the wealth of library routines in each topic describes the depth of the treatment.
Are you familiar with Fortran and the IMSL mathematical package so often associated with it? Or with C++ and its standard template library? Or C and the Numerical Recipes routines? If so, this book lets you appreciate that intellectually, PHP now ranks with those luminaries.