Property | Type | Description | |
---|---|---|---|
$playerID | 此变量用以在一个变量中区分多个播放器实例 |
Method | Description | |
---|---|---|
activate ( ) : void | 激活插件方法,如果激活失败,直接抛出异常 | |
config ( Typecho_Widget_Helper_Form $form ) : void | 获取插件配置面板 | |
deactivate ( ) : void | 禁用插件方法,如果禁用失败,直接抛出异常 | |
footerjs ( ) : void | 尾部js,解析文章中给header的播放器变量添加的播放器参数并生成播放器的html | |
getUniqueId ( ) : number | 获取一个唯一的id以区分各个播放器实例 | |
parseCallback ( unknown $matches ) : string | 回调解析 | |
personalConfig ( Typecho_Widget_Helper_Form $form ) : void | 个人用户的配置面板 | |
playercss ( ) : void | 头部css挂载,并定义参数的变量 | |
playerfilter ( array $value ) : array | MD兼容性过滤 | |
playerparse ( string $content, $widget, $lastResult ) : string | 内容标签替换 |
Method | Description | |
---|---|---|
cache_get ( unknown $key ) : mixed | boolean | 缓存读取 | |
cache_set ( unknown $key, unknown $value ) : number | 缓存写入 | |
deletefile ( ) : void | 缓存清空 | |
fetch_url ( unknown $url ) : boolean | mixed | url抓取,两种方式,优先用curl,当主机不支持curl时候采用file_get_contents | |
get_netease_lyric ( $id ) | 根据id从netease中获取歌词,带缓存 | |
get_netease_music ( unknown $id, unknown $type = 'song' ) | 从netease中获取歌曲信息 | |
get_shortcode_regex ( array $tagnames = null ) : string | Retrieve the shortcode regular expression for searching. | |
getcover ( string $words ) : boolean | string | 通过关键词从豆瓣获取专辑封面链接,当缓存存在时则直接读取缓存 | |
getlrc ( string $url ) : boolean | string | 通过url获取歌词内容,若缓存存在就直接读取缓存 | |
is_really_writable ( $file ) : boolean | Tests for file writability | |
parse ( string $content = '', array $atts = [] ) : array | 根据参数进一步解析得到歌曲的信息 | |
parse_netease ( unknown $id, unknown $type ) : boolean | multitype:multitype:unknown | 解析netease信息 | |
shortcode_parse_atts ( string $text ) : array | string | Retrieve all attributes from the shortcodes tag. |
public static deactivate ( ) : void | ||
return | void |
public static getUniqueId ( ) : number | ||
return | number |
public static parseCallback ( unknown $matches ) : string | ||
$matches | unknown | |
return | string |
public static personalConfig ( Typecho_Widget_Helper_Form $form ) : void | ||
$form | Typecho_Widget_Helper_Form | |
return | void |
public static playerfilter ( array $value ) : array | ||
$value | array | |
return | array |
public static playerparse ( string $content, $widget, $lastResult ) : string | ||
$content | string | |
return | string |