Commit 46d9402f authored by Aleksander Machniak's avatar Aleksander Machniak Committed by Thomas
Browse files

Fixed group expanding in IE7 (#369) - string[i] syntax doesn't work in IE, use...

Fixed group expanding in IE7 (#369) - string[i] syntax doesn't work in IE, use string.charAt(i) instead
parent 84c6b0a9
......@@ -81,16 +81,18 @@ function rcube_calendar_ui(settings)
{
var result = [],
strlen = str.length,
q, p, i;
q, p, i, char, last;
for (q = p = i = 0; i < strlen; i++) {
if (str[i] == '"' && str[i-1] != '\\') {
char = str.charAt(i);
if (char == '"' && last != '\\') {
q = !q;
}
else if (!q && str[i] == delimiter) {
else if (!q && char == delimiter) {
result.push(str.substring(p, i));
p = i + 1;
}
last = char;
}
result.push(str.substr(p));
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment