<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Calibri, sans-serif;">
<div>
<div>
<div>2 seconds after I found that there were custom attribute template examples in examples/themes that gave me the nuance that is missing or lost on me in the documentation.</div>
<div><br>
</div>
<div>You need to use the format “user.attributes.mobile” everywhere <span style="font-weight: bold;">
except</span> when rendering the value from the model. There you use ${account.attributes.mobile} for the interpolation. Any chance those could match and both be account.attributes.<blah> rather than be different?</div>
<div><br>
</div>
<div>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
<div class="form-group ${messagesPerField.printIfExists('user.attributes.mobile','has-error')}"></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
<div class="col-sm-2 col-md-2"></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
<label for="user.attributes.mobile" class="control-label">${msg("mobile")}</label> <span class="required">*</span></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
</div></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62); min-height: 14px;">
<br>
</p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
<div class="col-sm-10 col-md-10"></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
<input type="text" class="form-control" id="user.attributes.mobile" name="user.attributes.mobile" value="${(account.attributes.mobile!'')?html}"/></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
</div></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
</div></p>
</div>
<div><br>
</div>
<div>-Jason</div>
<div>
<div id="MAC_OUTLOOK_SIGNATURE"></div>
</div>
</div>
</div>
<div><br>
</div>
<span id="OLK_SRC_BODY_SECTION">
<div style="font-family:Calibri; font-size:12pt; text-align:left; color:black; BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: 0in; PADDING-LEFT: 0in; PADDING-RIGHT: 0in; BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; PADDING-TOP: 3pt">
<span style="font-weight:bold">From: </span><<a href="mailto:keycloak-user-bounces@lists.jboss.org">keycloak-user-bounces@lists.jboss.org</a>> on behalf of Jason Axley <<a href="mailto:jaxley@expedia.com">jaxley@expedia.com</a>><br>
<span style="font-weight:bold">Date: </span>Tuesday, February 23, 2016 at 9:02 PM<br>
<span style="font-weight:bold">To: </span>"<a href="mailto:keycloak-user@lists.jboss.org">keycloak-user@lists.jboss.org</a>" <<a href="mailto:keycloak-user@lists.jboss.org">keycloak-user@lists.jboss.org</a>><br>
<span style="font-weight:bold">Subject: </span>[keycloak-user] Custom user attribute documentation correct?<br>
</div>
<div><br>
</div>
<div>
<div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Calibri, sans-serif;">
<div>
<div>
<div>Is the documentation here accurate for v1.9.0-Final? <a href="http://keycloak.github.io/docs/userguide/keycloak-server/html/custom-user-attributes.html#d4e3678">http://keycloak.github.io/docs/userguide/keycloak-server/html/custom-user-attributes.html#d4e3678</a>
It says (for the user account profile pages, for example) that attributes must be of the form like “user.attributes.mobile” but if you do this, Freemarker can’t render the template. I can render it if I use “account.mobile”, however it’s not displaying the
data that is definitely there on the user profile (I can see it as an administrator on the Attributes tab). </div>
<div><br>
</div>
<div>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
<div class="form-group ${messagesPerField.printIfExists('account.mobile','has-error')}"></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
<div class="col-sm-2 col-md-2"></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
<label for="account.mobile" class="control-label">${msg("mobile")}</label> <span class="required">*</span></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
</div></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62); min-height: 14px;">
<br>
</p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
<div class="col-sm-10 col-md-10"></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
<input type="text" class="form-control" id="account.mobile" name="account.mobile" value="${(account.mobile!'')?html}"/></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
</div></p>
<p style="margin: 0px; font-size: 12px; font-family: Courier; color: rgb(255, 240, 165); background-color: rgb(19, 119, 62);">
</div></p>
</div>
<div><br>
</div>
<div>
<div id="">
<div style="font-size: 14px;">
<div>-Jason</div>
</div>
<div style="font-size: 14px;"><br>
</div>
<div>
<p class="MsoNormal" style="font-size: 11pt; margin: 0in 0in 0.0001pt; background-color: white;">
<b><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(23, 54, 93);">Jason Axley</span></b></p>
<p class="MsoNormal" style="margin: 0in 0in 0.0001pt; background-color: white;"><span style="font-family: Arial, sans-serif; color: rgb(227, 108, 10);"><font size="2">Sr. Security Engineer, Expedia Worldwide Engineering Team<o:p></o:p></font></span></p>
<p class="MsoNormal" style="font-size: 11pt; margin: 0in 0in 0.0001pt;"><span style="font-size: 8pt; color: rgb(31, 73, 125);">425-679-4157 (o) | 206-484-2778 (m) | 206-55-AXLEY (gv)<o:p></o:p></span></p>
<p class="MsoNormal" style="font-size: 11pt; margin: 0in 0in 0.0001pt;"><span style="font-size: 8pt; color: rgb(31, 73, 125);">333 108th Ave NE, 9S-282, Bellevue, WA 98004</span></p>
<p class="MsoNormal" style="font-size: 11pt; margin: 0in 0in 0.0001pt;"><span style="font-size: 8pt; color: rgb(31, 73, 125);"><a href="https://confluence/display/POS/EWE+Security">EWE Security Wiki</a></span></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</span>
</body>
</html>