Skip to Content
The Art of Modern PHP 8
book

The Art of Modern PHP 8

by Joseph Edmonds
October 2021
Intermediate to advanced content levelIntermediate to advanced
420 pages
7h
English
Packt Publishing
Content preview from The Art of Modern PHP 8

Chapter 4: Scalar, Arrays, and Special Types

Welcome to Section 2. In this part of the book, we are going to look at something that has become much more of a first-class feature in modern PHP: types.

The release of PHP 7 marked a significant turning point in the history of PHP. It ended a long period of stagnation that included the abandonment of a whole version – PHP 6. With PHP 7, we got some significant and highly useful changes to the language, and one of those was the introduction of scalar type declarations:

PHP: New features - Manual

https://www.php.net/manual/en/migration70.new-features.php

PHP 7 brought the advent of scalar type hints and strict type checking. This allowed us to write code with a clearer API and built-in assurances ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Modern PHP

Modern PHP

Josh Lockhart
The PHP Workshop

The PHP Workshop

Alexandru Busuioc, David Carr, Markus Gray, Vijay Joshi, Mark McCollum, Bart McLeod, M A Hossain Tonu
PHP 8 Basics: For Programming and Web Development

PHP 8 Basics: For Programming and Web Development

Gunnard Engebreth, Satej Kumar Sahu

Publisher Resources

ISBN: 9781800566156Supplemental Content