Have You Ever Tried Some Music in WordPress Posts?

music

Audio is a powerful means of communication, and music is very evocative and pleasant. Given what blogs are for, there’s absolutely no need for background music and other sound effects on most blogs. If you’re expert with sound or really love it, sure, make it part of your blog. But don’t think you need to add background music to your blog if it’s not your thing.   Why or Why Not? Music can make your blog much more diverse and creative to large extent. However, when people hear music when they don’t expect to, it can also be annoying. That’s why some people think putting some audio on auto-play is the most ridiculous thing in web design. Here are several reasons why you should not include audio in your website or posts: 1. You don’t like music. (I believe most people like it.) 2. Your posts have nothing to do about music. 3. The style of your website is serious and formal. 4. Many people listen to music while they browse the web. When they come across a website with music on auto-play, it becomes a scramble to figure out how to mute the music on the website because it is now overlapping the music they are already listening to. Comparatively, here are also some situations that adding music to your posts sounds great: 1. Your website is about fashion, travel, magazine, restaurant, or anything that is relaxing and casual. 2. Audio is the content of your blog. If you’re a musician or a podcaster then audio is the main form of content you want to share. 3. You posts have some relationship with music, for example, an article introducing people to music that you know and love, or about spoken podcasts, books on tape, and so on. As with music, a blog can add a lot of context, color, and camaraderie around spoken pieces. 4. You are running a personal blog, and your followers are friends you are familiar with. You believe most of you have similar taste about music. You may come up with more possibilities.   How to Add Audio to WordPress? Having already familiar with WorPress’s robust functions in words and images, you may eager to know how to add audio to a WordPress site. It might be a good stretch for you and your blog visitors if you make an effort to occasionally use music in your posts. There are multiple methods of inserting music into a post in WordPress. Taking our free WordPress theme Journal Box for example, I’ll mainly introduce three means.

music

1. Use WordPress Media Library

Go to Dashboard -> Posts -> Add New. Click on the “Add Media” button.

music

Upload a music file or select an existing file in the Media Library. Finally click on the “Insert to post” button.

music

You will see a sentence of codes like in the “Text” box. Preview the post, and you can see the music player among the texts.

music

  2. Use Codes

1) Go to Dashboard -> Media -> Add New. Upload a music file to the Media Library. Then move to Media Library, find the file you’ve uploaded just now and open it. Copy the file URL in the right box.

music

2) Go to Dashboard -> Posts, Add New.  swift to “Text” mode, type in the following codes, and paste the file URL. You can preview the effect before publishing the post.

<audio width=”300″ height=”32″ style=”‘margin:auto;” controls=”controls” autoplay=”autoplay” top:0=”” right:0=”” bottom:0=”” left:0=”” name=”media” src=”http://www.xxx.mp3″</audio>

music

These are only sample codes; you can change many properties by amending some key words. For example, if you don’t want to auto-play the music, delete autoplay=“autoplay”. If you want your music in a loop mode, add loop=“loop”.   3. Use Plugins Search for key word “Audio” in WordPress.org, and you can find various plugins. Not all of them are user-friendly, so you have to read their instructions carefully before deciding which one to use. Now I’ll explain how to use a HTML5 Audio plugin to insert music into a post.

1) Go to Dashboard -> Plugins -> Add New, type in “HTML5 Audio” in the search box, and you will see many plugins. Choose the second one “PB oEmbed HTML5 Audio – with Cache Support”, install and active it.

music

2) Go to Dashboard -> Posts -> Add New, navigate to the “HTML5 Audio-Generator” editing box.

music

Paste the file URL in the box or click on “Upload/Select from Media Library”. This plugin supports three file formats: MP3, OGG, and WAV.

music

You can deal with more properties from the multiple select boxes.

music

Finally click on the “Insert into the editor” button, and you can see a sentence of codes in the text box. You can preview the effect before publishing the post.

music

Till now, all of the three methods have been explained in detail. Similar to inserting music to a post, the methods of adding music file to a page is the same. By the way, two points you need to pay attention to. First, the maximum upload file size is 8MB. Second, some browser may not support music file other than MP3 format, and not all these methods are compatible with different browser. Anyway, they are worth trying.

What do you think about using music in WordPress websites? Any experience on this topic is welcomed to share with us!

About the author: Magee

You must be logged in to post a comment.