fix for attrib strings with embedded quotes

release-0.6
svncommit 16 years ago
parent 653242c663
commit f025740b07

@ -1483,7 +1483,7 @@ function create_attrib_string($attrib, $allowed_attribs=array('id', 'class', 'st
function parse_attrib_string($str)
{
$attrib = array();
preg_match_all('/\s*([-_a-z]+)=(["\'])??(?(2)([^"\']+)\2|(\S+?))/Ui', stripslashes($str), $regs, PREG_SET_ORDER);
preg_match_all('/\s*([-_a-z]+)=(["\'])??(?(2)([^\2]+)\2|(\S+?))/Ui', stripslashes($str), $regs, PREG_SET_ORDER);
// convert attributes to an associative array (name => value)
if ($regs)

Loading…
Cancel
Save