I really don't know how to do it. I don't know which master is busy. I am so worried! Effect: -- table structure: arctypeCREATETABLEarctype (idsmallint (5) blocks, paridsmallint (5) unsignedNOTNULLdefault & #039; 0 & #039 ;...
I really don't know how to do it. I don't know which master is busy. I am so worried!
Effect:
-- Table structure
arctype
CREATE TABLEarctype
(
id
Smallint (5) unsigned not null auto_increment,
parid
Smallint (5) unsigned not null default '0 ',
typerank
Smallint (5) unsigned not null default '0 ',
typename
Char (15) not null,
typedir
Char (15) default NULL,
typetitle
Varchar (80) not null,
typekeyword
Varchar (120) not null,
typedescription
Varchar (150) not null,
Primary key (id
)
ENGINE = MyISAM default charset = utf8 AUTO_INCREMENT = 176;
INSERTarctype
VALUES (145, 0, 1, 'syntacay', 'yufa ', 'Online learning of German grammar', 'German grammar learning, online learning of German grammar, German grammar exercises, german syntax audio, German syntax video ',' we offer online learning of German syntax, the best website for learning German syntax ');
INSERTarctype
VALUES (164,145, 0, 'Usage of lattice ', 'ge', 'Usage of German lattice, online learning of usage of German lattice, getting started with usage of German lattice, usage video of German lattice, usage audio of German lattice, usage of German lattice, online learning of usage of German lattice, Introduction to usage of German lattice, usage video of German lattice, the usage audios for German cells, 'the online learning for usage of German cells, the best learning website for usage of German cells ');
INSERTarctype
VALUES (165,164, 0, 'yige', 'yige', 'Usage of German Lattice-one online learn', one German grid, one German grid, and one German Grid, video with one grid in German and audio with one grid in German. 'The online learning with one grid in German and the best learning website with one grid in German ');
INSERTarctype
VALUES (166,164, 0, '2', 'erge', 'Usage of German Lattice-L2 online learn', 'German L2, and German L2 online learnings, getting started with a German two-cell, German two-cell video, German two-cell audios, 'the online learning of German two-cell syntax, the best learning website for German two-cell syntax ');
INSERTarctype
VALUES, german three-cell video, German three-cell audio, 'the online learning of German three-cell syntax is available, and the best website for learning German three-cell syntax ');
INSERTarctype
VALUES (168,164, 0, '4ge', 'sige', 'Usage of German Lattice-four online learn', 'German 4ge', German 4ge', and getting started, video of German four cells, audio of German four cells, 'the online learning of German four-cell syntax is available, and the best website for learning German four-cell syntax ');
Please do not simply write JavaScript code and use ajax or js to loop. I also know that I am not very familiar with ajax and js! So please help me write it down. Thank you again!
Reply content:
I really don't know how to do it. I don't know which master is busy. I am so worried!
Effect:
-- Table structure
arctype
CREATE TABLEarctype
(
id
Smallint (5) unsigned not null auto_increment,
parid
Smallint (5) unsigned not null default '0 ',
typerank
Smallint (5) unsigned not null default '0 ',
typename
Char (15) not null,
typedir
Char (15) default NULL,
typetitle
Varchar (80) not null,
typekeyword
Varchar (120) not null,
typedescription
Varchar (150) not null,
Primary key (id
)
ENGINE = MyISAM default charset = utf8 AUTO_INCREMENT = 176;
INSERTarctype
VALUES (145, 0, 1, 'syntacay', 'yufa ', 'Online learning of German grammar', 'German grammar learning, online learning of German grammar, German grammar exercises, german syntax audio, German syntax video ',' we offer online learning of German syntax, the best website for learning German syntax ');
INSERTarctype
VALUES (164,145, 0, 'Usage of lattice ', 'ge', 'Usage of German lattice, online learning of usage of German lattice, getting started with usage of German lattice, usage video of German lattice, usage audio of German lattice, usage of German lattice, online learning of usage of German lattice, Introduction to usage of German lattice, usage video of German lattice, the usage audios for German cells, 'the online learning for usage of German cells, the best learning website for usage of German cells ');
INSERTarctype
VALUES (165,164, 0, 'yige', 'yige', 'Usage of German Lattice-one online learn', one German grid, one German grid, and one German Grid, video with one grid in German and audio with one grid in German. 'The online learning with one grid in German and the best learning website with one grid in German ');
INSERTarctype
VALUES (166,164, 0, '2', 'erge', 'Usage of German Lattice-L2 online learn', 'German L2, and German L2 online learnings, getting started with a German two-cell, German two-cell video, German two-cell audios, 'the online learning of German two-cell syntax, the best learning website for German two-cell syntax ');
INSERTarctype
VALUES, german three-cell video, German three-cell audio, 'the online learning of German three-cell syntax is available, and the best website for learning German three-cell syntax ');
INSERTarctype
VALUES (168,164, 0, '4ge', 'sige', 'Usage of German Lattice-four online learn', 'German 4ge', German 4ge', and getting started, video of German four cells, audio of German four cells, 'the online learning of German four-cell syntax is available, and the best website for learning German four-cell syntax ');
Please do not simply write JavaScript code and use ajax or js to loop. I also know that I am not very familiar with ajax and js! So please help me write it down. Thank you again!
Do unlimited classification directly. What is Level 3 navigation.
Unlimited classification is currently implemented in many ways.
I generally create an unlimited category directly. All the SQL statements are displayed. What you want.
Sorry. Didn't look at your code at first. Not that difficult.
Read your database table. Basically, an ID field is designed very old. Then there is a PID field. Then, set the value based on the same PID! This is the idea, right.
There are many practices. If you cannot query the database cyclically, submit the table. Join itself multiple times to produce results.
If you are in trouble. Multiple queries. Check all the children each time. Then query it cyclically! Ajax is basically the same idea. However, I do not like this database design method very much.
We recommend that you search for the adjacent list model.
And nested set model. About 10 years ago! These problems are no longer a problem. The first adjacency list you use is the simplest method. The advantage is insertion. Update. Easy to delete. Confirm the query. Of course. If you are interested, you can search for the martieral path. And more complex matrix encoding. These models are very mature in the implementation of unlimited classification. Let's look back at the author's questions. Maybe. You will. Wow. It turns out to be so simple.
For more information, see the code ~
PHP simple implementation of infinitus Classification