[wp-trac] Re: [WordPress Trac] #6341: feature request: plugin_baseurl() function

WordPress Trac wp-trac at lists.automattic.com
Sun Jan 18 23:17:51 GMT 2009


#6341: feature request: plugin_baseurl() function
-------------------------------+--------------------------------------------
 Reporter:  Denis-de-Bernardy  |        Owner:  jacobsantos
     Type:  enhancement        |       Status:  closed     
 Priority:  low                |    Milestone:  2.8        
Component:  Optimization       |      Version:  2.7        
 Severity:  minor              |   Resolution:  invalid    
 Keywords:                     |  
-------------------------------+--------------------------------------------
Comment (by DD32):

 I'm still +1 for extending plugins_url() to take a 2nd param of
 {{{__FILE__}}} so that the URL returned from the function is relative to
 the folder, ie:

 {{{
 $url = plugins_url('script.js', __FILE__);
 echo $url; //http://...../wp-content/plugins/my-folder/script.js
 $url = plugins_url();
 echo $url; //http://..../wp-content/plugins/
 }}}

 It'll be a shame to add yet another function..

-- 
Ticket URL: <http://trac.wordpress.org/ticket/6341#comment:15>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list