[doc-base] standalone-mode: Don't define LANG in standalone mode

From: Date: Tue, 04 Aug 2026 18:04:22 +0000
Subject: [doc-base] standalone-mode: Don't define LANG in standalone mode
Groups: php.doc.cvs 
Request: Send a blank email to doc-cvs+get-23537@lists.php.net to get a copy of this message
Author: Jordi Kroon (jordikroon) Date: 2026-08-04T20:04:17+02:00 Commit: https://github.com/php/doc-base/commit/79ce0ed8511eee6cdc9a8e039945c5a2464ec893 Raw diff: https://github.com/php/doc-base/commit/79ce0ed8511eee6cdc9a8e039945c5a2464ec893.diff Don't define LANG in standalone mode Changed paths: M configure.php Diff: diff --git a/configure.php b/configure.php index ba848eac7a..407450a679 100755 --- a/configure.php +++ b/configure.php @@ -652,7 +652,13 @@ function dtd_pe_body( string $filename = '' ) $chmpath = dtd_pe_body(); $conf = []; - $conf[] = "<!ENTITY LANG '$lang'>"; + + // Standalone trees are not named after a language, so they must + // declare xml:lang themselves. Not defining &LANG; makes any + // accidental use of it fail. + if ( $ac['STANDALONE'] != 'yes' ) + $conf[] = "<!ENTITY LANG '$lang'>"; + $conf[] = "<!ENTITY manual.chmonly $chmpath>"; $conf[] = "<!ENTITY % base-entities $baseEnt1>";

« previous php.doc.cvs (#23537) next »