mirror of
https://github.com/Mottie/tablesorter.git
synced 2024-11-15 23:54:22 +00:00
Filter: Escape quotes in select options. See #1527
This commit is contained in:
parent
8703f25ba4
commit
aa113834db
@ -1783,13 +1783,13 @@
|
||||
options += '<option';
|
||||
for ( val in option ) {
|
||||
if ( option.hasOwnProperty( val ) && val !== 'text' ) {
|
||||
options += ' ' + val + '="' + option[ val ] + '"';
|
||||
options += ' ' + val + '="' + option[ val ].replace( tsfRegex.quote, '"' ) + '"';
|
||||
}
|
||||
}
|
||||
if ( !option.value ) {
|
||||
options += ' value="' + option.text + '"';
|
||||
options += ' value="' + option.text.replace( tsfRegex.quote, '"' ) + '"';
|
||||
}
|
||||
options += '>' + option.text + '</option>';
|
||||
options += '>' + option.text.replace( tsfRegex.quote, '"' ) + '</option>';
|
||||
// above code is needed in jQuery < v1.8
|
||||
|
||||
// make sure we don't turn an object into a string (objects without a "text" property)
|
||||
|
Loading…
Reference in New Issue
Block a user