|
Lines 88-93
my %scrubbertypes = (
Link Here
|
| 88 |
}, |
88 |
}, |
| 89 |
], |
89 |
], |
| 90 |
}, |
90 |
}, |
|
|
91 |
opac => { |
| 92 |
allow => [ |
| 93 |
qw( |
| 94 |
div span h1 h2 h3 h4 h5 h6 p br |
| 95 |
ul ol li dl dt dd |
| 96 |
a img svg |
| 97 |
strong b em i u |
| 98 |
hr |
| 99 |
) |
| 100 |
], |
| 101 |
rules => [ |
| 102 |
div => { |
| 103 |
class => qr/^[\w\s\-_]+$/, |
| 104 |
id => qr/^[\w\-_]+$/, |
| 105 |
}, |
| 106 |
|
| 107 |
span => { |
| 108 |
class => qr/^[\w\s\-_]+$/, |
| 109 |
id => qr/^[\w\-_]+$/, |
| 110 |
}, |
| 111 |
'svg' => { |
| 112 |
'id' => qr/^[\w\-_]+$/, |
| 113 |
'class' => qr/^[\w\s\-_]+$/, |
| 114 |
'data-barcode' => qr/^[\w\-_]+$/, |
| 115 |
'data-barcode-format' => qr/^[\w\-_]+$/, |
| 116 |
}, |
| 117 |
'img' => { |
| 118 |
'src' => qr/^(?:https?:\/\/|\/)/i, |
| 119 |
'alt' => 1, |
| 120 |
'class' => qr/^[\w\s\-_]+$/, |
| 121 |
'id' => qr/^[\w\-_]+$/, |
| 122 |
}, |
| 123 |
], |
| 124 |
} |
| 91 |
); |
125 |
); |
| 92 |
|
126 |
|
| 93 |
sub new { |
127 |
sub new { |