Typing an old PHP project with PHPStan
PHPStan can check a PHP project that has almost no types. The baseline lets you start today and fix the old errors one file at a time.
6 minute read
Category
PHP code that you can run: dates in the Shamsi calendar, one time passwords and static analysis, with checks against standards and tools.
PHPStan can check a PHP project that has almost no types. The baseline lets you start today and fix the old errors one file at a time.
6 minute read
A passkey sign in is two steps on the server. This post builds both in PHP and in C#, protects the add step, and tests the refusals that matter most.
15 minute read
Authenticator apps use a small standard, TOTP. A few lines of PHP can make and check the codes, and the RFC test values show that they are right.
6 minute read
PHP's DateTime knows only the Gregorian calendar. This post shows what the intl extension can do for Shamsi dates, a small converter that agrees with it on 73,414 days, and a free package that does the work.
8 minute read