Welcome to the MetaMod and Chameleon Support Forums.

Before posting, please check out the FAQs.

helpme

 

Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.

 

[solved] Assigning to flexicontent categories

[solved] Assigning to flexicontent categories

Hi

Thanks for this great and promising component, I purchased the chameleon and installed in one of my sites.

I use flexicontent and flexicontent uses joomla categories. I created three rules , selected certain categories (and some menus) and in the success actions I chose the suitable style for my rule.

But it seems not working, simply nothing works, only my assigned pages in the joomla template manager works.
I use joomla 2.5.19 , sh404sef , flexicontent

ANY help would be greatly appreciated.
Regards
Thanks

magj
Beginner Modder
ranks
useravatar
Offline
7 Posts
Administrator has disabled public posting

Re: [solved] Assigning to flexicontent categories

Hi,

Flexicontent may use the same categories, but it seems likely that the page detection is going to work differently (e.g. if com_flexicontent is involved) which may upset the internal workings of Chameleon. e.g. before trying to determine the category of an article, it checks to see if it's on an article page. If it's a flexicontent page then chances are that test will fail.

Could you please try the following in order to get some more info about Flexicontent that will help to identify the categories?

1 - download the free version of MetaMod from this site
2 - create a new MetaMod module, assign it to ALL pages and to a valid module position
3 - in the MetaMod, turn on "advanced debug" mode
4 - view some flexicontent pages e.g. articles and/or categories, and take a note of the output from the MetaMod for each page. This will give some important info including some PHP code that can help to put together the "recipe" for your situation
5 - paste the PHP code from each of the pages into a forum reply here, with a note of which type of page it was on.

Thanks,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3328 Posts
User info in posts
Administrator has disabled public posting

Re: [solved] Assigning to flexicontent categories

Hi

Thanks for your help, Sorry for my long delay, I didn't get the update email and somehow I got disappointed sad .  I hope chameleon could handle this type of assignment.
Thanks
Regards

I got this message in category page:

Code:


‫if (
$option == 'com_flexicontent'
and $view == 'category'
and $Itemid == '477'
and $jinput->get('isflexicontent') == 'yes' /*!*/
and $jinput->get('flexi_callview') == 'category' /*!*/
and $jinput->get('cid') == '79' /*!*/
and $jinput->get('format') == 'html' /*!*/
) return XXX; /* replace XXX with the module ID or position to display */


MetaMod debug info:
Module ID: 197
$option: com_flexicontent
$view: category
$id:
$Itemid: 616
$timezone: Tokyo//Japan
$language: en-us
$language_code: en
$language_region: us
Including modules

And in item page I get this:

Code:

(

$option == 'com_flexicontent'
and $view == 'item'
and $id == 'myalias'
and $Itemid == '596'
and $jinput->get('isflexicontent') == 'yes' /*!*/
and $jinput->get('flexi_callview') == 'item' /*!*/
and $jinput->get('loadcurrent') == '1' /*!*/
and $jinput->get('version') == '0' /*!*/
and $jinput->get('format') == 'html' /*!*/
) return XXX; /* replace XXX with the module ID or position to display */

.
MetaMod debug info:
Module ID: 197
$option: com_flexicontent
$view: item
$id: myalias
$Itemid: 616
$timezone: Tokyo/Japan
$language: en-us
$language_code: en
$language_region: us
Including modules

magj
Beginner Modder
ranks
useravatar
Offline
7 Posts
Administrator has disabled public posting

Re: [solved] Assigning to flexicontent categories

Hi,

It's going to be easy to get this working on Category pages, but I'll need a little more info to get things working on Item pages (where the item is in a particular category).

To detect Flexicontent category pages in Chameleon, you should be able to use this in the PHP section of the Chameleon rule (not in the Action section):

‫if (
  $option == 'com_flexicontent'
  and $view == 'category'
  and $jinput->get('isflexicontent') == 'yes'
  and $jinput->get('flexi_callview') == 'category'
  and $jinput->get('format') == 'html'
) return true;

To detect a particular category, e.g. category 79, use this:

‫if (
  $option == 'com_flexicontent'
  and $view == 'category'
  and $jinput->get('isflexicontent') == 'yes'
  and $jinput->get('flexi_callview') == 'category'
  and $jinput->get('cid') == '79'
  and $jinput->get('format') == 'html'
) return true;

Do you also wish to detect any Flexicontent articles that are in a particular category? If so, let me know and I'll look into that further. It will likely just require a simple database call.

Best regards,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3328 Posts
User info in posts
Administrator has disabled public posting

Re: [solved] Assigning to flexicontent categories

Hi,

Thank you very much for your help and prompt reply.  smile

Yes, Actually I need to assign 3 different templates each to some flexicontent categories. (i.e. template A to flexicontent category: 1,6,89,234,.... - template B to 2,4,5,66,... categories, and template C to 53,101,.... cats)

And template A will be the default template to unassigned , different components/pages.

Regards
Thanks again

magj
Beginner Modder
ranks
useravatar
Offline
7 Posts
Administrator has disabled public posting

Re: [solved] Assigning to flexicontent categories

Hi Magj,

when you talk about "categories" here, do you mean:

1 - category pages
or
2 - article pages, where the article is in those categories

or both?

Number (1) is easy. Number (2) would require some more investigation. Please let me know.

Thanks,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3328 Posts
User info in posts
Administrator has disabled public posting

Re: [solved] Assigning to flexicontent categories

Hi
Dear Stephen,
Thanks for your great support,

Yes, the answer is "Both",
I have three different root categories that have many sub categories and items, All of those pages including category pages and items in those categories should be assigned to three different Templates.

As you told I cannot see the category ids in the item debug code, How we may obtain this?

Any help would be greatly appreciated.
Thanks in advance,
Regards

magj
Beginner Modder
ranks
useravatar
Offline
7 Posts
Administrator has disabled public posting

Re: [solved] Assigning to flexicontent categories

Hi again Stephen,

Sorry for bumping, but is there any update on this feature support?

Thanks in advance
Regards

magj
Beginner Modder
ranks
useravatar
Offline
7 Posts
Administrator has disabled public posting

Re: [solved] Assigning to flexicontent categories

I am experiencing the same issue on my site. I only need to assign a template to single articles linked via menu based on category. I have tried linking menu, but that does not work as these are "sub-menus".

Basically, I need an update to your AWESOME component to handle flexicontent.

Thanks,

Trentin C Bergeron (TreChriron)
Bard, Dreamer & RPG Enthusiast
http://trechriron.me/

trechriron
Trentin C Bergeron
Beginner Modder
ranks
useravatar
Offline
9 Posts
User info in posts
Administrator has disabled public posting

Re: [solved] Assigning to flexicontent categories

I had to uninstall flexi-content as I need this more. :-(  Maybe the two teams could create a plug-in to sync up?

Trentin C Bergeron (TreChriron)
Bard, Dreamer & RPG Enthusiast
http://trechriron.me/

trechriron
Trentin C Bergeron
Beginner Modder
ranks
useravatar
Offline
9 Posts
User info in posts
Administrator has disabled public posting

Board Info

Board Stats:
 
Total Topics:
1686
Total Polls:
6
Total Posts:
5933
Total Posts Today:
7
User Info:
 
Total Users:
4432
Newest User:
kinggambling14
Members Online:
0
Guests Online:
151

Online: 
There are no members online

Forum Legend:

 Topic
 New
 Locked
 Sticky
 Active
 New/Active
 New/Locked
 New Sticky
 Locked/Active
 Active/Sticky
 Sticky/Locked
 Sticky/Active/Locked