Announcement

Collapse
No announcement yet.

Hide profile search links from unregistered users to prevent bots from using them

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Hide profile search links from unregistered users to prevent bots from using them

    In profiles there are links that are used to search latest posts, threads, blog posts etc. Unregistered users can use them by default so it may be a good idea to hide them to prevent bots from increasing server load.

    Click image for larger version

Name:	search-links.png
Views:	1
Size:	12.0 KB
ID:	3725119

    How to hide the links?
    1. Search for the row in the step 2 or go to AdminCP → Styles & Templates Style Manager → Your style → MEMBERINFO
    2. Find this row:

      HTML Code:
       <li><a href="search.php?{vb:raw session.sessionurl}do=finduser&amp;userid={vb:raw userinfo.userid}&amp;contenttype=vBForum_Post&amp;showposts=1"><img src="{vb:stylevar imgdir_siteicons}/forum.png" alt="{vb:rawphrase find_all_posts}" class="inlineimg" /> {vb:rawphrase find_all_posts}</a></li>
    3. Place this code above it:

      HTML Code:
      <vb:if condition="$bbuserinfo['userid']">
    4. Find
      HTML Code:
      <vb:if condition="$show['view_conversation']">
    5. Put this end tag above it:

      HTML Code:
      </vb:if>


    Now these links should be viewable only by users logged in.
    Last edited by Devtard; Fri 30th Nov '12, 5:01am.
Working...
X