var cb = function(event, ui, cb1, cb2){
if(recursionFlag) return;
recursionFlag = true;
if (){
cb1(event, ui);
} else {
cb2(event, ui);
}
recursionFlag = false;
};
sliderInit(param1, param1, param1, param1, param1, null, function(event, ui){
cb(event, ui, function(event, ui){
//1/3
}, function(event, ui){
// 2/4
}
});
If you try to use mb_detect_encoding to detect whether a string is valid UTF-8,
use the strict mode, it is pretty worthless otherwise.
mb_detect_encoding($s, 'UTF-8', true)