xoops forums

kakos

Friend of XOOPS
Posted on: 2014/4/30 10:41
kakos
kakos (Show more)
Friend of XOOPS
Posts: 73
Since: 2002/6/6 2
#1

Smarty tags to derive content from profile module and display it only in one (xoops) group

I did some search but did not find anything similar for profile module and groups.

So ...
is there a way to display something in the theme only for some groups, for example,
<{if $xoops_group == something}> message <{/if}>


Then in this message is it possible to display the content from a profile (module) field (those fields which created by user) like
<{$xoops_uname}>

?

thanks in advance

noo-b

Just can't stay away
Posted on: 2014/4/30 14:53
noo-b
noo-b (Show more)
Just can't stay away
Posts: 456
Since: 2007/10/23
#2

Re: Smarty tags to derive content from profile module and display it only in one (xoops) group

take a look at this old thread..maybe you can get some idea

:: view by group
https://xoops.org/modules/newbb/viewto ... id=325512#forumpost325512
https://xoops.org/modules/newbb/viewtopic.php?topic_id=32938

:: calling custom field from profile module
https://xoops.org/modules/newbb/viewtopic.php?topic_id=68104
https://xoops.org/modules/newbb/viewtopic.php?topic_id=68867
https://xoops.org/modules/newbb/viewto ... id=301524#forumpost301524

you can do this in profile module...but not sure if this possible to refrence it outside profile module

example in profile/userinfo.php you can put this at the end end some where before line with //userinfo

$mycustomfieldname $profile->getVar('mycustomfieldname');
$xoopsTpl->assign('mycustomfieldname',$mycustomfieldname);


in profile template you can use this
<{$mycustomfieldname}>

kakos

Friend of XOOPS
Posted on: 2014/5/5 5:11
kakos
kakos (Show more)
Friend of XOOPS
Posts: 73
Since: 2002/6/6 2
#3

Re: Smarty tags to derive content from profile module and display it only in one (xoops) group

Thanx for your answer...

For profile custom field the post #18 from Trabis in your reference does the job just fine. The groups need more search.