Skip to:
Content
Pages
Categories
Search
Top
Bottom

bloginfo(\'template_url\') how to get the child theme?

  • Avatar of Svenl77
    Svenl77
    Participant

    @svenl77

    I try to build a child theme based on the parent.

    If I use bloginfo() http://codex.wordpress.org/Template_Tags/bloginfo it give back the location from the parent theme.

    I would like to get back the child theme I’m using.

    My be a stupid question. But I do not know how to do it.

    Most of all I need a way to get the child theme info from:

    bloginfo(‘template_url’)

    bloginfo(‘stylesheet_url’)

Viewing 2 replies - 1 through 2 (of 2 total)
  • Avatar of Andy Peatling
    Andy Peatling
    Keymaster

    @apeatling

    Just use the stylesheet_url if it’s a child theme. Or get_stylesheet_directory_uri()

    Avatar of Svenl77
    Svenl77
    Participant

    @svenl77

    Thanks a lot Andy,

    get_stylesheet_directory_uri() points me to the child theme directory. This is exactly what I was looking for.

Viewing 2 replies - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.