A HitchHackers guide through WordPress


Home | Pages | Archives


plugin_dir_path

February 12, 2011 2:01 am

Definition:
function plugin_dir_path( $file ) {}

Gets the filesystem directory path (with trailing slash) for the plugin __FILE__ passed in

Parameters

Return values

returns:the filesystem path of the directory that contains the plugin

Source code

function plugin_dir_path( $file ) {

	return trailingslashit( dirname( $file ) );

}

2517

Rate this:

Posted by Thorsten

Categories: /wp-includes/plugin.php, Documentation, Files, Functions, Functions by letter p

Tags: ,

Leave a Reply



Mobile Site | Full Site


Get a free blog at WordPress.com Theme: WordPress Mobile Edition by Alex King.