Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
RE: AUI Column settings
I want to change the default maxlength attribute in the following
<aui:column><aui:input name="TIN"/></aui:column>
I tried to set the "max" attribute like so
<aui:column><aui:input name="TIN" max="10"/></aui:column>
But it's still at the default 75 characters and the HTML looks like this when I inspect it
<input class="field lfr-input-text" id="_compasspracticeprofile_WAR_compasspracticesportlet_TIN" name="_compasspracticeprofile_WAR_compasspracticesportlet_TIN" style="max-width: 350px; " type="text" value="XXXXXXXXX" maxlength="75">
I need to limit this field to 10 characters since our database can't handle anything greater than 10. Seems like there would be a simple solution here but I've been fighting with it for the last hour.. The aui stuff so clearly documented.....
<aui:column><aui:input name="TIN"/></aui:column>
I tried to set the "max" attribute like so
<aui:column><aui:input name="TIN" max="10"/></aui:column>
But it's still at the default 75 characters and the HTML looks like this when I inspect it
<input class="field lfr-input-text" id="_compasspracticeprofile_WAR_compasspracticesportlet_TIN" name="_compasspracticeprofile_WAR_compasspracticesportlet_TIN" style="max-width: 350px; " type="text" value="XXXXXXXXX" maxlength="75">
I need to limit this field to 10 characters since our database can't handle anything greater than 10. Seems like there would be a simple solution here but I've been fighting with it for the last hour.. The aui stuff so clearly documented.....
Hi Kevin, I think it's just a typo. You have this (according to your post)
But looking through the Liferay source code, I can see that when they are using it, the use the maxLength attribute, not max. Like so.
<aui:column><aui:input name="TIN" max="10" /></aui:column>
But looking through the Liferay source code, I can see that when they are using it, the use the maxLength attribute, not max. Like so.
[code]
Copyright © 2025 Liferay, Inc
• Privacy Policy
Powered by Liferay™