WS Subscription software
Premium Membership
graphics design php html youtube
Subscribe!
Not a premium user?
Subscriber and get access.
graphics design php html youtube
Live Support
Contact us by live help [photoshop, website design, tutorials]
Not available on weekends

Get userid and username in phpnuke

Hire Us!Download Video(1)Comments
Need Jobs done? Use our brand new Jobs Board to get your projects done at affordable prices.
This tutorial will show you how to simply retrieve userid and username for the current user.


When modifying or creating a page in PHP Nuke, you may need to get the user id and or username for the currently logged in user. This is easily done by using the cookiedecode function.

Your page must include the mainfile.php whether by using a module or creating a new page in the root of your site. The cookiedecode and other crucial codes are included in that file.

Once you page is ready to get the user id, we will then use the following code to get the information you need.

This was really simple uh? Now you can easily display logged in user information from your modules, blocks and other pages.