代码如下: function TextValidate(type) { var code; var character; var Lang = document.getElementById(‘Lang’).value; var err_msg = “”; if (Lang != “Eng”) { err_msg = “文件夹名稱不能包含下列字符之一:\n \\ / : * ? \” < > | & , “; } else { err_msg = “A Folder Name cannot contain any of the following characters:\n \\ / :