PHP from Scratch (3rd Edition) cover

PHP from Scratch (3rd Edition)

No rating yet
Chapters
32
Series
From Scratch
ISBN
9787111467953

Tags

Summary

PHP from Scratch (3rd Edition) is an introductory tutorial for PHP beginners in China Machine Press's "Programming from Scratch" series. It runs to 434 pages and comes with about 11.5 hours of multimedia teaching videos. The book is organized in five parts, moving from the simple to the advanced. Part One, "PHP Technical Basics," starts with what PHP is and the LAMP stack, introduces the HTML, CSS, and JavaScript fundamentals needed for web programming, and covers setting up Apache, MySQL, and PHP environments under Windows and Linux/UNIX. Part Two, "PHP Data Processing," concentrates on built-in features such as functions, arrays, strings, date and time, directories and files, URLs and HTTP, system information, and mathematical operations, with a simple text-based BLOG system as a stage-by-stage practice project. Part Three, "PHP and MySQL Databases," introduces MySQL and SQL basics and connecting to and operating databases with PHP. Part Four, "Advanced PHP," covers object-oriented programming, error handling, XML, AJAX, image processing, the MVC development pattern, and regular expressions. Part Five provides application examples such as sending email and common interview questions, and the book ends with appendices on configuring Eclipse, a regular expression reference, and general rules for writing PHP code. The book emphasizes pairing every concept with an example and analyzing the principle and use, aiming both to let readers with no background proceed step by step and to serve as a desk reference for those with some experience. Note that the book was written in the PHP 5 era, and its example environment and some coding practices differ from today's PHP 8.x; readers should study it alongside the current official documentation.

Editor's review

很多PHP入门书的问题在于“讲了语法,却不知道能干什么”。《零基础学PHP(第3版)》比较难得地按照“环境—语法—数据处理—数据库—进阶—实战”的逻辑铺开,读者在学完函数和数组后,会马上遇到一个基于文本的简易BLOG系统,把零散的知识点串成能跑起来的小项目;到第三篇再接入MySQL,学习路线和真实开发顺序基本一致。 本书的覆盖面也超出一般入门书:面向对象、错误处理、XML、AJAX、图像处理、MVC、正则表达式都有专章,最后的常见面试题和邮件发送实例,对准备求职或接小项目的读者有实际价值。随书附带的约11.5小时多媒体教学视频和源代码,对自学尤其友好,卡住时可以直接看演示。 需要提醒的是,本书出版于2014年,示例基于PHP 5与当时的Apache、MySQL配置,部分函数写法(如旧的MySQL扩展)在今天已经过时或被废弃。把它当作理解PHP基本概念和Web开发流程的入门读物,同时对照PHP 8官方手册与实际环境动手改写代码,收获会更大。

Who it's for

A good fit for

  • 完全没有编程基础、想系统入门Web开发的自学者
  • 了解HTML/CSS、希望补上服务器端编程能力的前端学习者
  • 需要一本结构完整、可当参考书翻阅的PHP初学者
  • 准备PHP相关岗位笔试面试、想复习基础知识点的人

Not a good fit for

  • 希望直接学习Laravel、ThinkPHP等现代框架的进阶开发者
  • 只想要PHP 8最新语法与特性、不愿读旧版本示例的读者
  • 需要深入讲解高并发、性能优化与架构设计的工程师

Reading tips

  1. 先按顺序读完第一篇并亲手把开发环境搭起来,环境跑通再往下学,比只看书效率高得多。
  2. 每章的示例代码务必自己敲一遍并改动参数观察结果,第二篇的简易BLOG系统建议独立完成一次。
  3. 阅读时对照PHP官方手册核对语法,遇到书中已废弃的函数(如旧MySQL扩展),改写成PDO或mysqli版本。
  4. 学完数据库篇后,自己设计一个小需求(如留言板、记账本)从建表做到页面展示,把知识真正用起来。

About the publisher

China Machine Press China · Founded in 1950

