If you're OK with a feature test and function to replace a non–capturing split, try the following. It tests for support when the script is loaded and assigns an appropriate function to nonCaptureSplit, so the test is only done once.
The pattern will need to be escaped if you are using anything other than alphabetic characters or numerals (e.g. if there is punctuation in the string).
Edited
Now does a completely manual split if lacking support for non-capture split.
// Do case insensitive, non-capture split
var nonCaptureSplit = (function() {
// Feature test for non-capturing split
if ( 'ab'.split(/(a)/).length == 3) {
return function (str, pattern) {
var re = new RegExp('(' + pattern + ')','i');
return str.split(re);
};
// Otherise, do it with a function
} else {
return function(str, pattern) {
// Do case insensitive split
var result = [];
var ts = str.toLowerCase(); // copy of string in lower case
var tp = pattern.toLowerCase();
var first = true;
while (ts.indexOf(tp) != -1) {
var i = ts.indexOf(tp);
// If first match is at the start, insert empty string + pattern
// Trim pattern from front of temp strings
if (i == 0 && first) {
result.push('', pattern);
ts = ts.substring(tp.length);
str = str.substring(tp.length);
// If match is at the end, append pattern and ''
// Set temp string to '' (i.e. finished)
} else if (i == ts.length - tp.length) {
result.push(str.substr(0,i), pattern);
ts = '';
str = '';
// Otherwise, append the next unmatched part
// and pattern
} else {
result.push(str.substring(0,i), pattern);
ts = ts.substring(i + pattern.length);
str = str.substring(i + pattern.length);
}
first = false;
}
// Append remainder of string or '' if used, i.e. last match
// must have been at end of string
result.push( ts.length? str : '');
return result;
};
}
}());
tests:
alert(nonCaptureSplit('wa', 'wa')); // ,wa,
alert(nonCaptureSplit('qwqwaba', 'wa')); // qwq,wa,ba
alert(nonCaptureSplit('qwqwaba', 'qw')); // ,qw,,qw,aba
alert(nonCaptureSplit('qwqwaba', 'ba')); // qwqwa,ba,
alert(nonCaptureSplit('baaqwqbawaba', 'ba')); // ,ba,aqwq,ba,wa,ba,
alert(nonCaptureSplit("L'architecture du système d'information devient", "ARCH"));
// L',arch,itecture du système d'information devient
alert(nonCaptureSplit("ARCHIMAG", "ARCH")); // ,ARCH,IMAG
It might be a bit inefficient for large strings with lots of matches, but only in browsers without support for non–capturing split. Test results matched in Safari and IE 6. Please test thoroughly and let me know if there are issues.
Oh, this isn't a general solution, but it should work for the limited cases similar to the OP.