hey, i'm looking for a way to the »url slug« for the current blog to use in my template.
like: example.tld/NAME
and i just want »NAME«. <?php bloginfo('name'); ?> won't work because it may contain umlauts etc, i just need the slug.
thanks! :)
hey, i'm looking for a way to the »url slug« for the current blog to use in my template.
like: example.tld/NAME
and i just want »NAME«. <?php bloginfo('name'); ?> won't work because it may contain umlauts etc, i just need the slug.
thanks! :)
You should be able to do:
get_option('siteurl');
You'll then have to strip out the part you don't want.
Alternatively, you could get the current blog ID and do a look up for the path column in the wp_blogs table. That'll give you /NAME/