aboutsummaryrefslogtreecommitdiffstats
path: root/src/sanitizer.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/sanitizer.js')
-rw-r--r--src/sanitizer.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/sanitizer.js b/src/sanitizer.js
index c8a7b9f1..8f4b87a6 100644
--- a/src/sanitizer.js
+++ b/src/sanitizer.js
@@ -15,9 +15,9 @@
*/
// Regular Expressions for parsing tags and attributes
-var START_TAG_REGEXP = /^<\s*([\w:]+)((?:\s+\w+(?:\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|[^>\s]+))?)*)\s*(\/?)\s*>/,
- END_TAG_REGEXP = /^<\s*\/\s*([\w:]+)[^>]*>/,
- ATTR_REGEXP = /(\w+)(?:\s*=\s*(?:(?:"((?:[^"])*)")|(?:'((?:[^'])*)')|([^>\s]+)))?/g,
+var START_TAG_REGEXP = /^<\s*([\w:-]+)((?:\s+[\w:-]+(?:\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|[^>\s]+))?)*)\s*(\/?)\s*>/,
+ END_TAG_REGEXP = /^<\s*\/\s*([\w:-]+)[^>]*>/,
+ ATTR_REGEXP = /([\w:-]+)(?:\s*=\s*(?:(?:"((?:[^"])*)")|(?:'((?:[^'])*)')|([^>\s]+)))?/g,
BEGIN_TAG_REGEXP = /^</,
BEGING_END_TAGE_REGEXP = /^<\s*\//,
COMMENT_REGEXP = /<!--(.*?)-->/g,