Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion config.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,11 @@
define('DB_PASS', "YOUR_DATABASE_PASSWORD");

// DB table names

define('DB_TABLE', "tracks");

//your last.fm info
define('API_KEY', "YOUR_LASTFM_API_KEY");
define('LASTFM_USER', "YOUR_LASTFM_USER");

?>

3 changes: 1 addition & 2 deletions heardsync.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@
// for now, we'll just run this 2 times per day, so if you listen to more than 200 songs in 12 hours, we will miss some...
// at one point I knew the right way to do it but I didn't implement it, so feel free to figure it out...

$from_xml_source = 'http://ws.audioscrobbler.com/2.0/?method=user.getRecentTracks&api_key=xxxxxxxxxxxxxxxxxxxxxxxx&user=xxxxxxxxxxxx&limit=100&page=1';
// ...................................................................................... ^ PUT YOUR API KEY HERE ^ PUT YOUR USERNAME HERE
$from_xml_source = 'http://ws.audioscrobbler.com/2.0/?method=user.getRecentTracks&api_key='.API_KEY.'&user='.LASTFM_USER.'&limit=100&page=1';


$from_remote_fp = fopen($from_xml_source, "rb");
Expand Down
2 changes: 1 addition & 1 deletion tracks.php
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@
<h1><a href="./">Heard</a></h1>

<?php /* you may want to change this so it points to your own account */ ?>
<h2><a href="http://www.last.fm/user/rasterweb">visit rasterweb on Last.fm</a></h2>
<h2><a href="http://www.last.fm/user/<?php echo LASTFM_USER ?>">visit <?php echo LASTFM_USER ?> on Last.fm</a></h2>

<p style="float: left; clear: both">
<?php echo $thecount ?> tracks scrobbled.
Expand Down