首页 WordPress函数大全 plugins_url()

plugins_url()

2020-05-02 / 6403阅 / 悠然

如何你看完本文还不知道如何使用该函数,可以联系我定制视频教程,50元/个函数,学不会全额退款

plugins_url( string $path = '', string $plugin = '' )

检索plugins或mu-plugins目录中的URL。

描述

如果未提供任何参数,则默认为插件目录URL。

参数

$path

(string)
(Optional)
Extra path appended to the end of the URL, including the relative directory if $plugin is supplied.

Default value: ''

$plugin

(string)
(Optional)
A full path to a file inside a plugin or mu-plugin. The URL will be relative to its directory. Typically this is done by passing __FILE__ as the argument.

Default value: ''

返回

(string) Plugins URL link with optional paths appended.

大家谈论
    我的见解