title: Laravel 4 REST API join table
body: <p>I'm trying to make a REST API using laravel 4 and I'm trying to join 3 table to get the data but when I check the url in postman it shows html page that says </p>
  
  <pre><code>&lt;title&gt;Whoops! There was an error.&lt;/title&gt; 
  </code></pre>
  
  <p>but when i check it using sql query it returns 2 data.</p>
  
  <p>Here is the UrlController</p>
  
  <pre><code>public function tayang($idKota)
  {
      $tayang=DB::table('detiltayang')
      -&gt;join('tayang','detiltayang.idTayang','=','tayang.idTayang')
      -&gt;join('bioskop','tayang.idBioskop','=','bioskop.idBioskop')
      -&gt;join('film','tayang.idFilm','=','film.idFilm')
      -&gt;where('bioskop.idKota','=',$idKota);
  
      return Response::json($tayang);
  }
  </code></pre>
  
  <p>Route</p>
  
  <pre><code>Route::get('api/{idKota}/tayang','UrlController@tayang')
  </code></pre>
  
  <p>Can anyone tell me how to join table in rest api? thanks in advance</p>