Category
stdlib · php-src-strict
Problem
mb_send_mail() is not registered. Zend exposes it from ext/mbstring for sending RFC-compliant mail with multibyte headers/bodies (pairs with mail() #3285 and MIME helpers #6038). Web apps and CLI scripts that call mb_send_mail() fail today.
php-src reference
Repro (failure today)
./script/docker-exec.sh -- bash -lc 'source script/php-env.sh
php bin/vm.php -r "var_export(function_exists(\"mb_send_mail\")); echo \"\\n\";"
'
# bool(false)
Compare Zend (ext/mbstring loaded):
./script/docker-exec.sh -- bash -lc 'php -r "var_export(function_exists(\"mb_send_mail\")); echo \"\\n\";"'
# bool(true)
Scope
| Module |
Path |
| Extension |
ext/mbstring/mb_send_mail.php (new), wire in ext/mbstring/Module.php |
| VM |
Delegate to mail() once #3285 exists, or thin sendmail wrapper matching php-src header encoding |
| Encoding |
Reuse mb_internal_encoding() / MIME helpers from #4636 / #6038 |
| Tests |
test/compliance/cases/stdlib/mb_send_mail.phpt (mock/skip when sendmail unavailable) |
PHP-in-PHP first: PHP implementation in ext/mbstring/; avoid permanent C-only mail tables in runtime/*.c.
Done when
function_exists('mb_send_mail') true when mbstring module is loaded
- Argument count / type errors match Zend (
TypeError on non-string recipients/subject/body; enum-case operands rejected under php-src-strict)
- Optional
$additional_headers / $additional_params semantics match php-src for ASCII + UTF-8 subjects
- Compliance test green or
@group sendmail skipped with documented reason
Verification
./script/docker-exec.sh -- bash -lc 'source script/php-env.sh && php bin/vm.php -r "var_export(function_exists(\"mb_send_mail\"));"'
./script/ci-fast.sh --filter mb_send_mail
Category
stdlib· php-src-strictProblem
mb_send_mail()is not registered. Zend exposes it from ext/mbstring for sending RFC-compliant mail with multibyte headers/bodies (pairs withmail()#3285 and MIME helpers #6038). Web apps and CLI scripts that callmb_send_mail()fail today.php-src reference
ext/mbstring/mbstring.c—PHP_FUNCTION(mb_send_mail)ext/standard/mail.c— underlying sendmail/MTA path reused by mbstringRepro (failure today)
Compare Zend (ext/mbstring loaded):
Scope
ext/mbstring/mb_send_mail.php(new), wire inext/mbstring/Module.phpmail()once #3285 exists, or thin sendmail wrapper matching php-src header encodingmb_internal_encoding()/ MIME helpers from #4636 / #6038test/compliance/cases/stdlib/mb_send_mail.phpt(mock/skip when sendmail unavailable)PHP-in-PHP first: PHP implementation in
ext/mbstring/; avoid permanent C-only mail tables inruntime/*.c.Done when
function_exists('mb_send_mail')true when mbstring module is loadedTypeErroron non-string recipients/subject/body; enum-case operands rejected under php-src-strict)$additional_headers/$additional_paramssemantics match php-src for ASCII + UTF-8 subjects@group sendmailskipped with documented reasonVerification
./script/docker-exec.sh -- bash -lc 'source script/php-env.sh && php bin/vm.php -r "var_export(function_exists(\"mb_send_mail\"));"' ./script/ci-fast.sh --filter mb_send_mail