November 20, 2026 - 19:56

Web Development

PHP PDO MySQL SQLSTATE[HY000] [2002]: Socket or Connection?

When PDO reports SQLSTATE[HY000] [2002], changing the database password is not the first test to run. The PHP process may be unable to reach MySQL ove...

PHP PHP Headers Already Sent: Find the First Output

You call header() to redirect a request, but the browser stays on the old page—or PHP refuses to set a cookie. A headers already sent warning usually ...

PHP PHP 8.2, 8.3, 8.4 or 8.5: Which Version Should You Choose?

Your hosting panel offers PHP 8.2, 8.3, 8.4 and 8.5. Which one should you pick? The highest number is easy to spot. The useful choice is the one your ...

PHP PHP Allowed Memory Size Exhausted: Diagnose Before Raising the Limit

Allowed memory size exhausted means a PHP request exceeded its configured memory limit. It does not, by itself, prove that the server has run out of R...

PHP Secure PHP Logout and Revoke Sessions Across Devices

Logging out should make the current browser stop presenting an authenticated session. Clearing a page variable is not enough: the server-side session ...

PHP PHP Email Activation: Verify Addresses with Expiring Tokens

Email activation can confirm that a person can receive mail at an address, but it does not prove a legal identity. Treat the activation link as a temp...

PHP One-Time PHP Password Reset Links with Expiration

A password reset link is a temporary credential. Anyone who obtains it may be able to change the account password, so the token must be difficult to g...

PHP Build a Safer PHP “Remember Me” Login with Rotating Tokens

A “remember me” checkbox creates a credential that lasts longer than the current browser session. Treat it like a password reset token: someone who st...

PHP PHP Session Disappears After Login: Cookie and Storage Checks

A login can appear successful and still lose its session on the next request. PHP sessions depend on a cookie reaching the browser and the server bein...

HTML5 & CSS3 CSS Container Queries: Responsive Components by Their Own Size

A card can appear in a wide main column on one page and a narrow sidebar on another. A media query sees the viewport; a container query lets the compo...