Advertisement
Guest User

Untitled

a guest
Sep 25th, 2016
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.57 KB | None | 0 0
  1. ErrorException in dbda158712a631f22ffd888cd244c74e60f3a433.php line 51:
  2. Undefined variable: albums (View: /var/www/clients/client2/web2/web/resources/views/album.blade.php)
  3.  
  4. @foreach($albums as $others)
  5. <option value="{{$others->id}}">{{$others->name}}</option>
  6. @endforeach
  7.  
  8. public function getAlbum($id)
  9. {
  10. $album = Album::with('Photos')->find($id);
  11. return View::make('album')
  12. ->with('album',$album);
  13. }
  14.  
  15. public function getList()
  16. {
  17. $albums = Album::with('Photos')->get();
  18. return View::make('index')
  19. ->with('albums',$albums);
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement