Journal

Listening to Special Music Website Songs on Linux

2009·08·04

Machine-translated from Chinese.  ·  Read original

Some time ago, someone asked how to listen to the songs from the China Agricultural University’s Ya Cool Music (http://music.cau.edu.cn/). At the time, I proposed an idea, but due to preparations for various exams, I didn’t have time to work on it. Today, I took some time to analyze it and wrote a small script, successfully implementing the ability to listen to Ya Cool Music songs on Linux. Currently, this is only the first version, and I haven’t created a GUI. Many practical functions, such as playlists, have not been implemented yet. I’ll refine it further when I have more time.

Download link: http://www.darlingtree.com/upload/musiccau.tar (10,240 bytes)


Usage:

  1. Open a terminal and navigate to the directory containing the script. Run:
python musiccau.py

After running the script, you will see the prompt:

ADDRESS:

At this point, go to http://music.cau.edu.cn/.

  1. Select the song you want to listen to, right-click on the song link, and choose “Copy link address”.

  2. Then, paste the link address into the terminal (right-click in the terminal and choose “Paste” or press Ctrl+Shift+V).

Note: The pasted address should be in the format:

javascript:PlayIt('Yxplay.php?id=105662&s=d2240beae555b76b79661f8cb999a1bf');

Not in the format:

http://music.cau.edu.cn/Yxplay.php?id=103714&s=d2240beae555b76b79661f8cb999a1bf
  1. Press Enter to confirm.
  • Supplement:

By default, the script uses Firefox to open the MP3 music. Please ensure that your Firefox has the necessary plugin installed (such as the mplayer plug-in, available at http://mplayerplug-in.sourceforge.net/index.php). You can also modify the info file to use a different MP3 player or browser, such as:

smplayer
opera

Note: This is the first version, and the functionality is not yet complete. Please be patient. If you have any questions or suggestions, please post on the Linux version of wusetu or contact quake’a#t’vip.qq.com. Lately, I’ve been busy with various tasks, so if your questions and suggestions don’t receive a timely response, please be understanding.

留 · 言