lundi 27 novembre 2017

Laravel 5 How to populate same view multiple times with different data and cycle between pages

I am quite new to Laravel and I'm trying to build a small application that uses nested views (something like shown below)

enter image description here

To explain, I have an array of $categories which can vary in quantity. Each $category contains a different number of $questions. I want to create a page of $questions for each $category using the same view (so each $category on a new page).

I want to start with a summary page and be able to cycle Next and Back from each page (except for the first and last pages).

I have created my controller that currently returns me $categories and $questions and I have fed them into a view. I just don't know how to split them up by $category and cycle through the same view.



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/2AhtRvq
via IFTTT

Aucun commentaire:

Enregistrer un commentaire