Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

wordpress require file from plugins folder

// If no arguments are passed, this will defaults to the plugins directory.
plugins_url();

// You can pass 2 variables
plugins_url( $path, $plugin );

// $path: extra path appended to the end of the URL, 
// 		including the relative directory if $plugin is supplied.

// $plugin: a full path to a file inside a plugin or my-plugin.
// 		The URL will be relative to its directory. Typically this is done by
// 		passing __FILE__ as the argument.
Source by developer.wordpress.org #
 
PREVIOUS NEXT
Tagged: #wordpress #require #file #plugins #folder
ADD COMMENT
Topic
Name
4+4 =