Menu

#3 namingAttribute not properly set when creating User Account

open
nobody
None
5
2007-11-26
2007-11-26
No

After altering the quick-create template for User Account to have "namingAttribute: uid", I found that 'cn' was still being used as the naming attribute. I identified and fixed the problem code in main.html, in quickCreate()

var namingAttribute; var icon_src;
$A(TXML.getElementsByTagName('TEMPLATE')).each( function(templateXML) {
var name = XMLNodeValue(templateXML,'name');
if (name = templateName) {
namingAttribute = XMLNodeValue(templateXML,'namingAttribute');
icon_src = XMLNodeValue(templateXML,'icon');
}
});

The error is
if(name = templateName)
should read
if(name == templateName)

I.e: this search matches every template and the namingAttribute is set by the final template rather than the one matching templateName.

Discussion


Log in to post a comment.