I am using the php framework codeigniter.
I am attempting to create a here is an example:
animals/feline/lionanimals/feline/tigeranimals/feline/snow-leopardanimals/canine/wolfanimals/canine/coyote
Where both genus (feline) and species (lion) are both retrieved from a database and animals is a controller. I have models that place genus and species in their respective arrays. I also wish to have views for each step along the breadcrumb as follows:
animalsanimals/felineanimals/canine
Any help would be greatly appreciated. I just looked at autocrumb and all it was as for displaying the breadcrumb control structure on the view, and not what I want.
I’d use URi routing., as another approach than
__remap(), which is better, but I just wanted to give another choiceIn you animals controller you have
view breadcrumb.php:
View folder contains:
Is this what you were looking for?
EDIT after comments:
SO looks like we’ve mistaken what you wanted. If you’re retrieving those variables from DB, then you could do like this:
In your view genus.php (in folder animal):
In your view genusspecies.php (in folder animal):
all those might be html snippets you load from database;
Your routing might look like this then:
If I were you, I’ll go about this way. Do I got it better or am I still wrong somewhere?