REQUIRED: This theme text domain does not match the theme's slug

REQUIRED: This theme text domain does not match the theme’s slug. The
text domain used: tmarketo. This theme’s correct slug and
text-domain is puck.

in my style.css →

Text Domain: tmarketo
Theme Name: puck

and also in the functions.php I have added in the theme setup function →

load_theme_textdomain('tmarketo',$lang_dir );

then why that error?

theme name and text-domain can’t be different?

Hi @crunchmanju,

According to official WordPress Internationalization requirements, your theme name and text domain should match:

The text domain is a unique identifier, which makes sure WordPress can distinguish between all loaded translations. If your plugin is a single file called my-plugin.php or it is contained in a folder called my-plugin the domain name should be my-plugin. The text domain name must use dashes and not underscores.

https://codex.wordpress.org/I18n_for_WordPress_Developers

Thanks,
Luca

1 Like