mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-31 17:39:05 +00:00
- fixed illegal character use in forum article names
- fixed navigation issue with editing rules - added links to details pages in forums area - you can no longer create spaces, forums or topics with illegal characters in the name git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@2745 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -102,3 +102,23 @@ function validateRegex(control, expression, requiresMatch, matchMessage, noMatch
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Ensures the value of the 'control' does not contain any illegal characters.
|
||||
*
|
||||
* @return true if the file name is valid
|
||||
*/
|
||||
function validateName(control, message, showMessage)
|
||||
{
|
||||
var result = true;
|
||||
var pattern = /[\"\*\\\>\<\?\/\:\|\%\&\+\;\xA3\xAC]+/;
|
||||
|
||||
var idx = control.value.search(pattern);
|
||||
if (idx != -1)
|
||||
{
|
||||
informUser(control, control.value.charAt(idx) + " " + message, showMessage);
|
||||
result = false;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user