Skip to content

Instantly share code, notes, and snippets.

@AlexJWayne
Created October 20, 2009 20:56
Show Gist options
  • Select an option

  • Save AlexJWayne/214609 to your computer and use it in GitHub Desktop.

Select an option

Save AlexJWayne/214609 to your computer and use it in GitHub Desktop.
CKURL *url = create(CKURL);
curl_setURL(url, cstring_text(urlString));
dispose(urlString);
CKMemory *document = (CKMemory *)curl_fetch(url, 60);
if (!document) {
cobject_error(self, 3, "Failed to load URL: %s", curl_text(url));
}
cstream_open(document, CK_ReadOnly);
CKObject *json = CKRuntimeThaw(superclass(document), NO);
CKList *rootPostList = cobject_evaluate(json, "comments");
CKObject *rootPostComment = clist_firstElement(rootPostList);
CKList *posts = cobject_evaluate(rootPostComment, "comments");
CKList 0x1002865d8 = {
0: [(CKHash *)0x10027b488 = {
[(CKString *)0x1002756d8 = "id"] -> [(CKValue *)0x10027a468 Type=Int64 Value=21194810]
[(CKString *)0x1002815a8 = "date"] -> [(CKString *)0x1002812b8 = "Oct 20, 2009 1:19pm CST"]
[(CKString *)0x100281358 = "category"] -> [(CKString *)0x100281068 = "stupid"]
[(CKString *)0x1002817f8 = "body"] -> [(CKString *)0x100281508 = "What happens when you fuck a stranger in the acidspan class="jt_green"?/span#13;br/br/a target="_blank" href="http://www.shackpics.com/viewer.x?file=astrangerintheass_qgc15kmzfzok29cjntkv.jpg"http://www.shackpics.com/viewer.x?file=astrangerintheass_qgc15kmzfzok29cjntkv.jpg#13;/abr/br/attn span class="jt_sample"span class="jt_strike"Captain Corvette/span/span span class="jt_yellow"gmd/span"]
[(CKString *)0x100280eb8 = "author"] -> [(CKString *)0x100280b28 = "Lunatic Angelic"]
[(CKString *)0x100283238 = "last_reply_id"] -> [(CKValue *)0x100289018 Type=Int64 Value=21196482]
[(CKString *)0x100275778 = "reply_count"] -> [(CKValue *)0x100272808 Type=Int64 Value=11]
[(CKString *)0x100280be8 = "comments"] -> [CKList 0x1002855a8 = { }]
[(CKString *)0x100281108 = "preview"] -> [(CKString *)0x100280e18 = "What happens when you fuck a stranger in the acid? http://www.shackpics.com/viewer.x?file=astrangerintheass_qgc15kmzfzok29cjntkv.jpg attn Captain Corv"]
[(CKString *)0x100283198 = "participants"] -> [CKList 0x100285358 = {
0: [(CKHash *)0x100267b88 = {
[(CKString *)0x100283dc8 = "post_count"] -> [(CKValue *)0x1002802b8 Type=Int64 Value=1]
[(CKString *)0x1002836d8 = "username"] -> [(CKString *)0x100283638 = "trOmblyj"]
}]
1: [(CKHash *)0x10023fd38 = {
[(CKString *)0x100284418 = "post_count"] -> [(CKValue *)0x10027fdf8 Type=Int64 Value=1]
[(CKString *)0x100283d28 = "username"] -> [(CKString *)0x1002844b8 = "Crabs Jarrard"]
}]
2: [(CKHash *)0x10026c5b8 = {
[(CKString *)0x100283488 = "post_count"] -> [(CKValue *)0x10027ed08 Type=Int64 Value=1]
[(CKString *)0x100282d98 = "username"] -> [(CKString *)0x100282cf8 = "everybodysuncle"]
}]
3: [(CKHash *)0x100280b78 = {
[(CKString *)0x100283888 = "post_count"] -> [(CKValue *)0x10027cb38 Type=Int64 Value=2]
[(CKString *)0x1002833e8 = "username"] -> [(CKString *)0x100283928 = "Lunatic Angelic"]
}]
4: [(CKHash *)0x10026a568 = {
[(CKString *)0x100282fe8 = "post_count"] -> [(CKValue *)0x10027c678 Type=Int64 Value=1]
[(CKString *)0x100283b78 = "username"] -> [(CKString *)0x100283ad8 = "maulla"]
}]
5: [(CKHash *)0x10023f448 = {
[(CKString *)0x1002841c8 = "post_count"] -> [(CKValue *)0x10027f298 Type=Int64 Value=1]
[(CKString *)0x100282f48 = "username"] -> [(CKString *)0x100284268 = "dirge23"]
}]
6: [(CKHash *)0x1002895e8 = {
[(CKString *)0x100282608 = "post_count"] -> [(CKValue *)0x10027eda8 Type=Int64 Value=1]
[(CKString *)0x100282858 = "username"] -> [(CKString *)0x1002828f8 = "famine101"]
}]
7: [(CKHash *)0x100287c28 = {
[(CKString *)0x100282458 = "post_count"] -> [(CKValue *)0x10027afc8 Type=Int64 Value=1]
[(CKString *)0x1002826a8 = "username"] -> [(CKString *)0x1002823b8 = "sKetchflow"]
}]
8: [(CKHash *)0x100288568 = {
[(CKString *)0x100281e48 = "post_count"] -> [(CKValue *)0x10027bb18 Type=Int64 Value=1]
[(CKString *)0x1002802e8 = "username"] -> [(CKString *)0x100282208 = "gmd"]
}]
9: [(CKHash *)0x100275038 = {
[(CKString *)0x100281c98 = "post_count"] -> [(CKValue *)0x1002750a8 Type=Int64 Value=1]
[(CKString *)0x100281ee8 = "username"] -> [(CKString *)0x100281bf8 = "indosauros"]
}]
10: [(CKHash *)0x10026cb78 = {
[(CKString *)0x100281758 = "post_count"] -> [(CKValue *)0x10026cbe8 Type=Int64 Value=1]
[(CKString *)0x1002819a8 = "username"] -> [(CKString *)0x100281a48 = "dedgecko"]
}]
}]
}]
}
{
"story_id": 60928,
"story_name": "Morning Discussion",
"last_page": 1,
"page": 1,
"comments":
[
{
"last_reply_id": 21196942,
"participants":
[
{
"username": "Omning",
"post_count": 1
},
{
"username": "trOmblyj",
"post_count": 1
},
{
"username": "Crabs Jarrard",
"post_count": 1
},
{
"username": "everybodysuncle",
"post_count": 1
},
{
"username": "Lunatic Angelic",
"post_count": 2
},
{
"username": "maulla",
"post_count": 1
},
{
"username": "dirge23",
"post_count": 1
},
{
"username": "zakazi",
"post_count": 1
},
{
"username": "spiderfill",
"post_count": 1
},
{
"username": "famine101",
"post_count": 1
},
{
"username": "sKetchflow",
"post_count": 1
},
{
"username": "gmd",
"post_count": 1
},
{
"username": "riptyde",
"post_count": 1
},
{
"username": "breadsticks",
"post_count": 1
},
{
"username": "indosauros",
"post_count": 1
},
{
"username": "dedgecko",
"post_count": 1
}
],
"body": "What happens when you fuck a stranger in the acid\u003Cspan class=\"jt_green\"\u003E?\u003C/span\u003E\u0026#13;\u003Cbr/\u003E\u003Cbr/\u003E\u003Ca target=\"_blank\" href=\"http://www.shackpics.com/viewer.x?file=astrangerintheass_qgc15kmzfzok29cjntkv.jpg\"\u003Ehttp://www.shackpics.com/viewer.x?file=astrangerintheass_qgc15kmzfzok29cjntkv.jpg\u0026#13;\u003C/a\u003E\u003Cbr/\u003E\u003Cbr/\u003Eattn \u003Cspan class=\"jt_sample\"\u003E\u003Cspan class=\"jt_strike\"\u003ECaptain Corvette\u003C/span\u003E\u003C/span\u003E \u003Cspan class=\"jt_yellow\"\u003Egmd\u003C/span\u003E",
"date": "Oct 20,
2009 1:19pm CST",
"category": "stupid",
"preview": "What happens when you fuck a stranger in the acid? http://www.shackpics.com/viewer.x?file=astrangerintheass_qgc15kmzfzok29cjntkv.jpg attn Captain Corv",
"author": "Lunatic Angelic",
"comments":
[
{
"last_reply_id": null,
"body": "\u003Cspan class=\"jt_red\"\u003EO\u003C/span\u003E_\u003Cspan class=\"jt_blue\"\u003Eo\u003C/span\u003E",
"date": "Oct 20,
2009 1:35pm CST",
"category": "ontopic",
"preview": "O_o",
"author": "everybodysuncle",
"comments":
[
],
"id": 21194992,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "it's a c4 it is ok with me ! what the hell happened though",
"date": "Oct 20,
2009 1:37pm CST",
"category": "ontopic",
"preview": "it's a c4 it is ok with me ! what the hell happened though",
"author": "gmd",
"comments":
[
{
"last_reply_id": null,
"body": "I think it's the battery (on the hood) starting a fire when it exploded over the fuel lines,
they rolled it out to the street (look at the tire melt)\u003Cspan class=\"jt_green\"\u003E.\u003C/span\u003E",
"date": "Oct 20,
2009 1:57pm CST",
"category": "ontopic",
"preview": "I think it's the battery (on the hood) starting a fire when it exploded over the fuel lines,
they rolled it out to the street (look at the tire melt).",
"author": "Lunatic Angelic",
"comments":
[
{
"last_reply_id": null,
"body": "isn't the battery located on the opposite side?",
"date": "Oct 20,
2009 3:46pm CST",
"category": "ontopic",
"preview": "isn't the battery located on the opposite side?",
"author": "dedgecko",
"comments":
[
{
"last_reply_id": null,
"body": "well it \u003Ci\u003Ewas\u003C/i\u003E \u003Cspan class=\"jt_sample\"\u003E\u003Cspan class=\"jt_sample\"\u003E(no idea)\u003C/span\u003E\u003C/span\u003E",
"date": "Oct 20,
2009 4:31pm CST",
"category": "ontopic",
"preview": "well it was (no idea)",
"author": "zakazi",
"comments":
[
],
"id": 21196913,
"reply_count": 0
}
],
"id": 21196482,
"reply_count": 1
}
],
"id": 21195273,
"reply_count": 2
}
],
"id": 21195002,
"reply_count": 3
},
{
"last_reply_id": null,
"body": "they werent kidding about bologna on car paint",
"date": "Oct 20,
2009 1:37pm CST",
"category": "ontopic",
"preview": "they werent kidding about bologna on car paint",
"author": "indosauros",
"comments":
[
],
"id": 21195008,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "holy shit",
"date": "Oct 20,
2009 1:38pm CST",
"category": "ontopic",
"preview": "holy shit",
"author": "maulla",
"comments":
[
],
"id": 21195017,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "Viral marketing for next Aliens movie.",
"date": "Oct 20,
2009 1:40pm CST",
"category": "ontopic",
"preview": "Viral marketing for next Aliens movie.",
"author": "trOmblyj",
"comments":
[
],
"id": 21195036,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "somebody shot a xenomorph on that thing",
"date": "Oct 20,
2009 1:40pm CST",
"category": "ontopic",
"preview": "somebody shot a xenomorph on that thing",
"author": "dirge23",
"comments":
[
],
"id": 21195043,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "Please tell me someone was dripped on with hot melting face",
"date": "Oct 20,
2009 1:42pm CST",
"category": "ontopic",
"preview": "Please tell me someone was dripped on with hot melting face",
"author": "sKetchflow",
"comments":
[
],
"id": 21195058,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "\"I just bought that car last week!\"",
"date": "Oct 20,
2009 2:15pm CST",
"category": "ontopic",
"preview": "\"I just bought that car last week!\"",
"author": "Crabs Jarrard",
"comments":
[
],
"id": 21195462,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "I'm impressed that tire isn't more fucked up than it is.",
"date": "Oct 20,
2009 3:13pm CST",
"category": "ontopic",
"preview": "I'm impressed that tire isn't more fucked up than it is.",
"author": "famine101",
"comments":
[
],
"id": 21196115,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "Looks like this car had a bad encounter with an Alien.",
"date": "Oct 20,
2009 4:20pm CST",
"category": "ontopic",
"preview": "Looks like this car had a bad encounter with an Alien.",
"author": "breadsticks",
"comments":
[
],
"id": 21196819,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "fucking recluse spiders!!!!!",
"date": "Oct 20,
2009 4:22pm CST",
"category": "ontopic",
"preview": "fucking recluse spiders!!!!!",
"author": "spiderfill",
"comments":
[
],
"id": 21196838,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "that'll buff right out",
"date": "Oct 20,
2009 4:33pm CST",
"category": "ontopic",
"preview": "that'll buff right out",
"author": "riptyde",
"comments":
[
],
"id": 21196934,
"reply_count": 0
},
{
"last_reply_id": null,
"body": "\u003Cspan class=\"jt_strike\"\u003Esome acid damage\u003C/span\u003E THIS CAR IS SIZZLING!",
"date": "Oct 20,
2009 4:34pm CST",
"category": "ontopic",
"preview": "some acid damage THIS CAR IS SIZZLING!",
"author": "Omning",
"comments":
[
],
"id": 21196942,
"reply_count": 0
}
],
"id": 21194810,
"reply_count": 16
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment