burn / oujs.org scripts stats

Aldo I prefer to see this build-in to the site, this script looks promising.

Before I could fully testing it, I got two error's that requires fixing:

  • I'm an admin on this site, which means my menu looks a bit different. To fix it you could change your for loop into a revering one and change to a more targeted selector: $("nav.navbar .navbar-collapse-top a"). The ends of the bar looks the same for users and admins.
  • Most of my scripts run in Scriptish, but for some reason yours doesn't work. After investigating I found an issue with GM_getValue default value. Aldo the documentation says it supports defaultValue it errored with TypeError: arrStored is undefined. I fixed it by using the following code return eval(GM_getValue(name) || (def || '({})'));.

Hope you'll fix above two issues so I can test it further.
Keep up the great work.

Hi,
thanks for your feedback, I've just published a new version which fixes both the issues you prompted me.

Regarding catching username, I do know mine was a weak routine so thanks again.

Let me know if you ever decide to build my code into oujs.org, I'm glad to contribute.

Re: @jerone:

see this build-in to the site

We could use client side local storage but will run into a security risk. I've thought many a time about doing something similar to US.o script author helper but usually it ends up needing the data stored client side... which runs into collisions with automatic cleanup routines on the client computer.

Re: @burn:

It would be nice to have a screenshot on your script homepage too. I've installed this a few times and didn't observe much happening... so it would be nice to know exactly where to look.

usually it ends up needing the data stored client side... which runs into collisions with automatic cleanup routines on the client computer.

Imho that ain't a problem: if an user cleans cookies / localStorage, my userscript will show no statistics at all, as if it were just installed. Does this Make sense?

Re: @burn:

thanks for your feedback, I've just published a new version which fixes both the issues you prompted me.
Working great now!

Re: @burn:

Does this Make sense?

The likelihood of using local storage is minimal from the OUJS perspective due to this. It would be very frustrating for those users that did clear it and reports would come in. Also some extensions/add-ons block local storage usage completely. I think it's best to keep this user.js side.