WordPress.org

Ready to get started?Download WordPress

Forums

Custom Field Widget
Is there any HTML widget for specific post and category (2 posts)

  1. Ashish Dhorajiya
    Member
    Posted 2 years ago #

    I want to add some code in some specific category, pages and post. So is there any plugin for this?

    http://wordpress.org/extend/plugins/custom-field-widget/

  2. Kakoma
    Member
    Posted 2 years ago #

    Hi Ashish,
    You'll need to give a few more details on your issue; though from what you've shared, depending on how comfortable you are with editing .php files, you won't need a plugin.
    You can edit single.php in your theme(used to display posts) and add code that will execute on only some posts
    e.g.

    <?php if(is_single('181')): ?>
    //code
    <?php endif; ?>

    The code //code would only execute on post 181. You can do the same for page.php

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic