• Resolved Alex Stine

    (@alexstine)


    Hello @lando1982,

    Is there a code snippet I can use to exclude pages or posts from search? I want to exclude them permanently so when I go to re run the index, they’re not indexed again.

    Thanks.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Andrea Landonio

    (@lando1982)

    Hi Alex, it’s not possible! But it’s a good extension for my plugin.. I take a note of your suggestion and I’ll include it in the next plugin release.

    Thanks

    Thread Starter Alex Stine

    (@alexstine)

    Hopefully it will be included soon. Some pages such as my contact “Thank You” page appears in search results and I need to remove pages/posts/other content such as this.

    Thanks.

    Plugin Author Andrea Landonio

    (@lando1982)

    Hi Ales, in the new plugin release (1.3.2) you can find a method to exclude post/page from search.. you have to add a custom field with name “acs_exclude” and with value 1 to your post/page..

    Ler me know..

    Thread Starter Alex Stine

    (@alexstine)

    Looks like a good solution, I’ll let you know if there is problems.

    Thanks. ??

    Thread Starter Alex Stine

    (@alexstine)

    Hello @lando1982

    Okay, maybe not so easy. I thought this was a field or ability you added in the plugin. It looks as if I actually have to create the field and then create a small admin page form to save values in said field. Am I over thinking it? Step by step instructions would really help me.

    Thanks.

    Plugin Author Andrea Landonio

    (@lando1982)

    Hi Alex,

    post/page exclusion is fully managed by the plugin. I choose to not add a form on admin or new/edit post page where the blog users could exclude or not the post. For me, post/page exclusion is typically a super-admin/developer task.

    I’ll try to give you a step by step explanation:

    1) edit your post
    2) scroll down to the “Custom Fields” section
    3) click “Enter new” and set in the “Name” field the value “acs_exclude” and in the “Value” field the value “1” (both without the ” char)
    4) click “Add Custom Field”
    5) save the post

    After a few seconds your post will be deleted from the index!
    NOTE: set value “0” or remove custom field if you want to restore the post

    It very simple.. and I think it’s a good solution for your problem..

    Thread Starter Alex Stine

    (@alexstine)

    Looks like it is working, thanks for the help. Marking it resolved.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘How to exclude certain pages’ is closed to new replies.