PHP Guides

Short, example-driven notes for common PHP tasks and debugging patterns.

PHP Date Guides

PHP Date Format Examples

Common PHP date format tokens with examples for dates, times, and timestamps.

PHP JSON Guides

PHP json_decode Examples

Practical json_decode examples for associative arrays, error handling, and common JSON mistakes.

PHP Security Guides

PHP password_hash Examples

Use password_hash and password_verify correctly for PHP login password storage.

PHP Regex Guides

PHP preg_match Examples

Simple preg_match and preg_match_all examples for extracting values with PHP regular expressions.

PHP Debugging Guides

PHP print_r vs var_dump

Compare print_r and var_dump for PHP debugging output and learn when each one is useful.

PHP Serialization Guides

PHP Serialized String Examples

Examples of PHP serialized strings for arrays, strings, booleans, nulls, and nested values.

PHP Date Guides

PHP strtotime Examples

Common PHP strtotime examples for relative dates, fixed dates, and date formatting.

PHP Date Guides

Convert PHP Timestamp to Date

How to convert Unix timestamps to formatted dates in PHP and avoid seconds versus milliseconds bugs.

PHP Serialization Guides

PHP unserialize Explained

What PHP unserialize does, where serialized data appears, and how to avoid unsafe usage.