*
The moose likes JForum and the fly likes Member List only for Members Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Products » JForum
Bookmark "Member List only for Members" Watch "Member List only for Members" New topic
Author

Member List only for Members

Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Hello everybody,

it is possible to disable the member list for users (anonymous) which aren't log on?

If there is no config switch at which position can I change this in the source code?

Thanks for helping, Kai.
[originally posted on jforum.net by kj]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
kj wrote:Hello everybody,

it is possible to disable the member list for users (anonymous) which aren't log on?

If there is no config switch at which position can I change this in the source code?

Thanks for helping, Kai.

The files named "user_list.htm" and "user_profile.htm" need to be edited.

The code below will show a nice box with the message, and a link back to the main JForum page. You can copy/paste the code snippets to the two files that need to be updated.

NOTE: you will need to change the "/jforum-2.1.8/" in the code sample to the directory name of your JForum install directory!!

At the top of the files, add the code in red below to the existing code (existing code is shown in black, new code in red):
<!-- <br /> <#include "js/utils.js"/> <br /> <br /> -->
</script>

<#if logged>

<#include "karma_search.inc.htm">



Then at the end of the files insert this code in red:

<table > <tr> <td ><#if thisPage?exists><@pagination.doPagination "${action}", -1/></#if></td> </tr> </table> <#else> <table border="0" > <tr> <td class="bodyline"> <table border="0" > <tr> <td class="nav">Forum Index</td> </tr> </table> <table class="forumline" border="0"> <tr><th> </th> </tr> <tr> <td class="row1"> <table border="0"> <tr> <td >Sorry, you must be logged in to see Member information!

</td> </tr> <tr> <td> </td> </tr> <tr> <td >Forum Index </td> </tr> </table> </td> </tr> </table> </td> </tr> </table>
</#if>


<#include "bottom.htm"/>


[originally posted on jforum.net by GatorBait3]
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Member List only for Members
 
Similar Threads
Reversing a Linked List
[Cricket] India VS Pakistan
Protected vs Default
Stack overflow error !
Overriding Static Method Question