Displaying User Attributes in sets on Profile / Edit page
Permalink
Hi guys,
I am currently playing with the User Attributes for registered members and am wondering if anyone can shed light on this for me, I am hoping it is a simple answer but I cannot figure it out with my limited php knowledge.
I am hoping to achieve a very similar result to the concrete5.org Edit Profile page where the form questions are grouped under headings such as 'Personal Information', 'Address' and 'Public Profile'.
My thoughts so far were to add my questions to User Attribute Sets but I cannot figure how to display these sets independently.
I can see the following code on single_pages/profile/edit.php which prints all attributes checked to be editible on profile but am unsure how I can change this to only display a User Attribute Set instead.
<fieldset>
<?php
$af = Loader::helper('form/attribute');
$af->setAttributeObject($ui);
foreach($attribs as $ak) {
print '<div class="ccm-profile-attribute">';
print $af->display($ak, $ak->isAttributeKeyRequiredOnProfile());
print '</div>';
} ?>
</fieldset>
<?php } ?>
Any input will be greatly appreciated. Cheers.
I am currently playing with the User Attributes for registered members and am wondering if anyone can shed light on this for me, I am hoping it is a simple answer but I cannot figure it out with my limited php knowledge.
I am hoping to achieve a very similar result to the concrete5.org Edit Profile page where the form questions are grouped under headings such as 'Personal Information', 'Address' and 'Public Profile'.
My thoughts so far were to add my questions to User Attribute Sets but I cannot figure how to display these sets independently.
I can see the following code on single_pages/profile/edit.php which prints all attributes checked to be editible on profile but am unsure how I can change this to only display a User Attribute Set instead.
<fieldset>
<?php
$af = Loader::helper('form/attribute');
$af->setAttributeObject($ui);
foreach($attribs as $ak) {
print '<div class="ccm-profile-attribute">';
print $af->display($ak, $ak->isAttributeKeyRequiredOnProfile());
print '</div>';
} ?>
</fieldset>
<?php } ?>
Any input will be greatly appreciated. Cheers.