I use the thinkphp developed, navigation solutions, products and services are a class classification, environmental protection is a class two classification. Level two category below is a list of articles.
I loop through two cycles through the recursive multidimensional array method to cycle through the first class and the two level classification. The question now is how to get a list of the articles under level two classification?
Use
admin\model\category; $cate =m (' Cate ')->order (' sort ')->select (); Import ("Admin.Model.Category"); $cate =category::unlimitedforlayer ($cate);//multidimensional array reading infinite pole classification
- {$v. Name}
{$value. Name}
Reply content:
I use the thinkphp developed, navigation solutions, products and services are a class classification, environmental protection is a class two classification. Level two category below is a list of articles.
I loop through two cycles through the recursive multidimensional array method to cycle through the first class and the two level classification. The question now is how to get a list of the articles under level two classification?
use admin\model\category; $cate =m (' Cate ')->order (' sort ')->select (); Import ("Admin.Model.Category"); $cate =category::unlimitedforlayer ($cate);//multidimensional array reading infinite pole classification
- {$v. Name}
{$value. Name}
In PHP once again based on the list ID, query the corresponding article data!