public static String getClearHiddenCommandFormParamsFunctionName ( String formName ) { final char separatorChar = FacesContext . getCurrentInstance ( ) . getNamingContainerSeparatorChar ( ) ; if ( formName == null ) { return "'" + HtmlRendererUtils . CLEAR_HIDDEN_FIELD_FN_NAME + "_'+formName.replace(/-/g, '\\$" + separatorChar + "').replace(/" + separatorChar + "/g,'_')" ; } return JavascriptUtils . getValidJavascriptNameAsInRI ( HtmlRendererUtils . CLEAR_HIDDEN_FIELD_FN_NAME + "_" + formName . replace ( separatorChar , ' ' ) ) ; }
Prefixes the given String with clear_ and removes special characters