Introduce get_available_languages(). Validate WPLANG. fixes #11774
git-svn-id: http://svn.automattic.com/wordpress/trunk@12946 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -23,7 +23,7 @@ switch ( $_GET['action'] ) {
|
||||
if ( empty( $_POST ) )
|
||||
wp_die( __("You probably need to go back to the <a href='ms-options.php'>options page</a>") );
|
||||
|
||||
if ( isset($_POST['WPLANG']) )
|
||||
if ( isset($_POST['WPLANG']) && ( '' === $_POST['WPLANG'] || in_array($_POST['WPLANG'], get_available_languages()) ) )
|
||||
update_site_option( "WPLANG", $_POST['WPLANG'] );
|
||||
|
||||
if ( is_email( $_POST['admin_email'] ) )
|
||||
|
||||
Reference in New Issue
Block a user