| 28 | | $get_lang = file_exists( ABSPATH . '/wp-config.php') ? file( ABSPATH . '/wp-config.php' ) : file( dirname(ABSPATH) . '/wp-config.php' ); |
|---|
| 29 | | |
|---|
| 30 | | if ( is_array($get_lang) ) { |
|---|
| 31 | | foreach ( $get_lang as $val ) { |
|---|
| 32 | | if ( strpos( $val, "'WPLANG'" ) !== false ) { |
|---|
| 33 | | eval( $val ); |
|---|
| 34 | | break; |
|---|
| 35 | | } |
|---|
| 36 | | } |
|---|
| 37 | | } |
|---|
| 38 | | |
|---|
| 39 | | if ( defined('WPLANG') && '' != WPLANG ) { |
|---|
| 40 | | if ( file_exists(ABSPATH . '/wp-content/languages') && @is_dir(ABSPATH . '/wp-content/languages') ) |
|---|
| 41 | | $langdir = '/wp-content/languages/'; |
|---|
| 42 | | else |
|---|
| 43 | | $langdir = '/wp-includes/languages/'; |
|---|
| 44 | | |
|---|
| 45 | | $locale_file = ABSPATH . $langdir . WPLANG . '.php'; |
|---|
| 46 | | if ( is_readable($locale_file) ) |
|---|
| 47 | | include_once($locale_file); |
|---|
| 48 | | } |
|---|
| 49 | | |
|---|
| 50 | | $rtl = ( isset($text_direction) && 'rtl' == $text_direction ) ? true : false; |
|---|
| 51 | | |
|---|