×
Pleas keep in mind that SPAM will be deleted instantly
explode row with php
- sbitlis.gmail
- Topic Author
- Offline
Less
More
- Posts: 4
- Thank you received: 0
9 years 6 months ago #3050
by sbitlis.gmail
explode row with php was created by sbitlis.gmail
Congratulations about your great component.
In my database my main table have a row which contains the categories that records belong.
One record can be in three categories maximum and the structure of the row is [catId1,catId2,catId3]
The categories are in different table.
I want to create menu in Joomla for each of the category and to display only the specific records that contains the specific category id.
In php i could do this with the explode command.
I dont know how to do this with JoomDB.
Can you help solve my problem?
In my database my main table have a row which contains the categories that records belong.
One record can be in three categories maximum and the structure of the row is [catId1,catId2,catId3]
The categories are in different table.
I want to create menu in Joomla for each of the category and to display only the specific records that contains the specific category id.
In php i could do this with the explode command.
I dont know how to do this with JoomDB.
Can you help solve my problem?
Please Log in to join the conversation.
- Dirk
- Offline
Less
More
- Posts: 1222
- Thank you received: 225
9 years 6 months ago - 9 years 6 months ago #3053
by Dirk
For relational databases (multiple connected tables you need the pro version).
But to be honest i don't know what you mean with explode. I guess the normal version will do the job.
There is a help topic about this in the forum
how-to-realize-a-catalog-with-categories.html
BTW: There is an SQL-Select param option for the catalog view!
Replied by Dirk on topic explode row with php
sbitlis.gmail wrote: The categories are in different table.
For relational databases (multiple connected tables you need the pro version).
But to be honest i don't know what you mean with explode. I guess the normal version will do the job.
There is a help topic about this in the forum
how-to-realize-a-catalog-with-categories.html
Seems to be unnecessary complicate and inflexible. Can you please provide the SQL-Structure?sbitlis.gmail wrote: catId1,catId2,catId3
BTW: There is an SQL-Select param option for the catalog view!
Last edit: 9 years 6 months ago by Dirk.
Please Log in to join the conversation.
- sbitlis.gmail
- Topic Author
- Offline
Less
More
- Posts: 4
- Thank you received: 0
9 years 6 months ago - 9 years 6 months ago #3054
by sbitlis.gmail
Replied by sbitlis.gmail on topic explode row with php
I have bought the pro version.
I attach the db structure.
Sorry for my bad english when i said "The categories are in different table"
i mean i save the catid in the main table and connect them with categories table via id field.
The categories field contains only the catid's with spaces between ids.
explode is a php command that break the string in to array which is separated with a specific separator.
I want in first menu to show the category with id 1 in second menu with id 2 etc.
Actually the mysql command WHERE and LIKE will work great but i understand from the examples how to perfom it inside catalog-Template so to work. Can you give a better example?
Thank you very much for your quick answer.
I attach the db structure.
Sorry for my bad english when i said "The categories are in different table"
i mean i save the catid in the main table and connect them with categories table via id field.
The categories field contains only the catid's with spaces between ids.
explode is a php command that break the string in to array which is separated with a specific separator.
I want in first menu to show the category with id 1 in second menu with id 2 etc.
Actually the mysql command WHERE and LIKE will work great but i understand from the examples how to perfom it inside catalog-Template so to work. Can you give a better example?
Thank you very much for your quick answer.
Last edit: 9 years 6 months ago by sbitlis.gmail. Reason: add file
Please Log in to join the conversation.
Moderators: Dirk, joest