Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Dynamic timeline selection for embedded timelines - Hashtag Timeline

Tags:

I've followed the guide here to add multiple widgets using the same widget id and this works perfectly fine for User timeline.

Snippet ----

<a class="twitter-timeline" href="https://twitter.com/benward" data-widget-id="[id]" data-screen-name="benward">
<a class="twitter-timeline" href="https://twitter.com/endform" data-widget-id="[id]" data-screen-name="endform">
<a class="twitter-timeline" href="https://twitter.com/kang" data-widget-id="[id]" data-screen-name="kang">
<a class="twitter-timeline" href="https://twitter.com/brianellin" data-widget-id="[id]" data-screen-name="brianellin">

What I would want to do is do the same( show different widgets ) for multiple hashtags - #MH17, #MH370 on the same page. But these tags change for each article on a page.

I want to know if either of these is possible.

  1. Can I make the same guide available for a search query to this and this without creating a widget manually from the Twitter page. Timeline changes when I change the "data-screen-name" property. Is there something like "data-hashtag-name"?
  2. Is it possible to use Twitter API or something to automate the process of creating a widget from the browser using Auth Token - Secret?
like image 923
Vivek Sampara Avatar asked Aug 22 '14 12:08

Vivek Sampara


1 Answers

May be this help you . Here i am sending you some example using this I am get json and render html div

enter image description here

Here is a sample code and demo you can use for search in twitter

1) http://www.codexworld.com/create-custom-twitter-widget-using-php/

2)you can also look into this examle may be this will full fill your requirement . http://dev.kim-maida.com/twitter/

3) here is demo code and code sample link. https://github.com/kmaida/twitter-timeline-php

like image 146
Neha Thakur Avatar answered Sep 24 '22 19:09

Neha Thakur