MyBB Community Forums

Full Version: Assign IP on Posts to Unknown Users or Guests
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
This small modification allows you to assign a Unique IP to the Unknown Users or Guests and show it on their Postbit.

It probably allows Moderators to Search Posts with that IP. Wink


First we have to remove their Default username ($lang->guest) to their IP.

Open ./inc/functions_post.php and find;
		$post['username'] = $post['username'];
and Change it to;
		$post['username'] = $_SERVER['REMOTE_ADDR'];

Save file.

Second, we've to remove the login box from Newthread, Newreply and Edit post pages just to make sure that our Username field remain empty (this is needed because we are using IP as their default username);

Now go to: ACP > Templates > Newthread Templates > newthread > find and remove the following;
{$loginbox}

Similarly, Open New Reply templates > newreply > find and remove the following;
{$loginbox}

Similarly, Open Edit Post Templates > editpost > find and remove the following;
{$loginbox}

FINAL RESULTS:
[attachment=22373] [attachment=22374] [attachment=22375] [attachment=22376] [attachment=22377]