This plugin allows keywords to be included with your items and enables things so that the keywords can be displayed as a meta tag in the HTML <HEAD> section. If you use <%Keywords(3)%> inside templates, it will produce keyword-based “see also” links. Number is how many links to produce for each of keywords.

General Plugin info
Author: Authors: v0.1 - TerryChay,
latest version - AlexanderGagin
Current Version: 0.40
Code: NP_Keywords Code
Demo: -
Forum Thread: -


NP_Keywords plugin allows you to add keywords to your new or updated journal items. Keywords separated by commas are treated as separate keywords. There are two applications for keywords.

  • First, they are applied to generate meta-tag information in the <HEAD> section of Archive and Item skins. For instance, add the following on the Archive skin…
    <meta name="keywords" content="<%Keywords%>">

    right after the line

    <meta name="description" content="<%blogsetting(desc)%>" />

    and it will add all the keywords bound to that item as a meta tag.

  • Second, you can have links to other items with same keywords. For this purpose,one should place plugin call inside one of page templates fields (notice the difference between skin html-files and structured template fields). In this case you should give number of links for each keyword in parenthesis:
    See also:<br/><%Keywords(3)%>

To add keywords, simply add or update a journal item. You will see an extra field called “Keywords” in the Plugins (Extended for Bookmarklets) section. Add a comma separated list of keywords.

Developer Notes

Terry allowed me to take work over and to improve his plugin. I made it work with Nucleus 3.0 and added seealso-links functionality. Meanwhile I'm not really a progammer so my code may still be bogus. First I've tried not to change this page as my english is bad and added new versions as comments. But as they were developed this approach proves wrong, so I edited page. You'll find Terry's original page and code at the tab with date at the end of this page. Alexander

Bugs and todos

Terry wrote that once the order of keywords for an entry is set, it can't be changed. I do not understand how it worked first and probably have broke this things. Now keywords are just sorted alphabetically.

Styling of seelalso links is hardcoded. Keyword prefixing in see-also links should be an plugin's option.

Plugin make a linebreak in HEAD's meta. Reason is still unknown.

I have no idea how this system treats case, so get the right case the first time at the minimum or you'll have to go into the database and edit by hand (not pretty).

Keywords not exported through the XMLRPC API.

Alexander's native language is not English, sorry for numerous mistakes in this page.

Version History

  • 0.1 First release
  • 0.2 Works with Nucleus 3.0, supports SqlTable feature
  • 0.3 Provide see-also links with doTemplateVar
  • 0.31 See-also links prefixed with keywords they are bound with
  • 0.32 Found a bug with PostUpdateItem instead of PostAddItem. Now keywords can be saved at first attempt.
  • 0.33 Optional second parameter “anyblog” added for TemplateVar, making see-also links to other blogs with same keywords too.
  • 0.38 Some bugs fixed, in particular - now it's not showing future-dated items
  • 0.40 Remove default value for keyword_id because it is already auto_increment


BSD where applicable (Note: Nucleus is GPL and since this is a linked library, this may fall under GPL), please leave the copyright and attribution in the code and derivative works, but other than that you are free to do with as you will. :-)

Plugin review

NP_Keywords version 0.4 works with Nucleus CMS version 3.31 - 2007-11-13 kg

keywords.txt · Last modified: 2016/02/12 06:35 (external edit)