• Resolved syncbox

    (@syncbox)


    Hello, anyone
    I understand the use of bloginfo() as related to getting the style sheet and of TEMPLATEPATH. when using an include… but how can I reference inline images, etc using this kind of method?
    I’ve always just used /wp-content/themes/nameoftheme/etc

    but surely there is a shorter method? especially since users might change the theme?

    help much appreciated!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter syncbox

    (@syncbox)

    anyone out there with a method? I’ve looked through some themes that seem to use an images directory… I’ve always used “sharedimages” as my default directory – does WP look in “images” by default? It sure doesn’t seem to find images in “sharedimages” unless I use /wp-content/themes/nameoftheme/sharedimages/myimage.gif

    I’m looking for a shortcut to the path above that references the active theme directory, allowing me to simply use the sharedimages/myimage.gif portion

    help? I know this seems basic, but I can find no reference to it in the documentation except showing relative pathing, which doesn’t seem to work.

    Thread Starter syncbox

    (@syncbox)

    nevermind… I did find it, thanks.

    <?php bloginfo('template_directory'); ?>/sharedimages/

    Yes, that – or the ‘stylesheet_directory’ works the same, as well.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘how to reference the theme directory’ is closed to new replies.