I have 3 variables holding 3 different values(managed from admin).
$tab_download_pos = 2;
$tab_download_title = "Download";
$tab_overview_pos = 1;
$tab_overview_title = "Overview";
$tab_faq_pos = 3;
$tab_faq_title = "FAQ";
Now I have 3 tabs and I would like to sort the tabs based on the values from above variables.
The three tabs are
1.Overview
2.Download
3.Faq
I started in this way
$tab_arr = sort(array($tab_download_pos,$tab_overview_pos,$tab_faq_pos));
I did foreach loop but then I am lost. I would like to sort the tabs based on the values from the variables which I am getting from backend.
Any help is highly appreciated. Thanks in advance.
Aucun commentaire:
Enregistrer un commentaire