Page 1 of 1

Re: Scrobbling everything to Last.fm?

PostPosted: Fri Dec 23, 2011 4:46 pm
by ytechie
You mean to have two last.fm accounts per subsonic user? One for the user's personal last.fm and the other for the global last.fm account?

Re: Scrobbling everything to Last.fm?

PostPosted: Fri Dec 23, 2011 6:32 pm
by ytechie
Two accounts but only one is able to be edited by the user. The other global account won't be displayed to the user.

Re: Scrobbling everything to Last.fm?

PostPosted: Wed Dec 28, 2011 2:04 pm
by BKKKPewsey
ytechie wrote:Two accounts but only one is able to be edited by the user. The other global account won't be displayed to the user.

Not at the moment without a mod, so I am moving this thread to Feature Requests :D
The only thing you can do at the moment is to have all the user accounts logging into the same Last FM a/c
but of course they will then lose their individual "scrobbles" (I still think its a stupid word :roll: )

Re: Scrobbling everything to Last.fm?

PostPosted: Wed Dec 28, 2011 4:25 pm
by BKKKPewsey
Its a bit of a pain if you have many users as its on the settings/personal tab.
So you have to log on as each user and set-up "Register what I'm playing at Last.fm" with the same user a/c.
Remember to enable user XXXX can change settings & password from admin a/c before logging on as user xxxx
:mrgreen:

Re: Scrobbling everything to Last.fm?

PostPosted: Wed Dec 28, 2011 9:14 pm
by ytechie
You might be able to edit the jsp file directly and place the last.fm account details as the values in their corresponding form elements. then, if the form gets submitted, the last.fm details will automatically default to the ones you set previously.

Don't forget to change the form elements that you want hidden to type="hidden" instead of type="text."

Re: Scrobbling everything to Last.fm?

PostPosted: Thu Dec 29, 2011 4:12 am
by ytechie
Oh by the way, there is a way to get all the passwords, and I am not going to write it out in the open. It might be tedious though to figure out each user's password, log in, and save the settings.

Just know that the is a way to learn the passwords of other users if and only if you are an administrator.

Re: Scrobbling everything to Last.fm?

PostPosted: Sun Jan 01, 2012 9:21 pm
by ytechie
Great news!

This is what you have to do to change all Last.fm accounts at once:

1) Go to http://www.string-functions.com/string-hex.aspx and convert your last.fm password to hex.
2) Take the value of your password in hex, and add 'enc:' to the front of it, so the password '123' would become 'enc:313233'
3) Go to [yourserver]/db.view
4) Type the following into the textarea: "update user_settings set LAST_FM_USERNAME='{username}', LAST_FM_PASSWORD='{password}', LAST_FM_ENABLED='true'". The {username} is the Last.fm username and {password} is the encoded hex password (step 2).
5) Click submit.
6) Very important step!! Perform a clean reload of your Subsonic server. When you reload the server, the subsonic.script file will be repopulated. (Do not hold down the power button or kill the service. My server is running on an Ubuntu server, so I use the command "sudo service subsonic restart."


If you don't want any users to be able to edit the Last.fm accounts unless they are administrators, you can edit the file personalSettings.jsp, and add the lines '<c:if test="${command.user.adminRole}">' and '</c:if> as I did below:

Code: Select all
<c:if test="${command.user.adminRole}">
    <table class="indent">
        <tr>
            <td><form:checkbox path="lastFmEnabled" id="lastFm" cssClass="checkbox" onclick="javascript:enableLastFmFields()"/></td>
            <td><label for="lastFm"><fmt:message key="personalsettings.lastfmenabled"/></label></td>
        </tr>
    </table>

    <table id="lastFmTable" style="padding-left:2em">
        <tr>
            <td><fmt:message key="personalsettings.lastfmusername"/></td>
            <td><form:input path="lastFmUsername" size="24"/></td>
        </tr>
        <tr>
            <td><fmt:message key="personalsettings.lastfmpassword"/></td>
            <td><form:password path="lastFmPassword" size="24"/></td>
        </tr>
    </table>
</c:if>

Re: Scrobbling everything to Last.fm?

PostPosted: Fri Jun 08, 2012 5:38 pm
by ytechie
Glad this helped you!
I don't know why subsonic wouldn't scrobble when using iSub. The subsonic server takes care of all scrobbling. In iSub there is an option to scrobble after a certain percentage of the song is played. Can you double check all of your settings?