Posts marked with “php”

finally{}: Semver, PHP and WordPress

by · July 2, 2019

0
 

Recently there was a big announcement that with WordPress 5.2, that they would be updating the minimum required version of PHP to 5.6. That’s a huge deal, but as can be expected, a vocal minority of the PHP community immediately erupted in anger

 

Internal Apparatus: A Walk Through the Generated Code

by ·

0
 

The PHP compiler/interpreter reads through our PHP code and produces an intermediate form. PHP’s virtual machine then interprets this intermediate form. PHP’s “generated code” feature allows us to walk through this intermediate form, better understanding exactly what PHP does with the software we write. We’ll begin with a three line example, observing the generated-code changes […]

 

Serverless PHP, Array Functions, and Data Structures with Chris Tankersley

by · June 17, 2019

0
 

Eric, John, and Oscar are back post-php[tek] to discuss the June 2019 issue.

 

Internal Apparatus: Memoization

by · June 5, 2019

0
 

Memoization is another form of memory use. I see it regularly used for improving application performance, but it’s also used to improve compiler performance. To learn the concept, we’ll use a PHP project with database tables, then look at other ways to use the technique.

 

Education Station: Data Structures, Part Two

by ·

0
 

Last month I talked about how, despite PHP arrays being one of the nicest things about the language, there were times where real data structures could help. There were various ways to use arrays as more “traditional” data structures, as well as the options provided by the Standard PHP Library, or SPL. If you can […]

 

finally{}: The State of PHP

by · May 2, 2019

0
 

I’ve spent a while now working on my seven deadly sins series of articles, and so it’s been a while since we’ve stepped back to look at PHP itself. Where are we as a language, and as a community?

 

Internal Apparatus: Memory Abstractions

by ·

0
 

We normally don’t care about abstractions in software, because they exist to hide details we shouldn’t need to care about. However, sometimes, we do need to know the detail. An essential part of how PHP works involves memory management. This month we’ll see new ways to think of memory itself; we’ll also introduce a learning tool we’ll be using in upcoming articles. We’ll be simulating an ancient mainframe computer, and its hard-wired operator console, using modern text messages.

 

Education Station: Data Structures, Part One

by ·

0
 

I’ll admit, one of the best things I love about PHP is that I don’t have to deal with all sorts of different ways to deal with data. At the base of the language we have nice primitives like strings, integers, floats, and Booleans, and we also have one of the most flexible structures known to programmers—the PHP Array. The array itself wears many hats. If you are coming from other languages, you have to think about the structure of ordered data in a few different ways. The reason for this tends to deal mostly with how we need to represent data and how we manipulate data. Different data has different requirements.

 

The New Frontend Fundamentals

by · April 3, 2019

0
 

Eventually, we expose the services offered by the PHP-powered APIs we build to users. Unlike a decade ago when we could count potential client applications on one hand, today the potential client can be anything. But for most people-facing applications, it still means HTML output with images and CSS. In this issue, we have articles to help keep your CSS know-how up to date, your twig components re-usable, and your dynamic front-end code quick.

 

Internal Apparatus: Patterns in the Code

by ·

0
 

The PHP compiler source code includes many patterns that can be frustrating and intimidating, because they are so different from typical PHP code, until we understand the structure and context. C’s preprocessor has a significant role in these unfamiliar patterns. We look at several of these patterns in the compiler’s PHP Array implementation.