Template:BilibiliVideo/doc
Name | Bilibili Video Widget |
Author | 加大号的猫 |
Revisor | Boxsnake |
Re-revisor | AnnAngela |
Re-revisor for html5 | |
Re-re-revisor for new html5 | |
Mobile support | XYZ指示物 |
Copyright Agreement | MIT |
Release Date | June 29, 2012, first version released. |
Release URL | https://zh.moegirl.org.cn/Widget:BilibiliVideo && https://zh.moegirl.org.cn/Template:BilibiliVideo |
Notes. | If you have any questions, please contact the author. |
Usage: | {{BilibiliVideo|id=BV177411m75s}}
|
Example: | Wide ModeShow Wide ModeShow |
Parameters
- Necessary parameter
- id the avid/bvid of the video (necessary parameter) (It is not recommended to omit the beginning av or bv)
- if the id is 【av + one to nine pure digits】 or 【one to nine pure digits】 then it is treated as avid.
- If the id is 【bv + ten digits or letters】 or 【ten digits or letters】 then it is treated as bvid.
- Error is reported if neither of the above is matched.
- Optional parameters
-
- video title
- title video title, optional, it will automatically get the video title by default
- video pages
- page' If the video has pagination, you can specify the number of pages by this parameter, optional, defaults to 1
- pagename' If the video has pagination, you can specify the number of pages by this parameter, optional, defaults to empty
- subtitle' If the video has pagination, you can specify the pagination title to be displayed by setting this parameter as true, optional, defaults to false
- Autoplay
- t Set the timing where the video starts to play in seconds (e.g. 01:40 is recorded as (1×60+40=)100, but it may not start at the exact set time due to the video file structure) (after setting this parameter the video will automatically play after the viewer clicks [show video], but please note that it may not automatically play the video under high version Chrome but only automatically play comments =。=)
- autoexpand as
true
, the video will be auto expanded if it’s without the parametert
- Sizes
- width' video width, optional, defaults to 665px
- height' video height, optional, defaults to 441px
- max-width' the maximum width of the video, optional, defaults to 665px
- max-height the maximum height of the video, optional, defaults to 441px
- The above four length values are only accepted in 【positive (positive integer or positive decimal), unit being null (considered as
px
) or one ofpx
,pc
,pt
,em
,ex
,ch
,rem
,vw
,vh
,vmin
,vmax
,cm
,mm
,Q
,in
,%
】
- video title
Others
- Please do not add too many to a same page as the video information is obtained directly from bilibili. Otherwise, if the user doesn’t login bilibili, the information will not be available for the latter templates due to speed limitation.
- To simplify, you can also use the {{bv}} template.