Changeset 392 for trunk/rss/extlib/kses.php
- Timestamp:
- 04/23/05 15:56:47 (4 years ago)
- Files:
-
- 1 modified
-
trunk/rss/extlib/kses.php (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/rss/extlib/kses.php
r260 r392 132 132 133 133 $xhtml_slash = ''; 134 if (preg_match('%\s /\s*$%', $attr))134 if (preg_match('%\s*/\s*$%', $attr)) 135 135 $xhtml_slash = ' /'; 136 136 … … 208 208 case 0: # attribute name, href for instance 209 209 210 if (preg_match('/^([-a-zA-Z]+) /', $attr, $match))210 if (preg_match('/^([-a-zA-Z]+)\/?/', $attr, $match)) 211 211 { 212 212 $attrname = $match[1]; 213 213 $working = $mode = 1; 214 $attr = preg_replace('/^[-a-zA-Z]+ /', '', $attr);214 $attr = preg_replace('/^[-a-zA-Z]+\/?/', '', $attr); 215 215 } 216 216 … … 241 241 case 2: # attribute value, a URL after href= for instance 242 242 243 if (preg_match('/^"([^"]*)"(\s+|$ )/', $attr, $match))243 if (preg_match('/^"([^"]*)"(\s+|$|\/)/', $attr, $match)) 244 244 # "value" 245 245 { … … 252 252 'vless' => 'n'); 253 253 $working = 1; $mode = 0; 254 $attr = preg_replace('/^"[^"]*"(\s+|$ )/', '', $attr);254 $attr = preg_replace('/^"[^"]*"(\s+|$|\/)/', '', $attr); 255 255 break; 256 256 } 257 257 258 if (preg_match("/^'([^']*)'(\s+|$ )/", $attr, $match))258 if (preg_match("/^'([^']*)'(\s+|$|\/)/", $attr, $match)) 259 259 # 'value' 260 260 { … … 271 271 } 272 272 273 if (preg_match("%^([^\s\"']+)(\s+|$ )%", $attr, $match))273 if (preg_match("%^([^\s\"']+)(\s+|$|\/)%", $attr, $match)) 274 274 # value 275 275 {
