Workshop in English - US at Longhorn PHP 2026
Track Name:
Elm
Short URL: https://joind.in/talk/b6e44
(QR-Code (opens in new window))
While PHP core comes with some nice functionality, the real power in PHP is found in extensions. Some of the functionality we take for granted come from extensions that are always enabled (e.g. the "standard" extension provides output buffering, array functions like sort() and in_array(), string utilities like trim() and explode(), and more). While plenty of extensions are bundled with PHP, and either always enabled (like reflection and json) or can be enabled with build flags (like mbstring and zip), extension can also be written separately. Third-party extensions include APCu, ImageMagick, Yaml and more. In this tutorial, we will cover how to create your own PHP extension. Initial topics include zvals, zend strings, hash tables, parameter parsing, and engine hooks. Hands-on examples will cover global functions, class registration, opaque types managed outside of the property system, and the use of external libraries. Extensions have been written in C, C++, Rust, and probably other languages too. This tutorial will be conducted in C, since that is the language that PHP is written in; the topics and examples provide a foundation for building extensions written in other languages as well.
Comments
Comments are closed.