Solved

Keywords from Joomla Category....sheesh!

Posted on 2013-01-29
8
240 Views
Last Modified: 2013-05-15
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
0
Comment
Question by:Mark Harris
8 Comments
 
LVL 22

Expert Comment

by:blu
Comment Utility
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.
0
 

Author Comment

by:Mark Harris
Comment Utility
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.
0
 
LVL 13

Expert Comment

by:joomla_php
Comment Utility
If you do a menu type of category blog, the category meta keywords will display.

Exactly what type of menu are you using?
0
Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

 

Author Comment

by:Mark Harris
Comment Utility
I won't be using a menu.
0
 
LVL 13

Expert Comment

by:joomla_php
Comment Utility
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.
0
 
LVL 24

Accepted Solution

by:
lenamtl earned 500 total points
Comment Utility
0
 

Author Comment

by:Mark Harris
Comment Utility
Thanks lenamtl. I will try that.
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

These days socially coordinated efforts have turned into a critical requirement for enterprises.
Since pre-biblical times, humans have sought ways to keep secrets, and share the secrets selectively.  This article explores the ways PHP can be used to hide and encrypt information.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now