MyBB Community Forums
Page - Printable Version

+- MyBB Community Forums (https://community.mybb.com)
+-- Forum: Extensions (https://community.mybb.com/forum-201.html)
+--- Forum: Plugins (https://community.mybb.com/forum-73.html)
+---- Forum: Plugin Development (https://community.mybb.com/forum-68.html)
+---- Thread: Page (/thread-169013.html)



Page - Wires - 2015-03-29

So basically, I'm trying to make a IF statement depending on the UID of a user. I'm basically creating a custom page and only want the user with a certain UID to view the page.

Any ideas?

Found what I'm looking for never mind.


RE: Page - mikeh - 2015-03-29

Next time please post the solution to your thread too. It could be helpful to other people.


RE: Page - Omar G. - 2015-03-29

if($mybb->user['uid'])
{
	$username = htmlspecialchars_uni($mybb->user['username']);
	echo "Hello {$username}!";
}