Lynxbee topic

PHP

Articles about PHP.

How to Disable the WordPress Admin Toolbar Safely

Hide the WordPress frontend Toolbar using the user profile setting or the supported `show_admin_bar` filter. Learn where site-wide policy code belongs, how to preserve editor access, why CSS/core edits fail, and how to verify and roll back.

Create Custom Meta Descriptions in Osclass

Osclass already provides a site description and a `meta_description_filter` extension point. Use a plugin to choose concise page-specific text, leave escaping to one known output boundary, and verify the rendered canonical pages instead of editing core files.

Show Subcategories on WordPress Category Archives

On a category archive, WordPress already knows which term is being viewed. Read that queried term, fetch its direct children with `get_terms()`, and render escaped term links—without hard-coding IDs into a fragile copied template.

Fix PHP count(): Value Must Be Countable

An empty array is valid input to count() and returns zero. This warning means the runtime value is null, scalar, or otherwise non-countable; find where the type contract broke, then fix or normalize it intentionally.

WordPress Login Link That Returns to the Current Page

Show a login prompt only when a WordPress visitor is signed out, then return them to the page they were reading. The secure implementation uses core URL helpers, escaped output, local destinations, page exclusions, and cache-aware verification.

Engineering weekly

Useful technical knowledge, not inbox noise.

Receive verified fixes, references, labs, and tools. Confirm by email; unsubscribe any time.