Lines 578-585
jQuery.fn.dataTable.ext.errMode = function(settings, note, message) {
Link Here
|
578 |
|
578 |
|
579 |
function build_query(col, value){ |
579 |
function build_query(col, value){ |
580 |
|
580 |
|
581 |
// escape SQL special characters |
581 |
// escape SQL special character \ |
582 |
value = value.replace(/(\%|\_|\\)/g, "\\$1" ); |
582 |
value = value.replace(/(\\)/g, "\\$1" ); |
583 |
|
583 |
|
584 |
var parts = []; |
584 |
var parts = []; |
585 |
var attributes = col.data.split(':'); |
585 |
var attributes = col.data.split(':'); |
Lines 590-595
jQuery.fn.dataTable.ext.errMode = function(settings, note, message) {
Link Here
|
590 |
if ( value.match(/^\^(.*)\$$/) ) { |
590 |
if ( value.match(/^\^(.*)\$$/) ) { |
591 |
value = value.replace(/^\^/, '').replace(/\$$/, ''); |
591 |
value = value.replace(/^\^/, '').replace(/\$$/, ''); |
592 |
criteria = "exact"; |
592 |
criteria = "exact"; |
|
|
593 |
} else { |
594 |
// escape SQL LIKE special characters % and _ |
595 |
value = value.replace(/(\%|\_)/g, "\\$1"); |
593 |
} |
596 |
} |
594 |
part[!attr.includes('.')?'me.'+attr:attr] = criteria === 'exact' |
597 |
part[!attr.includes('.')?'me.'+attr:attr] = criteria === 'exact' |
595 |
? value |
598 |
? value |
596 |
- |
|
|