Post Reply 
Twitter - Anyone use it?
Author Message
boogschd
boogyman
Worlds End

Posts: 4,954.3196
Threads: 90
Joined: 29th Nov 2007
Reputation: 4.19708
E-Pigs: 43.6852
Offline
Post: #11
RE: Twitter - Anyone use it?
06/05/2009 07:27 PM
Visit this user's website Find all posts by this user Quote this message in a reply
matchung
Turok Makto

Posts: 1,744.2413
Threads: 180
Joined: 5th Mar 2007
Reputation: -1.62846
E-Pigs: 162.3154
Offline
Post: #12
RE: Twitter - Anyone use it?
camera,, cannon?

Woo
06/05/2009 07:36 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Punk777E
Bowchikawowow

Posts: 356.9400
Threads: 10
Joined: 28th Jan 2009
Reputation: 1.46329
E-Pigs: 3.0796
Offline
Post: #13
RE: Twitter - Anyone use it?
Nope i prefer facebook it's the bomb!
And i am the terrorist (love that simile/metaphor i really don't feel like looking at keywords at the moment)

[Image: 218ohu.jpg]
If you want to save the penguins clix here


Spoiler:
Whit3f4ng Wrote:I got 8 inches yesterday and another 5 today.
Punk777E Wrote:xDDDDDDDD
06/05/2009 07:59 PM
Find all posts by this user Quote this message in a reply
krystabegnalie
~~~~I can cut trees!~~~

Posts: 2,127.4190
Threads: 218
Joined: 21st Jan 2008
Reputation: -6.39875
E-Pigs: 79.3639
Offline
Post: #14
RE: Twitter - Anyone use it?
twit twit? ehhh i thought i thaw a puttycat..

well i still prefer facebook, lol, or friendster in asian countries

Spoiler for don't look, might destruct your mind:
[Image: funny_math.jpg]
Spoiler for anime planet:
[Image: krystabegnalie.jpg]
06/05/2009 08:20 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Mickey
Down with MJ yo

Posts: 3,663.2843
Threads: 251
Joined: 26th Apr 2008
E-Pigs: 28.7300
Offline
Post: #15
RE: Twitter - Anyone use it?
matchung Wrote:anyone know any php scripts can retrieve twitter contents then put on our own host?

twitter is quite slow response from my side..
http://twitter.com/matchung
What exactly do you want to retrieve? I can write up a quick script

[Image: MiCk3Y.jpg]

[Image: battle.png]

Spoiler for link:
06/05/2009 08:38 PM
Find all posts by this user Quote this message in a reply
matchung
Turok Makto

Posts: 1,744.2413
Threads: 180
Joined: 5th Mar 2007
Reputation: -1.62846
E-Pigs: 162.3154
Offline
Post: #16
RE: Twitter - Anyone use it?
Mickey Wrote:
matchung Wrote:anyone know any php scripts can retrieve twitter contents then put on our own host?

twitter is quite slow response from my side..
http://twitter.com/matchung
What exactly do you want to retrieve? I can write up a quick script

Flatterd nice, just want to retrieve my twitter contents then put into a consolidated page, then i use it as my home page

Woo
06/05/2009 08:40 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Mickey
Down with MJ yo

Posts: 3,663.2843
Threads: 251
Joined: 26th Apr 2008
E-Pigs: 28.7300
Offline
Post: #17
RE: Twitter - Anyone use it?
What i used

PHP Code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<html>
<head>
<title></title>
<link href="style.css" rel="stylesheet" type="text/css" /> 
</head>

<body>
<?php
function twitter_status($twitter_id, $hyperlinks = true) {
    $c = curl_init();
    curl_setopt($c, CURLOPT_URL, "http://twitter.com/statuses/user_timeline/$twitter_id.xml?count=1");
    curl_setopt($c, CURLOPT_RETURNTRANSFER, 1);
    $src = curl_exec($c);
    curl_close($c);
    preg_match('/<text>(.*)<\/text>/', $src, $m);
    $status = htmlentities($m[1]);
    if( $hyperlinks ) $status = ereg_replace("[[:alpha:]]+://[^<>[:space:]]+[[:alnum:]/]", "<a href=\"\\0\">\\0</a>", $status);
    return($status);
}
?>

<?php
function twitter_time($twitter_id, $hyperlinks = true) {
    $c = curl_init();
    curl_setopt($c, CURLOPT_URL, "http://twitter.com/statuses/user_timeline/$twitter_id.xml?count=1");
    curl_setopt($c, CURLOPT_RETURNTRANSFER, 1);
    $src = curl_exec($c);
    curl_close($c);
    preg_match('/<created_at>(.*)<\/created_at>/', $src, $m);
    $status = htmlentities($m[1]);
    if( $hyperlinks ) $status = ereg_replace("[[:alpha:]]+://[^<>[:space:]]+[[:alnum:]/]", "<a href=\"\\0\">\\0</a>", $status);
    return($status);
}
?>

<div id="status">
<center>
<?php
echo twitter_status(twitter_id) ." on " .twitter_time(twitter_id);
?>
</center>
</div>
</body>
</html>


You'll need your twitter id, if you want more you can pull it from the xml

Example

by the way you'll need curl on the server enabled


[Image: MiCk3Y.jpg]

[Image: battle.png]

Spoiler for link:
(This post was last modified: 06/05/2009 08:44 PM by Mickey.)
06/05/2009 08:42 PM
Find all posts by this user Quote this message in a reply
matchung
Turok Makto

Posts: 1,744.2413
Threads: 180
Joined: 5th Mar 2007
Reputation: -1.62846
E-Pigs: 162.3154
Offline
Post: #18
RE: Twitter - Anyone use it?
yes, but any nice UI provide? thanks

Woo
06/05/2009 08:54 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Mickey
Down with MJ yo

Posts: 3,663.2843
Threads: 251
Joined: 26th Apr 2008
E-Pigs: 28.7300
Offline
Post: #19
RE: Twitter - Anyone use it?
matchung Wrote:yes, but any nice UI provide? thanks

UI will have to be done in css, and i fail at that :(

[Image: MiCk3Y.jpg]

[Image: battle.png]

Spoiler for link:
06/05/2009 08:55 PM
Find all posts by this user Quote this message in a reply
matchung
Turok Makto

Posts: 1,744.2413
Threads: 180
Joined: 5th Mar 2007
Reputation: -1.62846
E-Pigs: 162.3154
Offline
Post: #20
RE: Twitter - Anyone use it?
Mickey Wrote:
matchung Wrote:yes, but any nice UI provide? thanks

UI will have to be done in css, and i fail at that :(

Sadist im noob too

Woo
06/05/2009 08:56 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)

 Quick Theme: