BuddyDev

Search

[Resolved] Member to enable/disable to get indexed from Search Engines

  • Participant
    Level: Master
    Posts: 496
    Daniel on #15072

    Yo Hi,

    Is there a way to install a plugin where the buddypress member can enable/disable to opt out of being indexed from Search Engines ?

    I saw that on the dashboard I can select this option for each member, but I think the best will be if the member can do it himself?

    Thanks for your information.

    Regards,
    Daniel

  • Keymaster
    (BuddyDev Team)
    Posts: 24190
    Brajesh Singh on #15094

    Hi Daniel,
    Are you using a custom plugin that allows you to index/no index profile.

    BuddyPress doe not have this functionality.

    Still, It is easy to do that.
    All you need to do is add a meta tag like this

    
    <meta name="robots" content="noindex, nofollow">
    

    I don’t see any existing plugin giving an option to the user though.

  • Participant
    Level: Master
    Posts: 496
    Daniel on #15103

    Hi Brajesh,

    Thanks for your reply.

    In Dashboard, when I go to Menu User and I click on a username from the list, I can disable/enable the users archive from indexing from Search Engines by tick/untick this field below.

    *Do not allow search engines to show this author’s archives in search results.*

    I think it is from Yoast SEO Plugin.

    As you know I am PHP beginner 🙂 what do you mean with adding the meta tag ? Do I need to implement the code inside a php file and then create a tab with the BP Profile Tabs Plugin in order that it appears on the users profiles ?

    Thank you.

    Regards,
    Daniel

  • Keymaster
    Level: Yogi
    (BuddyDev Team)
    Posts: 2934
    Ravi on #15126

    Hello Daniel,

    Please refer this url
    https://gist.github.com/raviousprime/a33414052343dfaafbcf80956648d7ea

    It will add new tab under settings tab Where user can select no index, no follow option for his profile
    and will and meta based on saved settings.

    Thank You
    Ravi

  • Participant
    Level: Master
    Posts: 496
    Daniel on #15127

    Hi Ravi,

    Thanks for the very nice looking code.

    Just one question: do I need to create a new php file called no-follow-no-index.php

    and put the code inside? If yes, might could you state please in which folder I need to place then this no-follow-no-index.php file ?

    or do I need to simply add the code to the bp-custom.php file ?

    Thank you for clarification.

    Regards,
    Daniel

  • Participant
    Level: Master
    Posts: 496
    Daniel on #15129

    Hi Ravi,

    Ahh, I see now, did you create a new plugin and I can download the ZIP file from the Githup page that you have provided.

    Does this means that I just need to upload the zip file to wordpress the same way when I upload any other plugin and then I click activate in order that it activates the plugin ?

    Thank you for clarification.

    Kind regards,
    Daniel

  • Keymaster
    Level: Yogi
    (BuddyDev Team)
    Posts: 2934
    Ravi on #15130

    Hello Daniel,

    No, There is no need to create a new file. Just place the code in “bp-custom.php” file. It will work.

    Thanks
    Ravi

  • Participant
    Level: Master
    Posts: 496
    Daniel on #15136

    Hi Ravi,

    Thank you for clarifying.

    I have added the code as per your instruction and it looks like that it works.

    Thank you so much, that’s very cool!

    Only some little adjustments:

    1. I would like to add a text above of the two tick boxes saying:

    *Enable or Disable your Profile to get indexed from Search Engines*.

    2. The Text “No Index” “No Follow” next to the tick boxes are too close, how can I make a space in between ?

    3. The Tab is called “Search engines” and I would like that it looks like the other tabs “Search Engines” (Engines also in Capital Letter)

    Would it be possible to just help me how I can modify the three mentioned details ?

    Thank you.

    Regards,
    Daniel

  • Keymaster
    Level: Yogi
    (BuddyDev Team)
    Posts: 2934
    Ravi on #15140

    Hello Daniel,

    Thank you for the acknowledgement. I have updated the code. Please replace old code with new one.

    Thank You
    Ravi

  • Participant
    Level: Master
    Posts: 496
    Daniel on #15142

    Thank you Ravi, it looks awesome!

    Thank you very much for your really great work to write the code and for your time!

    Thanks again!

    Best regards,
    Daniel

The topic ‘ [Resolved] Member to enable/disable to get indexed from Search Engines’ is closed to new replies.

This topic is: resolved