Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2011-11-27 12:17:33

Ejoh
New Member
Registered: 2011-11-27
Posts: 2

Display name of logged in user [solved]

I have created a new section in the admin panel using the smd_tabber plugin. This basically allows for a page to be created using a page template which is great.

On this page I would like to be able to get the name of the logged in user (I want to enter in into a database) but I cannot figure out how to call it through php.

Last edited by Ejoh (2011-11-27 13:07:58)

Offline

#2 2011-11-27 13:07:38

Ejoh
New Member
Registered: 2011-11-27
Posts: 2

Re: Display name of logged in user [solved]

SOLVED

In order to call the name of the user and print it you need to write like this:

global $txp_user;
echo $txp_user;

Offline

Board footer

Powered by FluxBB