Hi, I?m developing a guestbook for PostNuke 0.8 and I don?t know how to get the USER HOMEPAGE URL var from the current user, I?d tray whit pnUserGetVar('URL'); but it seems to be disabled in this version, the question is, how can I get this var???
gives the core URL, not the current user home page...
edited by: inexinferis, Apr 01, 2008 - 03:24 PM
-----
-. Karman .- http://www.inexinferis.co.nr
PD: Excuse my English, I am learning... xD
Posted: 01.04.2008, 23:25
rank:
Helper
registered:
March 2005
Status:
offline
last visit:
16.08.08
Posts:
332
No clue, sorry. I guess I misunderstood. I'm totally clueless as to how to gather that information without user input. It seems like the browser would not give that information by a simple command, but would require user input.
This is one thing that really annoys me too: It is really hard to get these user variables. The access contains the legacy of PHPNuke and PostNuke .7 and some new stuff from .8
But you can use pnUserGetVars($uid) to get ALL user variables in an array. So you can pick out what you need.
But it assumes that the property label '_YOURHOMEPAGE' hasn't been changed.
I've been experimenting as I write...
I thought adjusting the Profile module for a default, non-editable set of 'obvious' variable labels might do the trick or use it's pnAPI to get what I wanted... but it's not pnAPI compliant???
So I am requesting some feedback on this core module and it's usage from someone involved in the code please.
-----
Under Construction!
Posted: 02.04.2008, 22:56
rank:
Professional
registered:
November 2003
Status:
offline
last visit:
19.08.08
Posts:
1606
Also thinking the UserUtil could use some UserUtil::[get|getAll|set][user]Profile() methods.
-----
Under Construction!
Posted: 02.04.2008, 23:41
rank:
Professional
registered:
December 2003
Status:
offline
last visit:
20.08.08
Posts:
2901
But it assumes that the property label '_YOURHOMEPAGE' hasn't been changed.
I came to the same conclusion...
-----
David Pahl
Zikula Support Team
Posted: 04.04.2008, 19:30
rank:
Freshman
registered:
April 2008
Status:
offline
last visit:
04.04.08
Posts:
8
thanks!!!
Code
$home_page = pnUserGetVar(_YOURHOMEPAGE)
works great!!!
Regards
-----
-. Karman .- http://www.inexinferis.co.nr
PD: Excuse my English, I am learning... xD