title: pagination with the Angellist API
body: <p>I am a little stuck on how to show the Angellist API records on the page with pagination.</p>
  
  <p>I succesfully got the first 50 records of the Angellist API showing on the page. When i change the number of $page to 2 and print $data, i do get the 50 records of page 2.
  But now i don't know how i can do that automatically so i can get the pagination going.</p>
  
  <p>This is the code i have until now:</p>
  
  <pre><code>&lt;?php
  $page = isset($_GET['page']) ?  (int)$_GET['page'] : 1;
  $jsonurl = 'https://api.angel.co/1/jobs/?page=' . $page;
  $url = file_get_contents($jsonurl);
  $data = json_decode($url,true); 
  $total = $data['total'];
  $per_page = $data['per_page'];
  $current = $data['page'];
  $last_page = $data['last_page'];
  ?&gt;
  &lt;div class="col-md-12" style="padding:0;"&gt;
      &lt;div class="col-md-6"&gt;
          &lt;div class="pagination"&gt;
              &lt;?php 
                  $i = 0;
                  while($page &lt; $last_page) :?&gt;               
                      &lt;?php echo "&lt;a href=\"/jobs?page=".$page++."\"\&gt;Next 50&lt;/a&gt;";                                       
                  endwhile;
  
              ?&gt;
          &lt;/div&gt;
      &lt;/div&gt;
  </code></pre>
  
  <p>I hope this is sufficient information for some help, but if you need more info i'm happy to give it.</p>