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
Thanks for looking at reddit. I suppose in my mind I was thinking in terms of a single comment (mostly to quick reference jmod comments).

So in your example: https://www.reddit.com/r/runescape/comments/42iatz/invention_megathread/

Mod Matthe made a post here: https://www.reddit.com/r/runescape/comments/42iatz/invention_megathread/czb42zu

Which contained:
[–]JagexMattHeMod MattHe 31 points 1 month ago
Invention is about discovery, pioneering your own way. Once you have done the in game tutorial a number of the confusions will evaporate but we will be keeping an eye out for any features that aren't clear and making sure the appropriate explanations are available.


But as you said, a discussion might be warranted... If that were possible, would that be something others wanted?

Edit:

It appears this can be done with the following code:

<script src="https://www.reddit.com/r/runescape/comments/42iatz/invention_megathread/czb42zu.embed?limit=1&t=all" type="text/javascript"></script>

Which should parse to this: http://puu.sh/nORq5/50baafdc35.jpg

Edit 2: http://www.redditblog.com/2015/03/announcing-embeddable-comment-threads.html

This method looks better...

http://puu.sh/nOUpA/a99b6b02b9.jpg

Now seeing if I can derive the script...

Edit 3: <div class="reddit-embed" data-embed-media="www.redditmedia.com" data-embed-parent="false" data-embed-live="true"><a href="
The direct link
">.</a></div><script async src="https://www.redditstatic.com/comment-embed.js"></script>
AO
Deputy-Owner :
The Nexus CC

21-Mar-2016 16:59:47 - Last edited on 21-Mar-2016 20:12:54 by AoDude

Indecent Act

Indecent Act

Posts: 7,456 Rune Posts by user Forum Profile RuneMetrics Profile
Awesome AoDude, thanks for the detailed post :)

I have no problem getting the comments via JSONP, getting comments is something I've been able to do from the start.

$.ajax({
url: "...........42iatz/invention_megathread/42iatz.embed?limit=1&t=all",
dataType: "jsonp",
success: function (response) {
console.log(response);
}
});

But I still cant get the actually topic's contents.

For example: https://www.reddit.com/r/runescape/comments/42iatz/invention_megathread/

That's where I'm having trouble. I'll look into it again, but currently if someone posted that link, and linkify were to embed it, all you'd see is the first comment, not the guide.

I feel like I'm missing the point somewhere, either with the api or with reddit :/

21-Mar-2016 23:03:15

AoDude

AoDude

Posts: 1,694 Mithril Posts by user Forum Profile RuneMetrics Profile
As far as the topic's contents, that is probably an issue of most of the topics are in-fact links to other things around the net.

For instance: https://www.reddit.com/r/runescape/comments/4bcyqp/varrock_west_bank_tree_now_has_a_new_examine/

The content is:

http://i.imgur.com/Oqxgg4D.png


Instead of a self.runescape text post like:
https://www.reddit.com/r/runescape/comments/4bcdim/21032016_game_update_thread/

----

Now if I am understanding the issue, instead of embedding all links starting with "https://www.reddit.com/..."; you would need to differentiate between a comment and a link to the whole thread? As in, whether it ends with "/" or a 7 character alpha/num string?

Or are you really trying to find a way to gather exactly what the content of the "main/original" post is?

Edit: If the answer is yes to the last question, then I think that kinda goes against the point. If I were to post a link to the thread as a whole, I would rather others follow the link to the whole thread. But if I were to post a link to a specific comment, I really am wanting others to see that specific comment.

Would be the difference between posting a qfc link on RSOF, or quoting a post from that thread...
AO
Deputy-Owner :
The Nexus CC

21-Mar-2016 23:20:56 - Last edited on 21-Mar-2016 23:51:30 by AoDude

Indecent Act

Indecent Act

Posts: 7,456 Rune Posts by user Forum Profile RuneMetrics Profile
I was hoping to embed the main post, and/or include it with comments.

A comment without any subject matter is what I'm trying to avoid.

The way I see it is embedding content is so you don't need to leave the forums. But embedding comments without the actual topic means you have to go to reddit to put the comment in context. Defeating the purpose of embedding.

