Skip to main content
We are Brand SEO Beijing serving international business, your marketing partner, Contact us by mi@mgsh.com.cn

Website custom classification template plugin

To realize the use of different styles for different categories of WordPress, the general practice is to create multiple category templates, and make corresponding calls through the corresponding category ID or category alias, or useis_category()The function to judge and call (refer to the tutorial "How to call different templates in different WordPress categories"), the operation is more complicated, and the implementation of the Custom Category Templates plug-in can avoid these steps.

Plug-in introduction:

The Custom Category Templates plugin is a wordpress plugin that can freely select category templates and call different display styles. Users place the prepared category template php file in the current theme root directory. After enabling the plugin, select the template in the category directory editing interface. Can.

Plugin Tutorial:

1. Download the plugin: WordPress official plugin center (or contact the site administrator)
2. After uploading and installing the plugin successfully, enable the plugin
3. Put the prepared classification template php file in the root directory of the currently used theme, and put the first line of the file in the<?phpReplace with the following code:

<?php /* Template Name: 自定义模板 */

Tip: Change the template name "Custom Template" to a name you like, and the names of different templates are different.
4. Enter the website background - article - category directory, edit the category that you want to call different templates, and select the template you want to call in the drop-down of "Category Templates"
wordpress Custom Category Template-brand-SEO-public opinion-optimization-米国生活
5. Finally, click Save.
Of course, you can study the code of the plugin and inherit this functionality into your current theme.

Back to Top