Link to home
Start Free TrialLog in
Avatar of Mark Harris
Mark HarrisFlag for United States of America

asked on

Keywords from Joomla Category....sheesh!

Hi,

I'm  using Joomla (2.5)

I have a Joomla plugin that will serve ads based on the keywords in the source.  I am using a directory component that utilizes Joomla's CORE CATEGORIES and ARTICLES as the directory tree structure..

Within the CORE Joomla you can add keywords to the source at the GLOBAL SITE CONFIG level; and at the ARTICLE level.  All you have to do is fill in the provided META fields and you are set.

Even though the CATEGORY level has the same META fields, the Developers decided that only way CATEGORY's can generate keywords from the META fields is if you publish a menu item for them......(Who develops like that?)

So, I need a custom script that I can place in the head of my template or use as an include that will pull the META DATA from which ever CATEGORY Page is being viewed and places it in the source...i.e. <meta name="keywords" content="keyword1, keyword2...

I thought this was a no brainer and I thought there might be an extension that does this but I cant find one..

Any assistance with the code would be much appreciated.

Thanks
Avatar of Brian Utterback
Brian Utterback
Flag of United States of America image

I am a little confused. Are you saying that you can get article keywords into the source, but not category keywords, unless the category is set via following a menu item? Can you give me a concrete example of what you want to see?

As to your answer about who would develope like that, Joomla is very menu oriented. It is not surprising to me that the category keywords are set when you are following a menu item.
Avatar of Mark Harris

ASKER

I am suppressing the Article Keywords by not using them at all.  I am not using the Site Keywords either.

The directory component I use "Reviewsforjoomla" (JReviews), uses the native category structure as the directory tree. So if I create a Cats named "Activities", "Clothing" etc, each with subcategories, JReviews uses them as the Directory it displays.  Each listing is an actual article.  The template that comes with the component configs everything like a true directory.  The problem is that it "skirts" the Menu Item requirement for Keywords at the Category level.

Activities
  |
   Bowling
  |     {articles}
  |
   Golf
  |      |
  |       Mini Golf
  |      |       {articles}
  |      |
  |       Driving Ranges
  |      |       {articles}
  |      |
  |       Courses
  |               {articles}
  |
    Skating
           {articles}


I intend to put keywords only in the Category Meta Keyword fields and display only those.  I need a script that will get the Meta Keywords of the current Category I am in and append it to the meta name tag.
Avatar of Member_5340450
Member_5340450

If you do a menu type of category blog, the category meta keywords will display.

Exactly what type of menu are you using?
I won't be using a menu.
Create a hidden menu and make a menu for the form from that. You'll need some kind of link to make the component appear.
ASKER CERTIFIED SOLUTION
Avatar of lenamtl
lenamtl
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks lenamtl. I will try that.