Jump to content
DevFuse Forums

Please help with edit to online users list.


Greg W

Recommended Posts

I am trying to do an edit to the Online Users list, what I really want to achieve is that Admins are not followed around the site, therefore, I want to edit the code so that Admins just show as "Private" or similar for the location when the online list is looked at by members.

 

1 - Is this possible?

 

2 - How can I do it?

 

I have worked out that an edit is needed in the showOnlineList Template, I think it should be a simple edit, but everything I have tried hasn't worked.

 

Please can somebody help me.

Link to comment
Share on other sites

  • Management

This hasn't been tested much but this should work. 4 is the member group id usually of the admin cp. If you want it to be multiple groups, let me know, can alter the edit for you. Also note it will show Private for users in that group regardless of who is viewing. Probably can add an exclusion for other admins if you need to.

 

Open the showOnlineList template bit

 

Find:

					<if test="nowhere:|:!$session['where_line'] || $session['in_error']">
					{$this->lang->words['board_index']}
				<else />
					<if test="wheretext:|:$session['where_link'] AND !$session['where_line_more']">
						<a href='{parse url="{$session['where_link']}" base="public"}'>
					</if>
					{$session['where_line']} 
					<if test="moredetails:|:$session['where_line_more']">
						 
						<if test="wheretextseo:|:$session['_whereLinkSeo']">
							<a href='{$session['_whereLinkSeo']}'>
						<else />
							<if test="detailslink:|:$session['where_link']"><a href='{parse url="{$session['where_link']}" base="public"}'></if>
						</if>
						{$session['where_line_more']}
						<if test="enddetailslink:|:$session['where_link']"></a></if>
					<else />
						<if test="nomoreenddetailslink:|:$session['where_link']"></a></if>
					</if>
				</if>

 

Replace With:

 	<if test="private_session:|:$session['member_group'] == '4'">
	Private
	<else />
				<if test="nowhere:|:!$session['where_line'] || $session['in_error']">
					{$this->lang->words['board_index']}
				<else />
					<if test="wheretext:|:$session['where_link'] AND !$session['where_line_more']">
						<a href='{parse url="{$session['where_link']}" base="public"}'>
					</if>
					{$session['where_line']} 
					<if test="moredetails:|:$session['where_line_more']">
						 
						<if test="wheretextseo:|:$session['_whereLinkSeo']">
							<a href='{$session['_whereLinkSeo']}'>
						<else />
							<if test="detailslink:|:$session['where_link']"><a href='{parse url="{$session['where_link']}" base="public"}'></if>
						</if>
						{$session['where_line_more']}
						<if test="enddetailslink:|:$session['where_link']"></a></if>
					<else />
						<if test="nomoreenddetailslink:|:$session['where_link']"></a></if>
					</if>
				</if>
	</if>

 

Save Template Bit

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...