No specialchars in Username (user_account)

Author Message

John Moritz

Saturday 04 October 2008 7:54:43 pm

Hello,

i dont want specialchars allowed for the Username of my community members. Only 0-9, a-z, A-Z and _ - should be allowed. The minimum and maximum characters should be between 3-12.

Is there a ini setting to make this possible or should i hack register.php? I could do this with javascript but an enhanced user can avoid this very easy.

André R.

Sunday 05 October 2008 6:51:17 am

Could you add a comment here with what your requirements are?

http://issues.ez.no/IssueView.php?Id=13587&activeItem=6

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

John Moritz

Tuesday 14 July 2009 2:25:49 pm

Today i found out that ezPublish has included this. And i just want to say wow, and thanks for doin this. Every day i see clear that choosing ezpublish was the best decision i have made! Move on ez...

Now we can use:

[UserSettings]
UserNameValidationRegex[wh]=/[^A-Za-z0-9_-]/
UserNameValidationErrorText[wh]=The username can only contain a-z, digits, underline or hyphen.

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 15:15:06
Script start
Timing: Jan 18 2025 15:15:06
Module start 'layout'
Timing: Jan 18 2025 15:15:06
Module start 'content'
Timing: Jan 18 2025 15:15:07
Module end 'content'
Timing: Jan 18 2025 15:15:07
Script end

Main resources:

Total runtime1.5168 sec
Peak memory usage4,096.0000 KB
Database Queries57

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0058 588.0469152.6406
Module start 'layout' 0.00580.0031 740.687539.4766
Module start 'content' 0.00891.5064 780.1641532.1875
Module end 'content' 1.51530.0015 1,312.351612.1250
Script end 1.5168  1,324.4766 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00340.2226160.0002
Check MTime0.00140.0892160.0001
Mysql Total
Database connection0.00090.056610.0009
Mysqli_queries1.469396.8694570.0258
Looping result0.00050.0341550.0000
Template Total1.484497.920.7422
Template load0.00240.161520.0012
Template processing1.481997.701320.7410
Template load and register function0.00020.010910.0002
states
state_id_array0.00080.055310.0008
state_identifier_array0.00100.067120.0005
Override
Cache load0.00210.1355140.0001
Sytem overhead
Fetch class attribute can translate value0.00060.042820.0003
Fetch class attribute name0.00100.069140.0003
XML
Image XML parsing0.00100.067220.0005
class_abstraction
Instantiating content class attribute0.00000.000640.0000
General
dbfile0.00080.0508170.0000
String conversion0.00000.000640.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
3content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
3content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 10
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs