Topic: Members Online - Theme.php
Dogeth
avatar
Freshman
Freshman
Posts: 6

Posted:
24.Mar 2004 - 15:31

Hi all.
Have moded the default theme a bit but not sure how one displays the uname , pwd, login fields in the top bar. I can see reference to it in the theme.php but not sure how to change it.

eg. on this forum I see "Welcome Dogeth! - Your Account | Log Out" in the black bar below the title graphic. I'd like to duplicate this on my site (www.elands.com)

Also the only Members online block I could find was part of the Forums display. I deselected all the forum info to just get the Members but it's a sad hack.

Any help much appreciated.

D

--
"The ultimate goal of farming is not the growing of crops,
but the cultivation and perfection of human beings."
Masanobu Fukuoka
Simon
online
avatar
Steering Committee
Steering Committee
Posts: 13427

Posted:
24.Mar 2004 - 15:39

Try something along the lines of

Welcome pnUserGetVar('uname') - Your Account | Logout


Depending on where this is in your theme, you may need to escape quotes.

Finally, you may want to do an

if (pnUserLoggedin())
{
}
else
{
Welcome Guest!
}
To make sure you dont display this info if the user is not logged in.


Information taken from the PostNuke API reference....

--
Regards,
Simon

itbegins.co.uk - Zikula Consulting

Please read the Support Guide
Dogeth
avatar
Freshman
Freshman
Posts: 6

Posted:
24.Mar 2004 - 16:32

Thanx for the speedy reply Hammer.

May I then ask, if not logged in, how do I display the login fields rather than just 'Welcome Guest' ?

TIA

D

--
"The ultimate goal of farming is not the growing of crops,
but the cultivation and perfection of human beings."
Masanobu Fukuoka
Simon
online
avatar
Steering Committee
Steering Committee
Posts: 13427

Posted:
24.Mar 2004 - 18:28

Try taking the code from another theme, or using the stuff in includes/blocks/login.php

--
Regards,
Simon

itbegins.co.uk - Zikula Consulting

Please read the Support Guide
ahksijen
avatar
Helper
Helper
Posts: 132

Posted:
24.Mar 2004 - 22:45

Quote

Also the only Members online block I could find was part of the Forums display. I deselected all the forum info to just get the Members but it's a sad hack.

I recommend dp-StaffStatus, a block available at http://www.dev-postnuke.com
it's excellent and configurable to display as much or as little information as you want to