質問

I use the load_textdomain action hook to list all active localization text domains with corresponding path to translation files.

function mo_location( $domain, $mofile ) {  
    if ( !is_array($GLOBALS['moloc']) )
            $GLOBALS['moloc'] = array();

    $GLOBALS['moloc'][$domain] = $mofile;
}

add_action( 'load_textdomain', 'mo_location', 10, 2 );

For some reason the $domain variable is not filled with a "default" text domain values. Does anybody know why?

正しい解決策はありません

ライセンス: CC-BY-SA帰属
所属していません wordpress.stackexchange
scroll top