A hands-on walkthrough of writing a Yar RPC TCP server in pure PHP: parsing the 82-byte Yar protocol header with pack/unpack, handling the 0x80DFEC60 magic number, and dispatching a whitelist query — the same RPC protocol the Yar extension speaks.
with 0 CommentHow PHP objects changed from PHP5 to PHP7: the object's own refcount and handle indirection are gone, zend_object now carries a variable-length properties_table allocated with the object, custom objects must place zend_object last, and COW no longer applies to IS_OBJECT.
with 0 CommentPHP 7.4 ships FFI (Foreign Function Interface), letting you call C libraries from pure PHP. A worked example using libcurl — from a basic fetch to a WRITEFUNCTION callback and preload-safe usage — shows how FFI removes the need to write a C extension wrapper.
with 0 Comment