If embedding is doing nothing more than linking to the full content I have to ask myself what's the point.

After seeng this, I'd need to go to reddit to view the thread. The most usful bit is the link at the bottom and I'm already providing that.
http://puu.sh/nOUpA/a99b6b02b9.jpg

I don't mean to sound down on it, I like that JSONP is working for comments, but it feels lacking without the subject.

I'll keep fiddling around with it. I worry I'm putting too much emphasis on the subject matter. Perhaps I need to rethink what reddit is all about.

I do however really appreciate all your help with this, when I got comments embedding I thought I was onto something but I have just been going in circles from then on :/

Edit: If it has be to be comments only, I'll do that. Just seemed odd to me is all :)

22-Mar-2016 00:05:19 - Last edited on 22-Mar-2016 00:13:37 by Indecent Act

AoDude

AoDude

Posts: 1,694 Mithril Posts by user Forum Profile RuneMetrics Profile
I think it is more a case of quoting jmods/sources when the subject of the thread and the subject of the reddit are essentially equal.

As in, if there were a thread on HLF asking about when divination would be spotlighted in the treasure hunter event: https://www.reddit.com/r/runescape/comments/4ba05r/divination_for_world_event/d17oswf

Or a thread trying to figure out Raids drop mechanics: https://www.reddit.com/r/runescape/comments/47fa4n/actual_raids_drop_rate/d0fnna6

A random comment with no context would not make any sense, agreed. But in the context of the thread, a relate-able quote can be helpful.

Edit: Does anyone else have opinions or thoughts on this? Am I the only person who would actually use this feature?
AO
Deputy-Owner :
The Nexus CC

22-Mar-2016 00:24:12 - Last edited on 22-Mar-2016 00:27:49 by AoDude

Indecent Act

Indecent Act

Posts: 7,456 Rune Posts by user Forum Profile RuneMetrics Profile
Thanks for your patience AoDude. I don't get reddit and that's where my problems stemmed from. I guess I placed too much importance on getting the subject.

Anyway here's how it looks (exactly as I had it the other day but I stopped because I thought it was incomplete).

HTTP://i.imgur.com/eTz5e2R.png
I still have some things to do before I can push it out, but I should get it out today :)

22-Mar-2016 02:01:07

Indecent Act

Indecent Act

Posts: 7,456 Rune Posts by user Forum Profile RuneMetrics Profile
Update Time!

RS Linkify Version 3.1.9.43-ish <-- Yes "-ish" as this covers a couple of updates.

- Embeds Reddit comments (Thanks AoDude) It can be toggled see: Settings --> Embedding

- Fixed an issue with consecutive smilieys (Thanks Bodyy).

- Removed the code and options for default fonts as it's no longer needed.

- Forum Home: expanded/contracted sections are remembered.

- Text to Image codes are no longer case-sensitive. For example...

* FaCePaLm
* Facepalm
* facepalm
* FACEPALM

should all work :)

Big thank you to everyone for all the comments, feedback, bug reports and coffee ­<3

22-Mar-2016 04:51:08 - Last edited on 22-Mar-2016 05:11:28 by Indecent Act

Blasty
Feb Member 2017

Blasty

Posts: 9,319 Rune Posts by user Forum Profile RuneMetrics Profile
Hey Indy, I hope you're doing well! :)

I just came across this javascript style guide and it all looked a bit alien to me:
https://github.com/airbnb/javascript

I was just wondering if you had any experience with the new syntax, or if you had any thoughts to share on it.

Alsoo, I've just started making proper use of git this semester (finally) and I'm finding it amazing what can be built in a short amount of time thanks to awesome public boilerplate repositories. I recently started experimenting with properly hosted websites thanks to one of my courses, and it's super exciting to have such a variety of back-end languages and architectures to choose from now that I'm using git and the terminal properly.

The embedded reddit comments look sweet, awesome work :D
Blasty
// @BlastytheBlue // Blasty#5167
| Co-owner of Mine Nation

22-Mar-2016 12:00:31

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