看网上有很多无限分类方式,想做一个购物网站,需要很多子类,不知道用哪种最好?

WBOY
Release: 2016-06-23 14:26:57
Original
745 people have browsed it

无限分类 哪种最好

rt;请大家帮忙介绍一下,递归肯定不用 我看还有数组无限分类法 还有嵌套集合模型,用那个好,顺便贴出来个教程 谢谢咯

回复讨论(解决方案)

利用PHP的模板

我的想是,可以用前端来做。用php把mysql所有整个分类表读取出来存放到html的某个记忆体,再去循环。
用Jquery 的ajax获取,再去做无限级分类。

Util = {   'Data':''};Util.PostJSON = function (URL) {    $.ajax({ type: "POST", url: URL, dataType: "JSON", data: d,        success: function (d) {            return d;                    }, error: function (d) { console.log(d); if (typeof e == 'function') e(d); }    });}$(function(){   Util.Data = Util.PostJSON('http://www.abc.com/api.php?c=Category&a=List');});
Copy after login

参考
http://blog.csdn.net/zy205817/article/details/14230853

参考
http://blog.csdn.net/zy205817/article/details/14230853
已用你的方法解决 谢谢

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!