title: Prev and Next with array
body: <p>I create script with foreach loop which give all items, anyone know how could make to display one item on page and when someone click on next arrow to display next tweet or when click prev to show prev tweet?</p>
  
  <p>Here is code:</p>
  
  <pre><code>&lt;?php include "tw/twitteroauth.php"; ?&gt;
  &lt;?php
      $consumer = "";
      $consumersecret = "";
      $accesstoken = "";
      $accesstokensecret = "";
  
      $twitter = new TwitterOAuth($consumer, $consumersecret,$accesstoken, $accesstokensecret);
  
      ?&gt;
  &lt;html&gt;
  &lt;head&gt;
  
  &lt;title&gt;Tw&lt;/title&gt;
        &lt;meta charset="utf-8" /&gt;
  
  &lt;/head&gt;
  &lt;body&gt;
  
  &lt;?php
  
  $tweets = $twitter -&gt; get('https://api.twitter.com/1.1/statuses/user_timeline.json?screen_name=MiDizajn&amp;count=100');
  foreach($tweets as $tweet){
  
         print_r($tweet -&gt; text.'&lt;br /&gt;&lt;br /&gt;');
  
  }
  
  
  ?&gt;
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Here is result:</p>
  
  <pre><code>Donec mauris leo, ultricies at nulla euismod, facilisis dapibus quam. Maecenas pharetra eros non dolor bibendum http://t.co/dZuDAW37pT...
  
  proba neka
  
  Win a brand new HTPC worth over 1400 Euro http://t.co/b70wypaQbo
  
  I just joined @SteelSeries Christmas Illuminated contest to win a Dota 2 Mouse Bundle. You can too: http://t.co/NJxOJk6fyX
  
  Ive just entered to win an Asus R9 280X Matrix Platinum thanks to OC3D! http://t.co/azbdOFmWIF
  
  I just got a code for free Gems in the Settlers Online: @CastleEmpire http://t.co/JKLdoMQlU9
  
  #darkside40
  
  RT @d3expert: Follow us + retweet for a chance to win 1x Book of Cain and 1x Diablo 2013 Wall Calendar EU only. More giveaways: http://t ...
  
  @palicomp are giving away an @amdradeon 7950HD Graphics Card!! Answer a question on facebook to enter! http://t.co/Yzhia6W1 #palicomp #amd
  
  @goran_jovanovic http://t.co/iO1VZu6R
  
  Win a PNY GeForce GTX 650Ti http://t.co/gft1TKWM
  
  Winpics [20] http://t.co/z7uQaBrG via @ftw_nl
  
  Corsair Vengeance Gaming Bundle Giveaway: http://t.co/y0Aqr74D
  
  just requested a beta invite @koding, a new way for developers to work! http://t.co/n5cQZmpr
  
  RT @POPodcast: Retweet for a chance to win Kingdom Rush HD from @ArmorGames! Mike is addicted and feeling generous! You have one hour to ...
  
  @1v4nB Hvala!!!
  
  @rain_wind_storm pogledaj nase radove od ranije na http://t.co/ezwp5LiS
  
  @goran_jovanovic http://t.co/ggMUkCfd
  
  @goran_jovanovic http://t.co/no8lrtae
  
  Enter to win a #GIGABYTE G1.Assassin2 motherboard w/ @futurelooks @MEGATechNews @eSportsCN ! http://t.co/iZ5pyZYn
  
  Follow @massluminosity on Twitter for the best #gamer #giveaways
  
  http://t.co/kNLLbGWX
  
  BARinfo - Šobić, Sklonište, Dado, Hanka, Laboratorija... u Baru http://t.co/gNG0B0d5
  
  RT @D_eSports: Who wants to win a @ZOWIEGEAR MiCO? Retweet this message and follow @D_eSports and @ZOWIEGEAR to enter the competition! # ...
  
  http://t.co/RACqraCP
  
  RT @IvanSimoSimic: @goran_jovanovic Evo rjeshenja! http://t.co/O7U4WX0V
  
  Ivy Bridge proven to suffer from poor thermal grease by http://t.co/aZgRZZds http://t.co/kYIBQ6r8 via @VRZone
  
  http://t.co/73Agsa9N
  
  RT @goran_jovanovic: http://t.co/Xl5KdprA
  
  RT @BARinfo_me: NOVO!!!!! http://t.co/5PuGxJss http://t.co/FObQHl7e
  
  Blic Online | EU neće ratifikovati sporazum Akta http://t.co/mUeZKQxV via @Blic_online
  
  RT @BARinfo_me: Uskoro nešto novo...
  
  RT @D3Sanc: We must fight harder! Don't let #D2 lose with 49% of the votes!!! http://t.co/EDKu0yqG
  
  Help me win a #Diablo3 Beta Key! http://t.co/YOnHgpjD
  
  I just entered to win a #Diablo3 Beta Key – follow @wowjuju and visit http://t.co/DtT0fD5h to enter the contest.
  
  RT @d3expert: Round 5 of 5 of the Giveaway! Follow us + Retweet and have a chance of winning 5 Beta Keys.Winners, Rules and Details: htt ...
  
  @Mare085Marko yummy :)
  
  Hachitosh alive!!!
  
  I just signed up for the Guild Wars 2 beta. Join the revolution! http://t.co/WVAQcqDE #GW2 #guildwars2 via @GuildWars2
  
  RT @YourAnonNews: TANGO DOWN - Interpol main http://t.co/tmhiBKCj (via @blackTuesdayHG) #Anonymous #ActAgainstACTA
  
  Intel 'Ivy Bridge' desktop chip prices leak - TechSpot News http://t.co/O3cg7f2i via @techspot
  
  RT @YourAnonNews: I can't wait to someday tell my kids that their grandparents are older than the modern Internet. That won't blow their ...
  
  RT @YourAnonNews: Love all. Trust few. Always paddle your own canoe. ツ
  
  RT @YourAnonNews: ACTA is falling apart in Europe | GET INVOLVED and ACT AGAINST ACTA - Here's How: http://t.co/ImybhSoj
  
  RT @YourAnonNews: #Anonymous. We are beyond common definitions. We are the movement, progression and realisation of an idea whose time h ...
  
  RT @YourAnonNews: BREAKING: UK Seizes &amp; Shuts Down Popular Music Blog RnBXclusive, Arrest Operators and Threaten Readers for Piracy | ht ...
  
  RT @Blic_online: #svet Hakeri "Anonimusi" srušili sajt Interpola http://t.co/G9NmQ8Kz
  
  ASrock Competition less than 30min left!!! http://t.co/zeChpmlW
  
  New version of GPUz. http://t.co/ONbMqYCQ
  
  Fresh from kitchen :) http://t.co/I0gmFdWw
  
  Big changes to Diablo 3 detailed, more to come • News • http://t.co/6RsZneLV http://t.co/TiAElt7V
  
  I support #wikipediablackout! Show your support here http://t.co/o2C0wUYb
  
  14 Days Christmas Giveaway http://t.co/HR87Nuou
  
  18 hours of overclocking
  
  http://t.co/zTIkGWqc via @vijestime
  
  http://t.co/sylX7wsV via @vijestime
  
  Blic Online | Pogledajte kako su izgledale prve verzije "Gugla", Fejsbuka, Jutjuba... http://t.co/n6xWKl6G via @Blic_online
  
  http://t.co/ezwtDls2
  
  hmm
  </code></pre>