Updating use of deprecated split() to use preg_split().

This commit is contained in:
Mark Story 2009-12-16 21:08:15 -05:00
parent c8297ff283
commit bbc72c3703

View file

@ -393,7 +393,7 @@ class L10n extends Object {
* @access private * @access private
*/ */
function __autoLanguage() { function __autoLanguage() {
$_detectableLanguages = split('[,;]', env('HTTP_ACCEPT_LANGUAGE')); $_detectableLanguages = preg_split('/[,;]/', env('HTTP_ACCEPT_LANGUAGE'));
foreach ($_detectableLanguages as $key => $langKey) { foreach ($_detectableLanguages as $key => $langKey) {
$langKey = strtolower($langKey); $langKey = strtolower($langKey);
if (strpos($langKey, '_') !== false) { if (strpos($langKey, '_') !== false) {