惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

P
Proofpoint News Feed
博客园_首页
WordPress大学
WordPress大学
大猫的无限游戏
大猫的无限游戏
有赞技术团队
有赞技术团队
阮一峰的网络日志
阮一峰的网络日志
Hugging Face - Blog
Hugging Face - Blog
博客园 - 【当耐特】
酷 壳 – CoolShell
酷 壳 – CoolShell
Y
Y Combinator Blog
Vercel News
Vercel News
The GitHub Blog
The GitHub Blog
T
The Blog of Author Tim Ferriss
云风的 BLOG
云风的 BLOG
博客园 - 司徒正美
Engineering at Meta
Engineering at Meta
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
J
Java Code Geeks
Stack Overflow Blog
Stack Overflow Blog
N
Netflix TechBlog - Medium
Martin Fowler
Martin Fowler
宝玉的分享
宝玉的分享
G
Google Developers Blog
Last Week in AI
Last Week in AI

WordPress Plugin

Copy Audio URL in Wonder Audio Player YouTube Error 153 | WordPress Plugin Wonder Lightbox JavaScript Events | WordPress Plugin How to Create a WordPress Gallery from an XML File How to Remove URL Query Parameters in Wonder Lightbox How to Dynamically Create a WordPress Image and Video Gallery Using WordPress Media Library IDs How to Add an Image to the Lightbox Gallery Without Showing It in the Grid Gallery How to Make the PDF Page Fit the Entire Lightbox Width When Opening a PDF File Double Tap to Play or Pause the WordPress Audio Player on Touch Devices
How to Create an Audio Player Playlist from an XML File
2026-02-20 · via WordPress Plugin

Plugin:

Wonder Audio Player Version 12.2 or later

Tutorial:

This tutorial will guide you on how to create an audio player from an XML file using the Wonder Audio Player plugin.

Step 1 - Create an XML file

Using XML allows you to define an audio player playlist directly from URLs. For example, if your MP3 files are hosted on Amazon S3, you can use an XML file to define the MP3 URLs and add them to the audio player.

An XML file is simply a text file that can be edited using a text editor or an XML editor, such as Microsoft's free and open-source XML Notepad.

The format of the XML file for the Wonder Audio Player plugin is as follows:

<list>
  <track>
    <mp3>https://www.wonderplugin.com/media/prideandprejudice_01.mp3</mp3>
    <title>Pride and Prejudice Chapter 1</title>
  </track>
  <track>
    <mp3>https://www.wonderplugin.com/media/prideandprejudice_02.mp3</mp3>
    <title>Pride and Prejudice Chapter 2</title>
  </track>
  <track>
    <mp3>https://www.wonderplugin.com/media/prideandprejudice_03.mp3</mp3>
    <title>Pride and Prejudice Chapter 3</title>
  </track>
  <track>
    <mp3>https://www.wonderplugin.com/media/prideandprejudice_04.mp3</mp3>
    <title>Pride and Prejudice Chapter 4</title>
  </track>
  <track>
    <mp3>https://www.wonderplugin.com/media/prideandprejudice_05.mp3</mp3>
    <title>Pride and Prejudice Chapter 5</title>
  </track>
</list>

The above XML adds five tracks to the player. The available XML keys are as follows:

Key Description
mp3 The mp3 URL
title Title
image The image of the audio
artist Artist
album Album
info Extra information
duration Duration in seconds

Step 2 - Upload the XML file to your web server and add the XML file to the plugin

After you have created the XML file, upload it to your web server using FTP or another method, and get the URL address.

Please note that while the MP3 URLs can be hosted on different domains, the XML file must be uploaded to the same web server as your WordPress site. The domain in the XML file URL needs to be exactly the same as the WordPress site domain, including the same protocol and prefix. For example, http://www.wonderplugin.com, https://www.wonderplugin.com and https://wonderplugin.com are all different domains.

After you get the XML URL address, you can open it in your web browser to ensure the URL is working and the XML output is correct.

Once you have confirmed that the XML URL is correct, in the Wonder Audio Player plugin, edit an existing audio player or create a new one. Navigate to Step 3, the Options tab, then to the Advanced Options tab, and add the following code into the Data Options input box:

data-xml="https://www.wonderplugin.com/test/audio-playlist.xml"

Please make sure to replace the XML URL with your own. And as mentioned above, the XML file must be uploaded to your own WordPress website.

An online demo created with the XML file above is as follows: