Forums

RS-Linkify Thread is sticky

Quick find code: 261-262-33-65181208

AoDude

AoDude

Posts: 1,694 Mithril Posts by user Forum Profile RuneMetrics Profile
Indecent Act said :


Blasty said :
Bug report~

The first number in the QFC in the thread list is missing for me:
http://i.imgur.com/w5QsXEC.png

Edit:
In case it helps:
canonicalFull = $("link[rel='canonical']" ).attr("href" ) // http://services.runescape.com/m=forum/forums.ws?86,87
canonicalFull.slice(49) // 6,87

Anyone know if there has been a forum update recently...

http://i.imgur.com/OT7BhQx.png
^They just fixed missing backslash, and now looking at the source it's broken again. I read from there because it's always free of ad trackers, and because it's in the head I don't need to wait for the DOM to be loaded or interactive.

That's the cause of the problem, but I'd don't know if I'm going crazy, as I'm sure it wasn't like that 2 days ago and I'm sure it was like that a few more gays ago. Anyway this tell me it's time for a regex approach.

Thanks blasty :)


What if you change the code to this?

canonicalFull = $("link[rel='canonical']" ).attr("href" ) // http://services.runescape.com/m=forum/forums.ws?86,87
n = canonicalFull.indexOf("?&quot ;) +1
canonicalFull.slice(n) // 86,87
AO
Deputy-Owner :
The Nexus CC

08-Nov-2015 15:53:56

Indecent Act

Indecent Act

Posts: 7,456 Rune Posts by user Forum Profile RuneMetrics Profile
Yep that would work, although I have already pushed out my regex method (for forum sections) that just works with the digits as I figure that's the safest bet for malformed urls.

Slice is actually my preferred choice, as regex is overkill for simple string manipulations.

But I want this to be as robust as possible since I've been burnt more than once. It doesn't matter what they omit from the URL now, as long there is comma separated numbers, I'll get the bits I need...

I hope :)

08-Nov-2015 17:02:44 - Last edited on 08-Nov-2015 17:05:27 by Indecent Act

AoDude

AoDude

Posts: 1,694 Mithril Posts by user Forum Profile RuneMetrics Profile
Indecent Act said :
Yep that would work, although I have already pushed out my regex method (for forum sections) that just works with the digits as I figure that's the safest bet for malformed urls.

Slice is actually my preferred choice, as regex is overkill for simple string manipulations.

But I want this to be as robust as possible since I've been burnt more than once. It doesn't matter what they omit from the URL now, as long there is comma separated numbers, I'll get the bits I need...

I hope :)


Oops, didn't know I was already too late for the party. Cheers for the fix though!

And who knows, jagex might drop the "?" in the canonical link next week and then it would have just broke again. So long live the regex method...

­coffee
AO
Deputy-Owner :
The Nexus CC

08-Nov-2015 17:19:12

Indecent Act

Indecent Act

Posts: 7,456 Rune Posts by user Forum Profile RuneMetrics Profile
AoDude said :
Hmm, something broke and they had to roll back the forums... Your last post no longer exists indy... interesting

Oh well it was nothing important I posted, just some regex.

I wonder did my postcount go down by one. Not that I care about postcount, just curious how it works.

Body btw said :
Not the first time this has happened. Very annoying either way

I recall seeing that happen when you posted once.

I read you'r post, came back later and it was gone. I remember what it was too, it was when I changed my name to a p-mod friendly one, you said something to the effect of poll to change Indy's name back :)

09-Nov-2015 02:03:03 - Last edited on 09-Nov-2015 02:03:40 by Indecent Act

AoDude

AoDude

Posts: 1,694 Mithril Posts by user Forum Profile RuneMetrics Profile
Indecent Act said :
AoDude said :
Hmm, something broke and they had to roll back the forums... Your last post no longer exists indy... interesting

Oh well it was nothing important I posted, just some regex.

I wonder did my postcount go down by one. Not that I care about postcount, just curious how it works.


Lol I know, I read it, but it is a little alarming to come back to a thread I know I didn't post last on, and see that somehow I had posted last... Though I might have been hacked for a split second.
AO
Deputy-Owner :
The Nexus CC

09-Nov-2015 02:22:44

Quick find code: 261-262-33-65181208 Back to Top