Créer un champ qui pointe vers une catégorie

More
11 years 11 months ago #31779 by ggppdk
You are welcome, your question became an article in our FAQ ;) !!

FLEXIcontent is a free open Source project, (we will be adding donation soon), which we have spent a big amount of our time developing and supporting (bugs and common questions, and important features (of course free custom development is not possible) )

Please consider leaving a good review in JED if you have not done already

Regards


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

More
11 years 11 months ago #31781 by eytanpierre
Just one more question.

How can I choose which parent categorie for the field ?
Now the parent categorie is ROOT so in the field there are all categorie of my website, and I'd like only all sub-categories of mycategorie.
I didn't test already this field with the advanced search ... but I will.

Thank you (again) for your work !

Please Log in or Create an account to join the conversation.

More
11 years 11 months ago #31786 by ggppdk
You can do it like this:
Code:
SELECT id as value, CONCAT(REPEAT('-',level),' ',title) as text FROM `#__categories` WHERE level>0 AND extension='com_content' AND id > (SELECT lft FROM `#__categories` WHERE id=555) AND id < (SELECT rgt FROM `#__categories` WHERE id=555) ORDER BY lft

in the above query replace 555 with the id of your top level 'mycategorie'


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

More
11 years 11 months ago #31792 by eytanpierre
It's working ! Thank you very much !!! :D :D :D

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.466 seconds
Save
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline