function filterClasses(str) {
var classes = str.split(' ');
var new_classes = [];
for (var i = 0, length = classes.length; i < length; i++) {
if (classes[i].substring(0, 3) == 'js_') {
continue;
}
new_classes.push(classes[i]);
}
return new_classes.join(' ');
}
var str = 'js_class1 js_1first sex_woman sp it_b_woman js_disable js_stylerForm';
alert( filterClasses(str) );