[theme-reviewers] Questions about submitting a theme (answering localization theme name slug question)

michael at mfields.org michael at mfields.org
Wed Dec 29 17:30:40 UTC 2010


> theme slug, erm basically the localization name for the theme
>
> when you do say for example _e('some text here', 'yourthemename;');  so
> that
> it can be used for translations with .po files and what not are needing to
> be unique slug name for your theme
>
> for example, my comicpress theme is
>
> <?php _e('Preview Next Comic', 'comicpress'); ?>
>
> that way the localization code knows that its the comicpress translation
> strings to use

Thanks, but is sounds like "theme-slug" is hinting at something bigger
here as the sentence I quoted mentions "and as a prefix for all custom
Theme functions and options". It seems like a "theme slug" should be used
here,

load_theme_textdomain( 'theme_slug' );

as well as here:

__( 'Hello WordPress'. 'theme_slug' );

and here

function theme_slug() {
   print 'Hello WordPress';
}

as well as here:

$hello = get_option( 'theme_slug_hello_wordpress' );

I just think that the guidelines could be a bit more specific. How should
a theme author decide which slug to use? Should the theme slug contain
dashes or underscores? It should probably only contain characters allowed
in the naming of functions if it is meant to be used as a prefix IMHO. On
another note, should the theme slug be required at the begining of actions
and filters defined by the theme?

-Mike



More information about the theme-reviewers mailing list