NP_lastfm.php

Outputs a user's last.fm stats via the last.fm API

Installing

  1. Upload NP_lastfm.php to your /nucleus/plugins
  2. Install the plugin via the Nucleus admin panel.

How to use the plugin

Place the skin vars where you want them to appear. Make sure you change the start/end tags, or put the skin vars in <ul></ul> tags if you use the default tags. Via the Nucleus plugin admin, set your username and your API key in the options. If you do not have a API key, you can get one at http://www.last.fm/api/account

Available SkinVars and/or TemplateVars

  • See the code for the (long) list.

Options

  • last.fm user name - The last.fm user name you would like to get stats for.
  • Display links - Turn track names, artist names, and album names into last.fm links.
  • Display play count - Add play counts to top tracks, albums, and artists.
  • Start tag - The opening tag for each entry.
  • End tag - The closing tag for each entry.
  • last.fm API key - Your last.fm API key.

History

  • Version 1.0, released 8-6-2008
    • Initial release
  • Version 1.1, released 8-7-2008
    • Added loved tracks, and weekly charts.
    • Switched from IF ELSEIF ELSE to SWITCH CASE
    • Moved everything into functions
    • All the cases are handled by 4 functions. It should be pretty easy for a user to write their own functions (or modify current ones to say, display album art) using the last.fm API and the current functions
np_lastfm.txt · Last modified: 2008/08/08 05:11 (external edit)
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial-Share Alike 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki