XF 2.2 Completely remove "Profile Posts" from "What's New" listing

elsparkodiablo

Active member
Hey guys, we're running into issues where members are compromising their information by putting email addresses in profile posts and then scammers email them requesting money for items being sold

I've turned off every Profile Post entry in admin.php?navigation
I've removed the Profile Post widgets from all pages in the Widgets section

How can I remove them from showing up in the What's New feed?
1709966593478.webp
 
Look on template whats_new_wrapper

Rich (BB code):
<xf:macro name="links" arg-pageSelected="!" arg-baseClass="!" arg-selectedClass="!">
    <a class="{$baseClass} {{ $pageSelected == 'overview' ? {$selectedClass} : '' }}" href="{{ link('whats-new') }}">{{ phrase('whats_new') }}</a>
    <!--[XF:links:start]-->
    <a class="{$baseClass} {{ $pageSelected == 'new_thread' ? {$selectedClass} : '' }}" href="{{ link('whats-new/posts') }}" rel="nofollow">{{ phrase('new_posts') }}</a>
    <!--[XF:links:after_thread]-->
    <xf:if is="$xf.visitor.canViewProfilePosts()">
        <a class="{$baseClass} {{ $pageSelected == 'new_profile_post' ? {$selectedClass} : '' }}" href="{{ link('whats-new/profile-posts') }}" rel="nofollow">{{ phrase('new_profile_posts') }}</a>
    </xf:if>
    <!--[XF:links:after_profile_post]-->
    <xf:if is="$xf.options.enableNewsFeed">
        <xf:if is="$xf.visitor.user_id">
            <a class="{$baseClass} {{ $pageSelected == 'news_feed' ? {$selectedClass} : '' }}" href="{{ link('whats-new/news-feed') }}" rel="nofollow">{{ phrase('your_news_feed') }}</a>
        </xf:if>

        <a class="{$baseClass} {{ $pageSelected == 'latest_activity' ? {$selectedClass} : '' }}" href="{{ link('whats-new/latest-activity') }}" rel="nofollow">{{ phrase('latest_activity') }}</a>
    </xf:if>
    <!--[XF:links:end]-->
</xf:macro>
 
Look on template whats_new_wrapper

Rich (BB code):
<xf:macro name="links" arg-pageSelected="!" arg-baseClass="!" arg-selectedClass="!">
    <a class="{$baseClass} {{ $pageSelected == 'overview' ? {$selectedClass} : '' }}" href="{{ link('whats-new') }}">{{ phrase('whats_new') }}</a>
    <!--[XF:links:start]-->
    <a class="{$baseClass} {{ $pageSelected == 'new_thread' ? {$selectedClass} : '' }}" href="{{ link('whats-new/posts') }}" rel="nofollow">{{ phrase('new_posts') }}</a>
    <!--[XF:links:after_thread]-->
    <xf:if is="$xf.visitor.canViewProfilePosts()">
        <a class="{$baseClass} {{ $pageSelected == 'new_profile_post' ? {$selectedClass} : '' }}" href="{{ link('whats-new/profile-posts') }}" rel="nofollow">{{ phrase('new_profile_posts') }}</a>
    </xf:if>
    <!--[XF:links:after_profile_post]-->
    <xf:if is="$xf.options.enableNewsFeed">
        <xf:if is="$xf.visitor.user_id">
            <a class="{$baseClass} {{ $pageSelected == 'news_feed' ? {$selectedClass} : '' }}" href="{{ link('whats-new/news-feed') }}" rel="nofollow">{{ phrase('your_news_feed') }}</a>
        </xf:if>

        <a class="{$baseClass} {{ $pageSelected == 'latest_activity' ? {$selectedClass} : '' }}" href="{{ link('whats-new/latest-activity') }}" rel="nofollow">{{ phrase('latest_activity') }}</a>
    </xf:if>
    <!--[XF:links:end]-->
</xf:macro>
Just comment it out?
 
Yes comment out or remove it (you can always restore the default via the revert button) . Then test that result is what you want.
 
Last edited:
Years ago, we took permissions away for profile posts completely. That took it out of the menu. It can also be turned off manually, without modifying any code.

ADMIN CP -> SETUP -> PUBLIC NAVIGATION
 
Put it in your rules that profile posts cannot be used for selling stuff.
Tell them to use the conversations if giving out details.
If they ignore that rule they will have scammers after them.
 
How to remove profile posts:

Admin control panel -> User groups & permissions -> User group permissions -> Unregistered / Unconfirmed

1709996204231.webp

Do the same for the Registered user group.
 
I wish some of you would read the OP before commenting.
I've turned off every Profile Post entry in admin.php?navigation
I've removed the Profile Post widgets from all pages in the Widgets section

How can I remove them from showing up in the What's New feed?
View attachment 299363


This is what my admin.php?navigation section looks like
1710002934153.webp


Notice New Profile Posts is turned off

Thus, replies like this:
Years ago, we took permissions away for profile posts completely. That took it out of the menu. It can also be turned off manually, without modifying any code.

ADMIN CP -> SETUP -> PUBLIC NAVIGATION
Are less than helpful as they still show up under What's New, per the image I put in the OP.

I've also turned them off under the Members tab:

1710003309147.webp

Yet clicking "What's New" still displays "New Profile Posts" in the sub navbar

1710003334149.webp


How to remove profile posts:

Admin control panel -> User groups & permissions -> User group permissions -> Unregistered / Unconfirmed

View attachment 299383

Do the same for the Registered user group.

@AndyB I do not want profile posts removed completely. I've already turned permissions for banned users & unregistered / not logged in to not be able to see them.

It's looking like the best option is going to be commenting out the Profile Posts sections of the template.
 
Back
Top Bottom