In addition to science and technology and professional publishing, the books in our catalog from China Machine Press also reflect a sustained focus on psychology, computing, management, finance and economics, and social sciences. In psychology, the catalog includes works by C. G. Jung and introductions to analytical psychology, as well as applied topics such as stress and health, and addiction and healing. In computing, it features Structure and Interpretation of Computer Programs (JavaScript Edition). Management and finance titles include Administrative Behavior (4th Edition), The Price of Inequality (Collector's Edition), and This Time Is Different: Eight Centuries of Financial Folly (Commemorative Edition). In the philosophy and history of science, there is The Worldview: The Third Edition. Relevant authors include C. G. Jung, William McGuire, Sonu Shamdasani, and Gabor Maté. Public information is limited; the above summarizes the publisher's profile based solely on the books in our catalog.

Contents

  1. Preface
  2. Part One: PHP Technical Basics
  3. Chapter 1: Getting Started with PHP
  4. Chapter 2: The PHP Language
  5. Chapter 3: Web Programming with PHP
  6. Part Two: PHP Data Processing
  7. Chapter 4: Functions in PHP
  8. Chapter 5: Array Handling in PHP
  9. Chapter 6: String Handling in PHP
  10. Chapter 7: Handling Dates and Times with PHP
  11. Chapter 8: Working with Directories and Files in PHP
  12. Chapter 9: Handling URLs and HTTP in PHP
  13. Chapter 10: Getting System Information with PHP
  14. Chapter 11: Mathematical Operations in PHP
  15. Chapter 12: Practice Project One: A Simple Text-Based BLOG System
  16. Part Three: PHP and MySQL Databases
  17. Chapter 13: MySQL Databases and SQL Basics
  18. Chapter 14: Using PHP to Operate MySQL Databases
  19. Part Four: Moving Up — Advanced PHP
  20. Chapter 15: Object-Oriented PHP Programming
  21. Chapter 16: Error Handling in PHP Programs
  22. Chapter 17: PHP and XML
  23. Chapter 18: PHP and AJAX
  24. Chapter 19: PHP and Image Processing
  25. Chapter 20: PHP and the MVC Development Pattern
  26. Chapter 21: Regular Expressions in PHP
  27. Part Five: PHP Application Examples and Common Interview Questions
  28. Chapter 22: Practice Project Two: Sending Email with PHP
  29. Chapter 23: Common Interview Questions
  30. Appendix A: Configuring Eclipse as a PHP Development Tool
  31. Appendix B: Regular Expression Reference
  32. Appendix C: General Rules for Writing PHP Code

FAQ

这本书适合完全没有编程基础的人吗?
适合。本书从PHP是什么、LAMP是什么讲起,并补充了HTML、CSS、JavaScript的基础知识,环境搭建也有Windows和Linux两套步骤,零基础读者可以跟着走;但建议至少先了解网页的基本结构,学起来会更顺。
书中的代码现在还能直接运行吗?
大部分基础语法仍然通用,但本书基于PHP 5,诸如mysql_*系列函数、旧版Apache配置等内容在新版本中已废弃或改变。建议使用PHP 8搭配PDO或mysqli改写数据库部分,其余示例按官方手册微调即可。
这本书和《零基础学PHP 全彩版》是同一本吗?
不是。本书是陈浩编著、机械工业出版社2014年出版的「零基础学PHP(第3版)」,ISBN为9787111467953,全书434页;全彩版由明日科技编著、吉林大学出版社2017年出版,ISBN为9787569208689,两书作者、内容编排与配套资源均不同。
学完这本书能达到什么水平?
大致可以独立完成带数据库的小型动态网站,理解函数、数组、会话、文件操作、面向对象和MVC的基本概念。至于主流框架、安全防护与工程化实践,还需另外学习并多做项目。

Comments

Find this book

This site is an index: you start “Search all sources” in your browser, and the entries it lists all point to third-party sites; please judge their availability yourself.

About the author

陈浩 Author

Public information about Chen Hao is limited: his nationality, dates of birth and death, and educational background are not clearly documented. Nevertheless, the 36 works held in the collection show that his writing and editing span a wide range of fields. In literature, he has been involved with a world classic such as Wuthering Heights; in history, with Studies in the History of the Eurasian Steppe; in finance and the workplace, with An Introduction to Digital Finance, The Management Journal of a Fortune 500 Human Resources Director, and books on sales techniques; and he has also touched on practical areas such as a medical English vocabulary textbook and Java programmer interview preparation. Aimed at general readers and learners, the works emphasize knowledge popularization and skills training, and are varied in genre yet practical, suitable for readers with different needs to consult by category.

More by the same author

Top rated in the same category