Skip to content
PHP News
Search
Implemented PHP 8.7

ini_get_all(): Case-Insensitive Extension Names

On the PHP wiki as Case-insensitive extension names in ini_get_all()

Makes ini_get_all() accept extension names in any letter case, as extension_loaded() and phpversion() already do.

Implement case-insensitive extension names in ini_get_all()?

Primary vote · 2/3 majority

20 Yes 0 No 3 abstain 100% approval

This poll has closed.

Weilin Du opened the internals discussion on October 16, 2026, after an earlier thread about the idea. Weilin Du opened the vote on November 2, 2026, after posting an intent to vote on October 30. Voting closed on November 16, 2026 at 00:00 UTC, and the RFC passed 20 to 0, with 3 abstentions. It needed a two-thirds majority. The implementation landed in php-src's master branch the same day, so the change ships in PHP 8.7.

Summary

ini_get_all() returns the ini settings for one extension, but only if you spell the extension's name in lowercase. Other functions that take an extension name, like extension_loaded(), get_extension_funcs() and phpversion(), don't care about case. Weilin Du's RFC makes ini_get_all() work the same way, so one spelling works with all four.

Show me

extension_loaded('Pcre'); // true
phpversion('Pcre');       // the extension's version
ini_get_all('Pcre');      // today: E_WARNING, then false

// PHP 8.7:
var_dump(ini_get_all('pcre') === ini_get_all('Pcre')); // bool(true)

The match ignores only ASCII letter case, and it doesn't depend on the current locale. It works the same whether you ask for full details or only the values, through the $details argument.

What it means for existing code

Calls that work today keep working. The only change is for a name that differs from a loaded extension's name only in case. That used to raise a warning and return false, and now it returns the settings. Code that relied on the failure will see different behavior.

Watch the discussion

Video episodes that cover this RFC, each linked to the moment it comes up.

  • Covers this RFC

    PHP 8.6, Security Release & The Wrong Crash

    This Week In PHP Internals · Nov 19, 2026 · Watch from 11:19 ↗

  • Covers this RFC

    Request Hooks, Bcrypt Wrap & Scope RFC

    This Week In PHP Internals · Nov 5, 2026 · Watch from 8:00 ↗

  • Covers this RFC

    Security Release, How It Breaks & The Fix

    This Week In PHP Internals · Oct 22, 2026 · Watch from 19:45 ↗