Get template directory path in WordPress

Adding below code to your WordPress theme will automatically generate the file path to your template directory.

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

Common Usages

 
<?php
	get_stylesheet_directory(): // file path to current Theme directory
	get_stylesheet_directory_uri(): // url path to current Theme directory
	get_template_directory(): // file path to parent Theme directory
	get_template_directory_uri(): // url path to parent Theme directory
?>

Related posts:

HTML5 page structure

HTML5 offers more powerful structure comparing to older versions of Html. There are many new …


Partner with Us

We are providing an exclusive partnership offer to individuals and companies who are interested in setting up their own web design & development company. For more information about how to partner with us, please contact us