what i am trying to do is embed images in my php files without having to use a long url like: /wordpress/wp-content/themes/example_theme/images/example_img.jpg
is there a php line of code that says to use the template theme directory?
what i am trying to do is embed images in my php files without having to use a long url like: /wordpress/wp-content/themes/example_theme/images/example_img.jpg
is there a php line of code that says to use the template theme directory?
http://codex.wordpress.org/Function_Reference/get_bloginfo
get_bloginfo('template_directory');
ok thanks now how exactly would i use it? this is what i have what do i replace it with?
<a href=""><img id="slide-img-1" src="/clayton/wp-content/themes/freestonemx/images/slide_1.gif" class="slide" alt="" /></a>
can anyone give me some advice on how to use that line of code in place of what i have?
<a href=""><img id="slide-img-1" src="<?php echo get_bloginfo('template_directory');?>/images/slide_1.gif" class="slide" alt="" /></a>
thank you so much. i am trying to learn exactly how to use php so i can implement the wordpress codex they provide.
This topic has been closed to new replies.