Last.fm Online Status

 
    • spacefish a dit :...
    • Utilisateur
    • 28 jui. 2006, 20h16m
    Seems to be working fine here. I haven't noticed anyone last seen in the morning though.

    • [Utilisateur supprimé] a dit :...
    • Utilisateur
    • 28 jui. 2006, 20h57m
    spacefish said:
    Seems to be working fine here. I haven't noticed anyone last seen in the morning though.


    There's actually no code in it to handle the morning, that's why I'm wondering if it exists. I could just throw in code to handle it... this is basically the final product. (For now at least)

    • MikeManger a dit :...
    • Utilisateur
    • 23 avr. 2007, 17h21m
    Ok made some changes so it works with the new site.

    I've hosted the script so feel free to download it from here (although I'd be glad if staticsage updated his script).

    I've added 'User Script Updates Support' as (I think) there are a couple of things that might not work/need improving - e.g. the menu could be done better. The essentials seem to work for me though ('last seen change' and name change)

    To do a 'quick' fix edit the script on the main page with these alterations:

    find all: aboutMe
    replace all with: LastHeadline

    find: ("\/\"\>", "\/\"\>\<font color\=green\>")
    replace with: ("h1user\"\>", "h1user\"\>\<font color\=green\>")

    find: ("\<\/a\>", "\<\/font\>\<\/a\>")
    replace with: ("\<\/h1\>", "\<\/font\>\<\/h1\>")

    find: ("\/\"\>", "\/\"\>\<font color\=#BA001E\>")
    replace with: ("h1user\"\>", "h1user\"\>\<font color\=#BA001E\>")

    find: ("\<\/a\>", "\<\/font\>\<\/a\>")
    replace with: ("\<\/h1\>", "\<\/font\>\<\/a\>")

    I actually am glad last.fm have reorded the 'about me' section the way they have, even if it does mean more breakage!

    Modifié par MikeManger le 31 jui. 2008, 15h29m
    • spacefish a dit :...
    • Utilisateur
    • 23 avr. 2007, 18h34m
    Thanks, Mike! I'm going to use your script link on the overview so I guess the edit fix won't be required for folks who grab it from there.

    • MikeManger a dit :...
    • Utilisateur
    • 23 avr. 2007, 19h27m
    No problems.. I've got a feeling that some of the other 'not working' scripts might be fixable in a simular manner (last.fm replacing the <a>s with <headings> is a biggie), so I'll look into it.

    • Elan11 a dit :...
    • Utilisateur
    • 22 juin 2007, 19h07m
    Is it possible to see if someone is on-line from your own profile page.
    With that I mean adding an icon or something to the
    a)Friend list
    b)Neighbours
    c)Shoutbox

    Just wondering :)

    -Elan

    We rode on the winds of the Rising Storm
    We ran to the sounds of the thunder
    We danced among the lightning bolts
    And tore the world asunder
    • MikeManger a dit :...
    • Utilisateur
    • 31 jui. 2008, 15h27m
    Hey guys new version for the new site.

    Takes into account mornings as well.

    • [Utilisateur supprimé] a dit :...
    • Utilisateur
    • 1 août 2008, 5h54m
    a terrible bug. I wanted to post a shout and it turned out to be impossible on any profile. Instead of posting the shout, the "post" button redirected me to the profile of the user shout o_O It occurred on every profile page and vanished after removing this script. Previously I considered recently installed Carousel, but checked both and this is it.

    • spacefish a dit :...
    • Utilisateur
    • 1 août 2008, 7h05m
    Wow! Is that what it was? I even tried to shout to Mike about this very script but I got sent to the shout abyss myself. For me though, it was possible to shout on some user profiles. Just not on Mike's! Didn't occur to me that it was a script causing this. Thought it was just another last.fm bug.

    • [Utilisateur supprimé] a dit :...
    • Utilisateur
    • 1 août 2008, 8h25m
    but can you shout with the script removed?

    • spacefish a dit :...
    • Utilisateur
    • 1 août 2008, 8h50m
    I don't know. I haven't tried that yet.

    • MikeManger a dit :...
    • Utilisateur
    • 1 août 2008, 12h37m
    Now I'm confused. I don't doubt you at all but if you look at the shouts on the page it is redirecting you to it could well be to do with any number of scripts. I've noticed a minor last.fm updated today (new 'free download' icons) so I'll check to see if anything has changed. :s

    Oh and I'll do a search on the forums to see if this has being reported.

    Cheers.

    • spacefish a dit :...
    • Utilisateur
    • 1 août 2008, 12h55m
    Well, that's true. The shouts left there have been there awhile. I also tried to search the forums but didn't find anything specific related to that page. Hmmm... maybe I should have searched for that page. Odd in all the time I've been here and been using scripts, I've never seen it before though.

    • MikeManger a dit :...
    • Utilisateur
    • 1 août 2008, 13h45m
    UPDATE: uploaded a partial fix that doesn't colour the name in, but (thank god) seems to allow you to post shouts. You might need to clear your cache to get the updated version.

    I had some fun spamming people's box (trying locate the harmful code) and it turns out you can muck around with the shout box without even meaning to; at one point the 'detect shout' button was un reachable (even with greasemonkey disabled!).

    • snyde1 a dit :...
    • Abonné
    • 1 août 2008, 18h19m
    It is a bug, but I think it is Last.fm's, and not in this script. The "action" for the shout box is just "shout", when I think it should properly be "javascript:shout()". shout should complain ...

    I don't see off-hand what in the script is causing the interaction to trigger this bug. There may also a bug in the script. (Too broad a match, maybe?)

    You could try changing the Last.fm form action and see if that fixes the problem.

    Improve your view of Last.fm - add some User Scripts.
    Did I hear that right? Mondegreens - for the misheard word. Like Odds? Can't get better than Even Odds!

    Speak your truth quietly and clearly; and listen to others, even to the dull and the ignorant; they too have their story.
    • MikeManger a dit :...
    • Utilisateur
    • 1 août 2008, 18h45m

    My mind is whirling..

    snyde1 said:
    It is a bug, but I think it is Last.fm's, and not in this script. The "action" for the shout box is just "shout", when I think it should properly be "javascript:shout()". shout should complain ...

    I don't see off-hand what in the script is causing the interaction to trigger this bug. There may also a bug in the script. (Too broad a match, maybe?)

    You could try changing the Last.fm form action and see if that fixes the problem.

    I've narrowed it down to 2 lines causing the problem, and I think it might be the 'too broad a match' problem you mention.

    The code I've commented out to make things work is:
    document.getElementById('content').innerHTML = document.getElementById('content').innerHTML.replace("\<h1\>"+user+"\<\/h1\>", "\<h1\>\<font color\=#BA001E\>"+user+"\<\/font\>\<\/h1\>"); (plus the other line for 'online').
    I'm going to start by narrowing things down - searching the whole content is a no go. :s

Les utilisateurs anonymes ne peuvent pas poster de messages. Merci de vous connecter ou de créer un compte pour pouvoir intervenir dans les forums.