Linux 软件免费装

Ant Media Secure Video

开发者 balajant
更新时间 2025年12月18日 21:54
PHP版本: 7.0 及以上
WordPress版本: 6.9
版权: GPLv3 or later
版权网址: 版权信息

标签

video streaming hls vod ant media server

下载

1.0.0

详情介绍:

A WordPress plugin for embedding JWT token secured video content from Ant Media Server. Uses raw video tag for mp4 videos and HLS.js for .m3u8 manifests. The JWT tokens are generated in the browser. Features

安装:

  1. Upload the plugin folder to the /wp-content/plugins/ directory.
  2. Activate the plugin through the 'Plugins' menu in WordPress.
  3. Configure the plugin settings at Settings > Ant Media Secure Video.
  4. Enter your Ant Media Server URL, Port, App Name, and Shared Secret.

常见问题:

How do I use the shortcode?

Use the [amsv_video] shortcode in any post or page. The only required parameter is streamId. Basic example: [amsv_video streamId="lesson1"] Advanced example: [amsv_video streamId="lesson1" poster="https://example.com/poster.jpg" autoplay="0" controls="1" preload="metadata" ttl="1800" width="640" height="360"]

What parameters are available?

  • streamId (required): The stream ID from Ant Media Server. Can include .mp4 or .m3u8 extension
  • poster (optional): URL to poster image
  • autoplay (optional): Set to "1" to autoplay (default: "0")
  • controls (optional): Set to "1" to show controls (default: "1")
  • preload (optional): Preload behavior - "none", "metadata", "auto" (default: "metadata")
  • ttl (optional): Custom token TTL in seconds (overrides global setting)
  • width (optional): Video width - numeric value in pixels, or with unit like "100%", "50em", "640px" (default: "100%")
  • height (optional): Video height - numeric value in pixels, or with unit like "50%", "30em", "360px" (default: auto)

How does the authentication work?

The plugin generates a JWT token using your configured Secret Key. This token is appended to the HLS stream URL and all subsequent segment requests, ensuring that only authorized viewers can access the content.

更新日志:

1.0.0