WordPress Tagging and Displaying Tag Clouds


WordPress 1.5 A plugin that allows you to tag posts and view tag clouds in . Jerome's Keywords Plugin , you can download the plugin and install it easily.

 

Installing the plugin

How to create a tag cloud or tag cosmos page Creating a keyword cosmos It is shown in , but I have rearranged it because the method of pasting it on the page does not seem to be detailed.

  1. sample cosmos.php template file After downloading and unpacking, upload cosmos.php to the current theme directory.
  2. Then, go to Site Admin and create a Page. In the page options, select 'Page Template' as 'ComsmosPage' and save it.
    wordpress page option
  3. Open the theme and link it to the tags menu. In my case it is in header.php .


To display a cloud of popular tags in the sidebar

 

1. Open sidebar.php and add the following source to the section to display the tag cloud.

Popular Tags

%keyword% ',” , 1,10, 3); ?>

more …

The meaning of 1,10,3 of the all_keywords() function means that the size of the character is divided from 1st to 10th column, and the tag displays at least 3 or more. It is specified in the cosmos class in style.css .

 

To display the number of posts in a tag

It is difficult to know the number of posts in each tag just by looking at the tag cloud. Like me, if you want to list all tags in alphabetical order on the left/right menu and insert the number of posts, you can do as follows.

  1. Open sidebar.php in your theme directory.
  2. Add the following sources: At this time, it should be shown when the tag menu is clicked, so it should be shown only when the page_id is the relevant number. In my case the page_id is 9.

    Tags

    %keyword% (%count%) ') ?>

If you want it to appear in the body rather than the left and right menus like me, you can put the above source in cosmos.php

When writing an article, a keyword input box appears below the text input box. Just enter the keywords you want to tag there.
There are times when you need to rename some tags all at once while writing and tagging. I made a plugin to change tags all at once. We will upload it soon.







Recommendations





0 If you like the article, please click the heart~ It will be a strength to bloggers (SNS/login/advertising is not related)



Articles you might like







smart stock calculator

Various stock calculators for successful stock investment: profit/loss ratio, profit/loss unit price, purchase quantity, water/burning unit price, unit price required funds, selling price, percentage, etc.












17 Comments

Add a Comment

Email addresses are not disclosed. Required items *is indicated by

























This posting is part of Coupang Partners' activities, and a certain amount of commission is provided accordingly.