This question has been answered by BobRay. See the first response.
<?php $user = $modx->getObject('modUser', array('id' => $modx->user->get('id'))); // get present user infos if ($user) { if ($user->isMember(array($group))) { $page = $modx->getObject('modResource', $pageId); return $page->getTVValue($tv); } }
[[!isLegitMember? &pageId=`[[*id]]` &group=`Administrator` &tv=`wholeSale`]]
[[!Personalize? &yesChunk=`@CODE:[[*Wholesale]]` &noChunk=`@CODE:[[*Retail]]` &allowedGroups=`Administrator,customer` ]]
This should also do it if you have the Personalize extra installed. Put this tag where you want the price to appear:
[[!Personalize? &yesChunk=`@CODE:[[*Wholesale]]` &noChunk=`@CODE:[[*Retail]]` &allowedGroups=`Administrator,customer` ]]
Wholesale and Retail are the names of TVs holding the wholesale or retail price. Only members of a group listed in &allowedGroups can see the wholesale price.