mentions_timeline on my website



I try to put the mentions on my website with JS librarie jsOAuth-1.3.6.min.js.
When I do this

oauth = OAuth(options);
oauth.get("", success, error);

function success(data){

var items = [];
$.each(data, function(key, val) {
	items.push('<li id="' + key + '">' + val + '</li>');

$('<ul/>', {
	'class': 'my-new-list',
	html: items.join('')

function error(data) {
	alert("something failed");

I have this in my div #test

<ul class="my-new-list">
<li id="text"></li>
<li id="xml"></li>
<li id="requestHeaders">objectObject</li>
<li id="responseHeaders">objectObject</li>

My question is how can I do to have this json :

Thank you


Your mentions timeline is a feed built for your eyes only. If you’re going to display those tweets on a public website, it’s your responsibility to insure that you’re maintaining user privacy by not displaying tweets authored by protected users.

API v1.1 requires OAuth 1.0A, which prevents you from using it in a pure client-side Javascript environment like this.


Thank you for your response.

My developpement is for my website administration. Nobody else can see it.

So if I can’t use Javascript for my authentification, what kind of language I should use ?


Most server-side languages have OAuth libraries available. I would recommend tmhOAuth for PHP if you’re already familiar with PHP.


Ok thank you.
Have a good day !


Another question.
Is it possible to use classic ASP ?


Yes – Feel free to use my ASPTwitter class as a starting point. The code already does OAuth authentication and gets tweets, and works with Twitter API 1.1:


please I want to show the mentions from people that show on my timeline
to feed it on my website
this code is right??
and then how to print Valuse??


$consumerkey = “”;
$consumersecret = “”;
$accesstoken = “”;
$accesstokensecret = “”;
function getConnectionWithAccessToken($cons_key, $cons_secret, $oauth_token, $oauth_token_secret) {
$connection = new TwitterOAuth($cons_key, $cons_secret, $oauth_token, $oauth_token_secret);
return $connection;

$connection = getConnectionWithAccessToken($consumerkey, $consumersecret, $accesstoken, $accesstokensecret);

$search = str_replace("#", “%23”, $search);
$tweets = $connection->get(“"+$search+"&src=typd&result_type=mixed&count=4”);

echo json_encode($tweets);


I would first recommend that you use [node:10248]. Create a search query for “to:screen_name” and then embed the resultant widget on your site.

If you want to take this server-side approach, make sure you’re using the latest version of twitteroauth. You want to use the [node:10287] API method from API v1.1. (You’re using the users/search method from API v1 in this example code, an API version that is now retired).


thanx mr @episod … I dont want to use Embed method because I want to use different design.
I want use API method from API 1.1
but I didnt know how I can use it

first I should be use this URL:
what then??
I want ready example to edit and use it.
if I use this code

what the commend to print the request??
echo xxx;


Keep in mind that if you want to use your own design, you’ll still need to make it compliant with [node:142].

I would recommend that you explore the object that you get back after a successful request. Generally the object structure gets translated into a hash of some kind, and then you iterate through elements in a collection.

In the Search API, the tweets you’re looking for are in an array within the “statuses” node of the response hash. Each element of that array is tweet – [node:7286] gives you info on the fields within a tweet. Some you’ll want to use for display, some you won’t.