@@ -758,7 +758,7 @@ discard block |
||
758 | 758 | $current['loopcount'] = 1; |
759 | 759 | // the MaxCount is the max number of messages exported before |
760 | 760 | $current['maxCount'] = $counter + (($maxItems < $queuedMessages) ? $maxItems : $queuedMessages); |
761 | - $loop = true; // loop mode!! |
|
761 | + $loop = true; // loop mode!! |
|
762 | 762 | } |
763 | 763 | } |
764 | 764 | elseif ($queuedMessages == 0) { |
@@ -778,7 +778,7 @@ discard block |
||
778 | 778 | $this->ignore_messageid = $current['potential']; |
779 | 779 | } |
780 | 780 | $current['maxCount'] = $counter + (($maxItems < $queuedMessages) ? $maxItems : $queuedMessages); |
781 | - $loop = true; // loop mode!! |
|
781 | + $loop = true; // loop mode!! |
|
782 | 782 | } |
783 | 783 | } |
784 | 784 | } |
@@ -11,7 +11,7 @@ |
||
11 | 11 | public const UNAUTHENTICATED = 1; |
12 | 12 | public const UNPROVISIONED = 2; |
13 | 13 | public const NOACTIVESYNCCOMMAND = 3; |
14 | - public const WEBSERVICECOMMAND = 4; // DEPRECATED |
|
14 | + public const WEBSERVICECOMMAND = 4; // DEPRECATED |
|
15 | 15 | public const HIERARCHYCOMMAND = 5; |
16 | 16 | public const PLAININPUT = 6; |
17 | 17 | public const REQUESTHANDLER = 7; |
@@ -346,7 +346,7 @@ |
||
346 | 346 | $out = chr($byte) . $out; |
347 | 347 | } |
348 | 348 | else { |
349 | - $out = chr($byte | 0x80) . $out; |
|
349 | + $out = chr($byte|0x80) . $out; |
|
350 | 350 | } |
351 | 351 | } |
352 | 352 | fwrite($this->_out, $out); |
@@ -34,8 +34,7 @@ |
||
34 | 34 | if (!isset(self::$loopCounter[$name])) { |
35 | 35 | self::$loopCounter[$name] = 0; |
36 | 36 | } |
37 | - else { |
|
38 | - ++self::$loopCounter[$name]; |
|
37 | + else {++self::$loopCounter[$name]; |
|
39 | 38 | } |
40 | 39 | |
41 | 40 | if (self::$loopCounter[$name] > self::MAXLOOP) { |
@@ -410,22 +410,22 @@ |
||
410 | 410 | |
411 | 411 | for (; $i < $iMax; ++$i) { |
412 | 412 | switch ($string[$i]) { |
413 | - case '\\': |
|
414 | - ++$slashes; |
|
413 | + case '\\': |
|
414 | + ++$slashes; |
|
415 | 415 | |
416 | - break; |
|
416 | + break; |
|
417 | 417 | |
418 | - case '"': |
|
419 | - if ($slashes % 2 == 0) { |
|
420 | - $in_quote = !$in_quote; |
|
421 | - } |
|
422 | - // Fall through to default action below. |
|
418 | + case '"': |
|
419 | + if ($slashes % 2 == 0) { |
|
420 | + $in_quote = !$in_quote; |
|
421 | + } |
|
422 | + // Fall through to default action below. |
|
423 | 423 | |
424 | - // no break |
|
425 | - default: |
|
426 | - $slashes = 0; |
|
424 | + // no break |
|
425 | + default: |
|
426 | + $slashes = 0; |
|
427 | 427 | |
428 | - break; |
|
428 | + break; |
|
429 | 429 | } |
430 | 430 | } |
431 | 431 |
@@ -17,83 +17,83 @@ discard block |
||
17 | 17 | * Updated at: 01.06.2012 |
18 | 18 | */ |
19 | 19 | private static $mstzones = [ |
20 | - "000" => ["Dateline Standard Time", "(GMT-12:00) International Date Line West"], |
|
21 | - "001" => ["Samoa Standard Time", "(GMT-11:00) Midway Island, Samoa"], |
|
22 | - "002" => ["Hawaiian Standard Time", "(GMT-10:00) Hawaii"], |
|
23 | - "003" => ["Alaskan Standard Time", "(GMT-09:00) Alaska"], |
|
24 | - "004" => ["Pacific Standard Time", "(GMT-08:00) Pacific Time (US and Canada); Tijuana"], |
|
25 | - "010" => ["Mountain Standard Time", "(GMT-07:00) Mountain Time (US and Canada)"], |
|
26 | - "013" => ["Mexico Standard Time 2", "(GMT-07:00) Chihuahua, La Paz, Mazatlan"], |
|
27 | - "015" => ["US Mountain Standard Time", "(GMT-07:00) Arizona"], |
|
28 | - "020" => ["Central Standard Time", "(GMT-06:00) Central Time (US and Canada"], |
|
29 | - "025" => ["Canada Central Standard Time", "(GMT-06:00) Saskatchewan"], |
|
30 | - "030" => ["Mexico Standard Time", "(GMT-06:00) Guadalajara, Mexico City, Monterrey"], |
|
31 | - "033" => ["Central America Standard Time", "(GMT-06:00) Central America"], |
|
32 | - "035" => ["Eastern Standard Time", "(GMT-05:00) Eastern Time (US and Canada)"], |
|
33 | - "040" => ["US Eastern Standard Time", "(GMT-05:00) Indiana (East)"], |
|
34 | - "045" => ["SA Pacific Standard Time", "(GMT-05:00) Bogota, Lima, Quito"], |
|
35 | - "uk1" => ["Venezuela Standard Time", "(GMT-04:30) Caracas"], // added |
|
36 | - "050" => ["Atlantic Standard Time", "(GMT-04:00) Atlantic Time (Canada)"], |
|
37 | - "055" => ["SA Western Standard Time", "(GMT-04:00) Caracas, La Paz"], |
|
38 | - "056" => ["Pacific SA Standard Time", "(GMT-04:00) Santiago"], |
|
39 | - "060" => ["Newfoundland and Labrador Standard Time", "(GMT-03:30) Newfoundland and Labrador"], |
|
40 | - "065" => ["E South America Standard Time", "(GMT-03:00) Brasilia"], |
|
41 | - "070" => ["SA Eastern Standard Time", "(GMT-03:00) Buenos Aires, Georgetown"], |
|
42 | - "073" => ["Greenland Standard Time", "(GMT-03:00) Greenland"], |
|
43 | - "075" => ["Mid-Atlantic Standard Time", "(GMT-02:00) Mid-Atlantic"], |
|
44 | - "080" => ["Azores Standard Time", "(GMT-01:00) Azores"], |
|
45 | - "083" => ["Cape Verde Standard Time", "(GMT-01:00) Cape Verde Islands"], |
|
46 | - "085" => ["GMT Standard Time", "(GMT) Greenwich Mean Time: Dublin, Edinburgh, Lisbon, London"], |
|
47 | - "090" => ["Greenwich Standard Time", "(GMT) Casablanca, Monrovia"], |
|
48 | - "095" => ["Central Europe Standard Time", "(GMT+01:00) Belgrade, Bratislava, Budapest, Ljubljana, Prague"], |
|
49 | - "100" => ["Central European Standard Time", "(GMT+01:00) Sarajevo, Skopje, Warsaw, Zagreb"], |
|
50 | - "105" => ["Romance Standard Time", "(GMT+01:00) Brussels, Copenhagen, Madrid, Paris"], |
|
51 | - "110" => ["W Europe Standard Time", "(GMT+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna"], |
|
52 | - "111" => ["W. Europe Standard Time", "(GMT+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna"], |
|
53 | - "113" => ["W Central Africa Standard Time", "(GMT+01:00) West Central Africa"], |
|
54 | - "115" => ["E Europe Standard Time", "(GMT+02:00) Bucharest"], |
|
55 | - "120" => ["Egypt Standard Time", "(GMT+02:00) Cairo"], |
|
56 | - "125" => ["FLE Standard Time", "(GMT+02:00) Helsinki, Kiev, Riga, Sofia, Tallinn, Vilnius"], |
|
57 | - "130" => ["GTB Standard Time", "(GMT+02:00) Athens, Istanbul, Minsk"], |
|
58 | - "135" => ["Israel Standard Time", "(GMT+02:00) Jerusalem"], |
|
59 | - "140" => ["South Africa Standard Time", "(GMT+02:00) Harare, Pretoria"], |
|
60 | - "145" => ["Russian Standard Time", "(GMT+03:00) Moscow, St. Petersburg, Volgograd"], |
|
61 | - "150" => ["Arab Standard Time", "(GMT+03:00) Kuwait, Riyadh"], |
|
62 | - "155" => ["E Africa Standard Time", "(GMT+03:00) Nairobi"], |
|
63 | - "158" => ["Arabic Standard Time", "(GMT+03:00) Baghdad"], |
|
64 | - "160" => ["Iran Standard Time", "(GMT+03:30) Tehran"], |
|
65 | - "165" => ["Arabian Standard Time", "(GMT+04:00) Abu Dhabi, Muscat"], |
|
66 | - "170" => ["Caucasus Standard Time", "(GMT+04:00) Baku, Tbilisi, Yerevan"], |
|
20 | + "000" => ["Dateline Standard Time", "(GMT-12:00) International Date Line West"], |
|
21 | + "001" => ["Samoa Standard Time", "(GMT-11:00) Midway Island, Samoa"], |
|
22 | + "002" => ["Hawaiian Standard Time", "(GMT-10:00) Hawaii"], |
|
23 | + "003" => ["Alaskan Standard Time", "(GMT-09:00) Alaska"], |
|
24 | + "004" => ["Pacific Standard Time", "(GMT-08:00) Pacific Time (US and Canada); Tijuana"], |
|
25 | + "010" => ["Mountain Standard Time", "(GMT-07:00) Mountain Time (US and Canada)"], |
|
26 | + "013" => ["Mexico Standard Time 2", "(GMT-07:00) Chihuahua, La Paz, Mazatlan"], |
|
27 | + "015" => ["US Mountain Standard Time", "(GMT-07:00) Arizona"], |
|
28 | + "020" => ["Central Standard Time", "(GMT-06:00) Central Time (US and Canada"], |
|
29 | + "025" => ["Canada Central Standard Time", "(GMT-06:00) Saskatchewan"], |
|
30 | + "030" => ["Mexico Standard Time", "(GMT-06:00) Guadalajara, Mexico City, Monterrey"], |
|
31 | + "033" => ["Central America Standard Time", "(GMT-06:00) Central America"], |
|
32 | + "035" => ["Eastern Standard Time", "(GMT-05:00) Eastern Time (US and Canada)"], |
|
33 | + "040" => ["US Eastern Standard Time", "(GMT-05:00) Indiana (East)"], |
|
34 | + "045" => ["SA Pacific Standard Time", "(GMT-05:00) Bogota, Lima, Quito"], |
|
35 | + "uk1" => ["Venezuela Standard Time", "(GMT-04:30) Caracas"], // added |
|
36 | + "050" => ["Atlantic Standard Time", "(GMT-04:00) Atlantic Time (Canada)"], |
|
37 | + "055" => ["SA Western Standard Time", "(GMT-04:00) Caracas, La Paz"], |
|
38 | + "056" => ["Pacific SA Standard Time", "(GMT-04:00) Santiago"], |
|
39 | + "060" => ["Newfoundland and Labrador Standard Time", "(GMT-03:30) Newfoundland and Labrador"], |
|
40 | + "065" => ["E South America Standard Time", "(GMT-03:00) Brasilia"], |
|
41 | + "070" => ["SA Eastern Standard Time", "(GMT-03:00) Buenos Aires, Georgetown"], |
|
42 | + "073" => ["Greenland Standard Time", "(GMT-03:00) Greenland"], |
|
43 | + "075" => ["Mid-Atlantic Standard Time", "(GMT-02:00) Mid-Atlantic"], |
|
44 | + "080" => ["Azores Standard Time", "(GMT-01:00) Azores"], |
|
45 | + "083" => ["Cape Verde Standard Time", "(GMT-01:00) Cape Verde Islands"], |
|
46 | + "085" => ["GMT Standard Time", "(GMT) Greenwich Mean Time: Dublin, Edinburgh, Lisbon, London"], |
|
47 | + "090" => ["Greenwich Standard Time", "(GMT) Casablanca, Monrovia"], |
|
48 | + "095" => ["Central Europe Standard Time", "(GMT+01:00) Belgrade, Bratislava, Budapest, Ljubljana, Prague"], |
|
49 | + "100" => ["Central European Standard Time", "(GMT+01:00) Sarajevo, Skopje, Warsaw, Zagreb"], |
|
50 | + "105" => ["Romance Standard Time", "(GMT+01:00) Brussels, Copenhagen, Madrid, Paris"], |
|
51 | + "110" => ["W Europe Standard Time", "(GMT+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna"], |
|
52 | + "111" => ["W. Europe Standard Time", "(GMT+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna"], |
|
53 | + "113" => ["W Central Africa Standard Time", "(GMT+01:00) West Central Africa"], |
|
54 | + "115" => ["E Europe Standard Time", "(GMT+02:00) Bucharest"], |
|
55 | + "120" => ["Egypt Standard Time", "(GMT+02:00) Cairo"], |
|
56 | + "125" => ["FLE Standard Time", "(GMT+02:00) Helsinki, Kiev, Riga, Sofia, Tallinn, Vilnius"], |
|
57 | + "130" => ["GTB Standard Time", "(GMT+02:00) Athens, Istanbul, Minsk"], |
|
58 | + "135" => ["Israel Standard Time", "(GMT+02:00) Jerusalem"], |
|
59 | + "140" => ["South Africa Standard Time", "(GMT+02:00) Harare, Pretoria"], |
|
60 | + "145" => ["Russian Standard Time", "(GMT+03:00) Moscow, St. Petersburg, Volgograd"], |
|
61 | + "150" => ["Arab Standard Time", "(GMT+03:00) Kuwait, Riyadh"], |
|
62 | + "155" => ["E Africa Standard Time", "(GMT+03:00) Nairobi"], |
|
63 | + "158" => ["Arabic Standard Time", "(GMT+03:00) Baghdad"], |
|
64 | + "160" => ["Iran Standard Time", "(GMT+03:30) Tehran"], |
|
65 | + "165" => ["Arabian Standard Time", "(GMT+04:00) Abu Dhabi, Muscat"], |
|
66 | + "170" => ["Caucasus Standard Time", "(GMT+04:00) Baku, Tbilisi, Yerevan"], |
|
67 | 67 | "175" => ["Transitional Islamic State of Afghanistan Standard Time", "(GMT+04:30) Kabul"], |
68 | - "180" => ["Ekaterinburg Standard Time", "(GMT+05:00) Ekaterinburg"], |
|
69 | - "185" => ["West Asia Standard Time", "(GMT+05:00) Islamabad, Karachi, Tashkent"], |
|
70 | - "190" => ["India Standard Time", "(GMT+05:30) Chennai, Kolkata, Mumbai, New Delhi"], |
|
71 | - "193" => ["Nepal Standard Time", "(GMT+05:45) Kathmandu"], |
|
72 | - "195" => ["Central Asia Standard Time", "(GMT+06:00) Astana, Dhaka"], |
|
73 | - "200" => ["Sri Lanka Standard Time", "(GMT+06:00) Sri Jayawardenepura"], |
|
74 | - "201" => ["N Central Asia Standard Time", "(GMT+06:00) Almaty, Novosibirsk"], |
|
75 | - "203" => ["Myanmar Standard Time", "(GMT+06:30) Yangon Rangoon"], |
|
76 | - "205" => ["SE Asia Standard Time", "(GMT+07:00) Bangkok, Hanoi, Jakarta"], |
|
77 | - "207" => ["North Asia Standard Time", "(GMT+07:00) Krasnoyarsk"], |
|
78 | - "210" => ["China Standard Time", "(GMT+08:00) Beijing, Chongqing, Hong Kong SAR, Urumqi"], |
|
79 | - "215" => ["Singapore Standard Time", "(GMT+08:00) Kuala Lumpur, Singapore"], |
|
80 | - "220" => ["Taipei Standard Time", "(GMT+08:00) Taipei"], |
|
81 | - "225" => ["W Australia Standard Time", "(GMT+08:00) Perth"], |
|
82 | - "227" => ["North Asia East Standard Time", "(GMT+08:00) Irkutsk, Ulaanbaatar"], |
|
83 | - "230" => ["Korea Standard Time", "(GMT+09:00) Seoul"], |
|
84 | - "235" => ["Tokyo Standard Time", "(GMT+09:00) Osaka, Sapporo, Tokyo"], |
|
85 | - "240" => ["Yakutsk Standard Time", "(GMT+09:00) Yakutsk"], |
|
86 | - "245" => ["AUS Central Standard Time", "(GMT+09:30) Darwin"], |
|
87 | - "250" => ["Cen Australia Standard Time", "(GMT+09:30) Adelaide"], |
|
88 | - "255" => ["AUS Eastern Standard Time", "(GMT+10:00) Canberra, Melbourne, Sydney"], |
|
89 | - "260" => ["E Australia Standard Time", "(GMT+10:00) Brisbane"], |
|
90 | - "265" => ["Tasmania Standard Time", "(GMT+10:00) Hobart"], |
|
91 | - "270" => ["Vladivostok Standard Time", "(GMT+10:00) Vladivostok"], |
|
92 | - "275" => ["West Pacific Standard Time", "(GMT+10:00) Guam, Port Moresby"], |
|
93 | - "280" => ["Central Pacific Standard Time", "(GMT+11:00) Magadan, Solomon Islands, New Caledonia"], |
|
94 | - "285" => ["Fiji Islands Standard Time", "(GMT+12:00) Fiji Islands, Kamchatka, Marshall Islands"], |
|
95 | - "290" => ["New Zealand Standard Time", "(GMT+12:00) Auckland, Wellington"], |
|
96 | - "300" => ["Tonga Standard Time", "(GMT+13:00) Nuku'alofa"], |
|
68 | + "180" => ["Ekaterinburg Standard Time", "(GMT+05:00) Ekaterinburg"], |
|
69 | + "185" => ["West Asia Standard Time", "(GMT+05:00) Islamabad, Karachi, Tashkent"], |
|
70 | + "190" => ["India Standard Time", "(GMT+05:30) Chennai, Kolkata, Mumbai, New Delhi"], |
|
71 | + "193" => ["Nepal Standard Time", "(GMT+05:45) Kathmandu"], |
|
72 | + "195" => ["Central Asia Standard Time", "(GMT+06:00) Astana, Dhaka"], |
|
73 | + "200" => ["Sri Lanka Standard Time", "(GMT+06:00) Sri Jayawardenepura"], |
|
74 | + "201" => ["N Central Asia Standard Time", "(GMT+06:00) Almaty, Novosibirsk"], |
|
75 | + "203" => ["Myanmar Standard Time", "(GMT+06:30) Yangon Rangoon"], |
|
76 | + "205" => ["SE Asia Standard Time", "(GMT+07:00) Bangkok, Hanoi, Jakarta"], |
|
77 | + "207" => ["North Asia Standard Time", "(GMT+07:00) Krasnoyarsk"], |
|
78 | + "210" => ["China Standard Time", "(GMT+08:00) Beijing, Chongqing, Hong Kong SAR, Urumqi"], |
|
79 | + "215" => ["Singapore Standard Time", "(GMT+08:00) Kuala Lumpur, Singapore"], |
|
80 | + "220" => ["Taipei Standard Time", "(GMT+08:00) Taipei"], |
|
81 | + "225" => ["W Australia Standard Time", "(GMT+08:00) Perth"], |
|
82 | + "227" => ["North Asia East Standard Time", "(GMT+08:00) Irkutsk, Ulaanbaatar"], |
|
83 | + "230" => ["Korea Standard Time", "(GMT+09:00) Seoul"], |
|
84 | + "235" => ["Tokyo Standard Time", "(GMT+09:00) Osaka, Sapporo, Tokyo"], |
|
85 | + "240" => ["Yakutsk Standard Time", "(GMT+09:00) Yakutsk"], |
|
86 | + "245" => ["AUS Central Standard Time", "(GMT+09:30) Darwin"], |
|
87 | + "250" => ["Cen Australia Standard Time", "(GMT+09:30) Adelaide"], |
|
88 | + "255" => ["AUS Eastern Standard Time", "(GMT+10:00) Canberra, Melbourne, Sydney"], |
|
89 | + "260" => ["E Australia Standard Time", "(GMT+10:00) Brisbane"], |
|
90 | + "265" => ["Tasmania Standard Time", "(GMT+10:00) Hobart"], |
|
91 | + "270" => ["Vladivostok Standard Time", "(GMT+10:00) Vladivostok"], |
|
92 | + "275" => ["West Pacific Standard Time", "(GMT+10:00) Guam, Port Moresby"], |
|
93 | + "280" => ["Central Pacific Standard Time", "(GMT+11:00) Magadan, Solomon Islands, New Caledonia"], |
|
94 | + "285" => ["Fiji Islands Standard Time", "(GMT+12:00) Fiji Islands, Kamchatka, Marshall Islands"], |
|
95 | + "290" => ["New Zealand Standard Time", "(GMT+12:00) Auckland, Wellington"], |
|
96 | + "300" => ["Tonga Standard Time", "(GMT+13:00) Nuku'alofa"], |
|
97 | 97 | ]; |
98 | 98 | |
99 | 99 | /** |
@@ -127,104 +127,104 @@ discard block |
||
127 | 127 | * Created at: 01.06.2012 |
128 | 128 | */ |
129 | 129 | private static $tzonesoffsets = [ |
130 | - "Transitional Islamic State of Afghanistan Standard Time" => [-270, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
131 | - "Alaskan Standard Time" => [540, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
132 | - "Arab Standard Time" => [-180, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
133 | - "Arabian Standard Time" => [-240, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
134 | - "Arabic Standard Time" => [-180, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
130 | + "Transitional Islamic State of Afghanistan Standard Time" => [-270, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
131 | + "Alaskan Standard Time" => [540, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
132 | + "Arab Standard Time" => [-180, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
133 | + "Arabian Standard Time" => [-240, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
134 | + "Arabic Standard Time" => [-180, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
135 | 135 | // "Argentina Standard Time" => array(180, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
136 | - "Atlantic Standard Time" => [240, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
137 | - "AUS Central Standard Time" => [-570, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
138 | - "AUS Eastern Standard Time" => [-600, 0, -60, 0, 4, 0, 1, 3, 0, 0, 0, 0, 10, 0, 1, 2, 0, 0, 0], |
|
136 | + "Atlantic Standard Time" => [240, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
137 | + "AUS Central Standard Time" => [-570, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
138 | + "AUS Eastern Standard Time" => [-600, 0, -60, 0, 4, 0, 1, 3, 0, 0, 0, 0, 10, 0, 1, 2, 0, 0, 0], |
|
139 | 139 | // "Azerbaijan Standard Time" => array(-240, 0, -60, 0, 10, 0, 5, 5, 0, 0, 0, 0, 3, 0, 5, 4, 0, 0, 0), |
140 | - "Azores Standard Time" => [60, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
140 | + "Azores Standard Time" => [60, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
141 | 141 | // "Bangladesh Standard Time" => array(-360, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
142 | - "Canada Central Standard Time" => [360, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
143 | - "Cape Verde Standard Time" => [60, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
144 | - "Caucasus Standard Time" => [-240, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
145 | - "Cen Australia Standard Time" => [-570, 0, -60, 0, 4, 0, 1, 3, 0, 0, 0, 0, 10, 0, 1, 2, 0, 0, 0], |
|
146 | - "Central America Standard Time" => [360, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
147 | - "Central Asia Standard Time" => [-360, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
142 | + "Canada Central Standard Time" => [360, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
143 | + "Cape Verde Standard Time" => [60, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
144 | + "Caucasus Standard Time" => [-240, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
145 | + "Cen Australia Standard Time" => [-570, 0, -60, 0, 4, 0, 1, 3, 0, 0, 0, 0, 10, 0, 1, 2, 0, 0, 0], |
|
146 | + "Central America Standard Time" => [360, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
147 | + "Central Asia Standard Time" => [-360, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
148 | 148 | // "Central Brazilian Standard Time" => array(240, 0, -60, 0, 2, 6, 4, 23, 59, 59, 999, 0, 10, 6, 3, 23, 59, 59, 999), |
149 | - "Central Europe Standard Time" => [-60, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
150 | - "Central European Standard Time" => [-60, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
151 | - "Central Pacific Standard Time" => [-660, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
152 | - "Central Standard Time" => [360, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
153 | - "Mexico Standard Time" => [360, 0, -60, 0, 10, 0, 5, 2, 0, 0, 0, 0, 4, 0, 1, 2, 0, 0, 0], |
|
154 | - "China Standard Time" => [-480, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
155 | - "Dateline Standard Time" => [720, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
156 | - "E Africa Standard Time" => [-180, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
157 | - "E Australia Standard Time" => [-600, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
158 | - "E Europe Standard Time" => [-120, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
159 | - "E South America Standard Time" => [180, 0, -60, 0, 2, 6, 4, 23, 59, 59, 999, 0, 10, 6, 3, 23, 59, 59, 999], |
|
160 | - "Eastern Standard Time" => [300, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
161 | - "Egypt Standard Time" => [-120, 0, -60, 0, 9, 4, 5, 23, 59, 59, 999, 0, 4, 4, 5, 23, 59, 59, 999], |
|
162 | - "Ekaterinburg Standard Time" => [-300, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
163 | - "Fiji Islands Standard Time" => [-720, 0, -60, 0, 3, 0, 5, 3, 0, 0, 0, 0, 10, 0, 4, 2, 0, 0, 0], |
|
164 | - "FLE Standard Time" => [-120, 0, -60, 0, 10, 0, 5, 4, 0, 0, 0, 0, 3, 0, 5, 3, 0, 0, 0], |
|
149 | + "Central Europe Standard Time" => [-60, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
150 | + "Central European Standard Time" => [-60, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
151 | + "Central Pacific Standard Time" => [-660, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
152 | + "Central Standard Time" => [360, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
153 | + "Mexico Standard Time" => [360, 0, -60, 0, 10, 0, 5, 2, 0, 0, 0, 0, 4, 0, 1, 2, 0, 0, 0], |
|
154 | + "China Standard Time" => [-480, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
155 | + "Dateline Standard Time" => [720, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
156 | + "E Africa Standard Time" => [-180, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
157 | + "E Australia Standard Time" => [-600, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
158 | + "E Europe Standard Time" => [-120, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
159 | + "E South America Standard Time" => [180, 0, -60, 0, 2, 6, 4, 23, 59, 59, 999, 0, 10, 6, 3, 23, 59, 59, 999], |
|
160 | + "Eastern Standard Time" => [300, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
161 | + "Egypt Standard Time" => [-120, 0, -60, 0, 9, 4, 5, 23, 59, 59, 999, 0, 4, 4, 5, 23, 59, 59, 999], |
|
162 | + "Ekaterinburg Standard Time" => [-300, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
163 | + "Fiji Islands Standard Time" => [-720, 0, -60, 0, 3, 0, 5, 3, 0, 0, 0, 0, 10, 0, 4, 2, 0, 0, 0], |
|
164 | + "FLE Standard Time" => [-120, 0, -60, 0, 10, 0, 5, 4, 0, 0, 0, 0, 3, 0, 5, 3, 0, 0, 0], |
|
165 | 165 | // "Georgian Standard Time" => array(-240, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
166 | - "GMT Standard Time" => [0, 0, -60, 0, 10, 0, 5, 2, 0, 0, 0, 0, 3, 0, 5, 1, 0, 0, 0], |
|
167 | - "Greenland Standard Time" => [180, 0, -60, 0, 10, 6, 5, 23, 0, 0, 0, 0, 3, 6, 4, 22, 0, 0, 0], |
|
168 | - "Greenwich Standard Time" => [0, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
169 | - "GTB Standard Time" => [-120, 0, -60, 0, 10, 0, 5, 4, 0, 0, 0, 0, 3, 0, 5, 3, 0, 0, 0], |
|
170 | - "Hawaiian Standard Time" => [600, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
171 | - "India Standard Time" => [-330, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
172 | - "Iran Standard Time" => [-210, 0, -60, 0, 9, 1, 3, 23, 59, 59, 999, 0, 3, 6, 3, 23, 59, 59, 999], |
|
173 | - "Israel Standard Time" => [-120, 0, -60, 0, 9, 0, 4, 2, 0, 0, 0, 0, 3, 5, 5, 2, 0, 0, 0], |
|
166 | + "GMT Standard Time" => [0, 0, -60, 0, 10, 0, 5, 2, 0, 0, 0, 0, 3, 0, 5, 1, 0, 0, 0], |
|
167 | + "Greenland Standard Time" => [180, 0, -60, 0, 10, 6, 5, 23, 0, 0, 0, 0, 3, 6, 4, 22, 0, 0, 0], |
|
168 | + "Greenwich Standard Time" => [0, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
169 | + "GTB Standard Time" => [-120, 0, -60, 0, 10, 0, 5, 4, 0, 0, 0, 0, 3, 0, 5, 3, 0, 0, 0], |
|
170 | + "Hawaiian Standard Time" => [600, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
171 | + "India Standard Time" => [-330, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
172 | + "Iran Standard Time" => [-210, 0, -60, 0, 9, 1, 3, 23, 59, 59, 999, 0, 3, 6, 3, 23, 59, 59, 999], |
|
173 | + "Israel Standard Time" => [-120, 0, -60, 0, 9, 0, 4, 2, 0, 0, 0, 0, 3, 5, 5, 2, 0, 0, 0], |
|
174 | 174 | // "Jordan Standard Time" => array(-120, 0, -60, 0, 10, 5, 5, 1, 0, 0, 0, 0, 3, 4, 5, 23, 59, 59, 999), |
175 | 175 | // "Kamchatka Standard Time" => array(-720, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0), |
176 | - "Korea Standard Time" => [-540, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
176 | + "Korea Standard Time" => [-540, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
177 | 177 | // "Magadan Standard Time" => array(-660, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0), |
178 | 178 | // "Mauritius Standard Time" => array(-240, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
179 | - "Mid-Atlantic Standard Time" => [120, 0, -60, 0, 9, 0, 5, 2, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
179 | + "Mid-Atlantic Standard Time" => [120, 0, -60, 0, 9, 0, 5, 2, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
180 | 180 | // "Middle East Standard Time" => array(-120, 0, -60, 0, 10, 6, 5, 23, 59, 59, 999, 0, 3, 6, 4, 23, 59, 59, 999), |
181 | 181 | // "Montevideo Standard Time" => array(180, 0, -60, 0, 3, 0, 2, 2, 0, 0, 0, 0, 10, 0, 1, 2, 0, 0, 0), |
182 | 182 | // "Morocco Standard Time" => array(0, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
183 | - "Mountain Standard Time" => [420, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
184 | - "Mexico Standard Time 2" => [420, 0, -60, 0, 10, 0, 5, 2, 0, 0, 0, 0, 4, 0, 1, 2, 0, 0, 0], |
|
185 | - "Myanmar Standard Time" => [-390, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
186 | - "N Central Asia Standard Time" => [-360, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
183 | + "Mountain Standard Time" => [420, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
184 | + "Mexico Standard Time 2" => [420, 0, -60, 0, 10, 0, 5, 2, 0, 0, 0, 0, 4, 0, 1, 2, 0, 0, 0], |
|
185 | + "Myanmar Standard Time" => [-390, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
186 | + "N Central Asia Standard Time" => [-360, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
187 | 187 | // "Namibia Standard Time" => array(-60, 0, -60, 0, 4, 0, 1, 2, 0, 0, 0, 0, 9, 0, 1, 2, 0, 0, 0), |
188 | - "Nepal Standard Time" => [-345, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
189 | - "New Zealand Standard Time" => [-720, 0, -60, 0, 4, 0, 1, 3, 0, 0, 0, 0, 9, 0, 5, 2, 0, 0, 0], |
|
190 | - "Newfoundland and Labrador Standard Time" => [210, 0, -60, 0, 11, 0, 1, 0, 1, 0, 0, 0, 3, 0, 2, 0, 1, 0, 0], |
|
191 | - "North Asia East Standard Time" => [-480, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
192 | - "North Asia Standard Time" => [-420, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
193 | - "Pacific SA Standard Time" => [240, 0, -60, 0, 3, 6, 2, 23, 59, 59, 999, 0, 10, 6, 2, 23, 59, 59, 999], |
|
194 | - "Pacific Standard Time" => [480, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
188 | + "Nepal Standard Time" => [-345, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
189 | + "New Zealand Standard Time" => [-720, 0, -60, 0, 4, 0, 1, 3, 0, 0, 0, 0, 9, 0, 5, 2, 0, 0, 0], |
|
190 | + "Newfoundland and Labrador Standard Time" => [210, 0, -60, 0, 11, 0, 1, 0, 1, 0, 0, 0, 3, 0, 2, 0, 1, 0, 0], |
|
191 | + "North Asia East Standard Time" => [-480, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
192 | + "North Asia Standard Time" => [-420, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
193 | + "Pacific SA Standard Time" => [240, 0, -60, 0, 3, 6, 2, 23, 59, 59, 999, 0, 10, 6, 2, 23, 59, 59, 999], |
|
194 | + "Pacific Standard Time" => [480, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
195 | 195 | // "Pacific Standard Time (Mexico)" => array(480, 0, -60, 0, 10, 0, 5, 2, 0, 0, 0, 0, 4, 0, 1, 2, 0, 0, 0), |
196 | 196 | // "Pakistan Standard Time" => array(-300, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
197 | 197 | // "Paraguay Standard Time" => array(240, 0, -60, 0, 4, 6, 1, 23, 59, 59, 999, 0, 10, 6, 1, 23, 59, 59, 999), |
198 | - "Romance Standard Time" => [-60, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
199 | - "Russian Standard Time" => [-180, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
200 | - "SA Eastern Standard Time" => [180, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
201 | - "SA Pacific Standard Time" => [300, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
202 | - "SA Western Standard Time" => [240, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
203 | - "Samoa Standard Time" => [660, 0, -60, 0, 3, 6, 5, 23, 59, 59, 999, 0, 9, 6, 5, 23, 59, 59, 999], |
|
204 | - "SE Asia Standard Time" => [-420, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
205 | - "Singapore Standard Time" => [-480, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
206 | - "South Africa Standard Time" => [-120, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
207 | - "Sri Lanka Standard Time" => [-330, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
198 | + "Romance Standard Time" => [-60, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
199 | + "Russian Standard Time" => [-180, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
200 | + "SA Eastern Standard Time" => [180, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
201 | + "SA Pacific Standard Time" => [300, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
202 | + "SA Western Standard Time" => [240, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
203 | + "Samoa Standard Time" => [660, 0, -60, 0, 3, 6, 5, 23, 59, 59, 999, 0, 9, 6, 5, 23, 59, 59, 999], |
|
204 | + "SE Asia Standard Time" => [-420, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
205 | + "Singapore Standard Time" => [-480, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
206 | + "South Africa Standard Time" => [-120, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
207 | + "Sri Lanka Standard Time" => [-330, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
208 | 208 | // "Syria Standard Time" => array(-120, 0, -60, 0, 10, 4, 5, 23, 59, 59, 999, 0, 4, 4, 1, 23, 59, 59, 999), |
209 | - "Taipei Standard Time" => [-480, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
210 | - "Tasmania Standard Time" => [-600, 0, -60, 0, 4, 0, 1, 3, 0, 0, 0, 0, 10, 0, 1, 2, 0, 0, 0], |
|
211 | - "Tokyo Standard Time" => [-540, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
212 | - "Tonga Standard Time" => [-780, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
209 | + "Taipei Standard Time" => [-480, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
210 | + "Tasmania Standard Time" => [-600, 0, -60, 0, 4, 0, 1, 3, 0, 0, 0, 0, 10, 0, 1, 2, 0, 0, 0], |
|
211 | + "Tokyo Standard Time" => [-540, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
212 | + "Tonga Standard Time" => [-780, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
213 | 213 | // "Ulaanbaatar Standard Time" => array(-480, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
214 | - "US Eastern Standard Time" => [300, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
215 | - "US Mountain Standard Time" => [420, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
214 | + "US Eastern Standard Time" => [300, 0, -60, 0, 11, 0, 1, 2, 0, 0, 0, 0, 3, 0, 2, 2, 0, 0, 0], |
|
215 | + "US Mountain Standard Time" => [420, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
216 | 216 | // "UTC" => array(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
217 | 217 | // "UTC+12" => array(-720, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
218 | 218 | // "UTC-02" => array(120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
219 | 219 | // "UTC-11" => array(660, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), |
220 | - "Venezuela Standard Time" => [270, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
221 | - "Vladivostok Standard Time" => [-600, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
222 | - "W Australia Standard Time" => [-480, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
223 | - "W Central Africa Standard Time" => [-60, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
224 | - "W Europe Standard Time" => [-60, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
225 | - "West Asia Standard Time" => [-300, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
226 | - "West Pacific Standard Time" => [-600, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
227 | - "Yakutsk Standard Time" => [-540, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
220 | + "Venezuela Standard Time" => [270, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
221 | + "Vladivostok Standard Time" => [-600, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
222 | + "W Australia Standard Time" => [-480, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
223 | + "W Central Africa Standard Time" => [-60, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
224 | + "W Europe Standard Time" => [-60, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
225 | + "West Asia Standard Time" => [-300, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
226 | + "West Pacific Standard Time" => [-600, 0, -60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], |
|
227 | + "Yakutsk Standard Time" => [-540, 0, -60, 0, 10, 0, 5, 3, 0, 0, 0, 0, 3, 0, 5, 2, 0, 0, 0], |
|
228 | 228 | ]; |
229 | 229 | |
230 | 230 | /** |
@@ -23,12 +23,12 @@ discard block |
||
23 | 23 | * carried in the IPM.TaskRequest item (although this information seems |
24 | 24 | * redundant due to that information already being available in PR_MESSAGE_CLASS). |
25 | 25 | */ |
26 | - define('tdmtNothing', 0); // Value in IPM.Task items |
|
27 | - define('tdmtTaskReq', 1); // Assigner -> Assignee |
|
28 | - define('tdmtTaskAcc', 2); // Assignee -> Assigner |
|
29 | - define('tdmtTaskDec', 3); // Assignee -> Assigner |
|
30 | - define('tdmtTaskUpd', 4); // Assignee -> Assigner |
|
31 | - define('tdmtTaskSELF', 5); // Assigner -> Assigner (?) |
|
26 | + define('tdmtNothing', 0); // Value in IPM.Task items |
|
27 | + define('tdmtTaskReq', 1); // Assigner -> Assignee |
|
28 | + define('tdmtTaskAcc', 2); // Assignee -> Assigner |
|
29 | + define('tdmtTaskDec', 3); // Assignee -> Assigner |
|
30 | + define('tdmtTaskUpd', 4); // Assignee -> Assigner |
|
31 | + define('tdmtTaskSELF', 5); // Assigner -> Assigner (?) |
|
32 | 32 | |
33 | 33 | /* The TaskHistory is used to show the last action on the task |
34 | 34 | * on both the assigner and the assignee's side. |
@@ -38,22 +38,22 @@ discard block |
||
38 | 38 | * the format 'Accepted by <user> on 01-01-2010 11:00'. |
39 | 39 | */ |
40 | 40 | define('thNone', 0); |
41 | - define('thAccepted', 1); // Set by assignee |
|
42 | - define('thDeclined', 2); // Set by assignee |
|
43 | - define('thUpdated', 3); // Set by assignee |
|
41 | + define('thAccepted', 1); // Set by assignee |
|
42 | + define('thDeclined', 2); // Set by assignee |
|
43 | + define('thUpdated', 3); // Set by assignee |
|
44 | 44 | define('thDueDateChanged', 4); |
45 | - define('thAssigned', 5); // Set by assigner |
|
45 | + define('thAssigned', 5); // Set by assigner |
|
46 | 46 | |
47 | 47 | /* The TaskState value is used to differentiate the version of a task |
48 | 48 | * in the assigner's folder and the version in the |
49 | 49 | * assignee's folder. The buttons shown depend on this and |
50 | 50 | * the 'taskaccepted' boolean (for the assignee) |
51 | 51 | */ |
52 | - define('tdsNOM', 0); // Got a response to a deleted task, and re-created the task for the assigner |
|
53 | - define('tdsOWNNEW', 1); // Not assigned |
|
54 | - define('tdsOWN', 2); // Assignee version |
|
55 | - define('tdsACC', 3); // Assigner version |
|
56 | - define('tdsDEC', 4); // Assigner version, but assignee declined |
|
52 | + define('tdsNOM', 0); // Got a response to a deleted task, and re-created the task for the assigner |
|
53 | + define('tdsOWNNEW', 1); // Not assigned |
|
54 | + define('tdsOWN', 2); // Assignee version |
|
55 | + define('tdsACC', 3); // Assigner version |
|
56 | + define('tdsDEC', 4); // Assigner version, but assignee declined |
|
57 | 57 | |
58 | 58 | /* The TaskAcceptanceState is used for the assigner to indicate state */ |
59 | 59 | define('olTaskNotDelegated', 0); |
@@ -63,13 +63,13 @@ discard block |
||
63 | 63 | |
64 | 64 | /* The task ownership indicates the role of the current user relative to the task. */ |
65 | 65 | define('olNewTask', 0); |
66 | - define('olDelegatedTask', 1); // Task has been assigned |
|
67 | - define('olOwnTask', 2); // Task owned |
|
66 | + define('olDelegatedTask', 1); // Task has been assigned |
|
67 | + define('olOwnTask', 2); // Task owned |
|
68 | 68 | |
69 | 69 | /* taskmultrecips indicates whether the task request sent or received has multiple assignees or not. */ |
70 | 70 | define('tmrNone', 0); |
71 | - define('tmrSent', 1); // Task has been sent to multiple assignee |
|
72 | - define('tmrReceived', 2); // Task Request received has multiple assignee |
|
71 | + define('tmrSent', 1); // Task has been sent to multiple assignee |
|
72 | + define('tmrReceived', 2); // Task Request received has multiple assignee |
|
73 | 73 | |
74 | 74 | // Task icon index. |
75 | 75 | define('ICON_TASK_ASSIGNEE', 0x00000502); |
@@ -307,7 +307,7 @@ discard block |
||
307 | 307 | VALUE => $goid, ], |
308 | 308 | ]; |
309 | 309 | |
310 | - $table = mapi_folder_getcontentstable($folder, MAPI_DEFERRED_ERRORS | SHOW_SOFT_DELETES); |
|
310 | + $table = mapi_folder_getcontentstable($folder, MAPI_DEFERRED_ERRORS|SHOW_SOFT_DELETES); |
|
311 | 311 | $softDeletedItems = mapi_table_queryallrows($table, [PR_ENTRYID], $restriction); |
312 | 312 | if (!empty($softDeletedItems)) { |
313 | 313 | return true; |
@@ -515,14 +515,14 @@ discard block |
||
515 | 515 | // Set properties on Task Request |
516 | 516 | mapi_setprops($this->message, [ |
517 | 517 | $this->props['task_goid'] => $taskid, /* our new task_goid */ |
518 | - $this->props['taskstate'] => tdsACC, /* state for our outgoing request */ |
|
519 | - $this->props['taskmode'] => tdmtNothing, /* we're not sending a change */ |
|
520 | - $this->props['updatecount'] => 2, /* version 2 (no idea) */ |
|
518 | + $this->props['taskstate'] => tdsACC, /* state for our outgoing request */ |
|
519 | + $this->props['taskmode'] => tdmtNothing, /* we're not sending a change */ |
|
520 | + $this->props['updatecount'] => 2, /* version 2 (no idea) */ |
|
521 | 521 | $this->props['task_acceptance_state'] => olTaskDelegationUnknown, /* no reply yet */ |
522 | 522 | $this->props['ownership'] => olDelegatedTask, /* Task has been assigned */ |
523 | - $this->props['taskhistory'] => thAssigned, /* Task has been assigned */ |
|
523 | + $this->props['taskhistory'] => thAssigned, /* Task has been assigned */ |
|
524 | 524 | PR_CONVERSATION_TOPIC => $messageprops[PR_SUBJECT], |
525 | - PR_ICON_INDEX => ICON_TASK_ASSIGNER, /* Task request icon */ |
|
525 | + PR_ICON_INDEX => ICON_TASK_ASSIGNER, /* Task request icon */ |
|
526 | 526 | ]); |
527 | 527 | $this->setLastUser(); |
528 | 528 | $this->setOwnerForAssignor(); |
@@ -537,10 +537,10 @@ discard block |
||
537 | 537 | |
538 | 538 | // Make it a task request, and put it in sent items after it is sent |
539 | 539 | mapi_setprops($outgoing, [ |
540 | - PR_MESSAGE_CLASS => "IPM.TaskRequest", /* class is task request */ |
|
541 | - $this->props['taskstate'] => tdsOWN, /* for the recipient he is the task owner */ |
|
542 | - $this->props['taskmode'] => tdmtTaskReq, /* for the recipient it's a request */ |
|
543 | - $this->props['updatecount'] => 1, /* version 2 is in the attachment */ |
|
540 | + PR_MESSAGE_CLASS => "IPM.TaskRequest", /* class is task request */ |
|
541 | + $this->props['taskstate'] => tdsOWN, /* for the recipient he is the task owner */ |
|
542 | + $this->props['taskmode'] => tdmtTaskReq, /* for the recipient it's a request */ |
|
543 | + $this->props['updatecount'] => 1, /* version 2 is in the attachment */ |
|
544 | 544 | PR_SUBJECT_PREFIX => $prefix, |
545 | 545 | PR_SUBJECT => $prefix . $messageprops[PR_SUBJECT], |
546 | 546 | ]); |
@@ -551,7 +551,7 @@ discard block |
||
551 | 551 | PR_ATTACHMENT_HIDDEN => true, |
552 | 552 | PR_DISPLAY_NAME => $messageprops[PR_SUBJECT], ]); |
553 | 553 | |
554 | - $sub = mapi_attach_openproperty($attach, PR_ATTACH_DATA_OBJ, IID_IMessage, 0, MAPI_MODIFY | MAPI_CREATE); |
|
554 | + $sub = mapi_attach_openproperty($attach, PR_ATTACH_DATA_OBJ, IID_IMessage, 0, MAPI_MODIFY|MAPI_CREATE); |
|
555 | 555 | |
556 | 556 | mapi_copyto($this->message, [], [], $sub); |
557 | 557 | mapi_savechanges($sub); |
@@ -890,7 +890,7 @@ discard block |
||
890 | 890 | |
891 | 891 | $attach = mapi_message_createattach($outgoing); |
892 | 892 | mapi_setprops($attach, [PR_ATTACH_METHOD => ATTACH_EMBEDDED_MSG, PR_DISPLAY_NAME => $messageprops[PR_CONVERSATION_TOPIC], PR_ATTACHMENT_HIDDEN => true]); |
893 | - $sub = mapi_attach_openproperty($attach, PR_ATTACH_DATA_OBJ, IID_IMessage, 0, MAPI_CREATE | MAPI_MODIFY); |
|
893 | + $sub = mapi_attach_openproperty($attach, PR_ATTACH_DATA_OBJ, IID_IMessage, 0, MAPI_CREATE|MAPI_MODIFY); |
|
894 | 894 | |
895 | 895 | $message = !$this->isTaskRequest() ? $this->message : $this->getAssociatedTask(false); |
896 | 896 | |
@@ -943,7 +943,7 @@ discard block |
||
943 | 943 | // edit response before sending task response. |
944 | 944 | if ($this->taskCommentsInfo) { |
945 | 945 | $comments = $this->getTaskCommentsInfo(); |
946 | - $stream = mapi_openproperty($outgoing, PR_BODY, IID_IStream, STGM_TRANSACTED, MAPI_CREATE | MAPI_MODIFY); |
|
946 | + $stream = mapi_openproperty($outgoing, PR_BODY, IID_IStream, STGM_TRANSACTED, MAPI_CREATE|MAPI_MODIFY); |
|
947 | 947 | mapi_stream_setsize($stream, strlen($comments)); |
948 | 948 | mapi_stream_write($stream, $comments); |
949 | 949 | mapi_stream_commit($stream); |
@@ -1206,7 +1206,7 @@ discard block |
||
1206 | 1206 | } |
1207 | 1207 | |
1208 | 1208 | foreach ($recips as $recip) { |
1209 | - $recip[PR_RECIPIENT_TYPE] = MAPI_TO; // Change recipient type to MAPI_TO |
|
1209 | + $recip[PR_RECIPIENT_TYPE] = MAPI_TO; // Change recipient type to MAPI_TO |
|
1210 | 1210 | mapi_message_modifyrecipients($outgoing, MODRECIP_ADD, [$recip]); |
1211 | 1211 | } |
1212 | 1212 |
@@ -1739,193 +1739,193 @@ |
||
1739 | 1739 | // Loop through the entire recurrence range of dates, and check for each occurrence whether it is in the view range. |
1740 | 1740 | |
1741 | 1741 | switch ($this->recur["type"]) { |
1742 | - case 10: |
|
1743 | - // Daily |
|
1744 | - if ($this->recur["everyn"] <= 0) { |
|
1745 | - $this->recur["everyn"] = 1440; |
|
1746 | - } |
|
1747 | - |
|
1748 | - if ($this->recur["subtype"] == 0) { |
|
1749 | - // Every Nth day |
|
1750 | - for ($now = $daystart; $now <= $dayend && ($limit == 0 || count($items) < $limit); $now += 60 * $this->recur["everyn"]) { |
|
1751 | - $this->processOccurrenceItem($items, $start, $end, $now, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1742 | + case 10: |
|
1743 | + // Daily |
|
1744 | + if ($this->recur["everyn"] <= 0) { |
|
1745 | + $this->recur["everyn"] = 1440; |
|
1752 | 1746 | } |
1753 | - } |
|
1754 | - else { |
|
1755 | - // Every workday |
|
1756 | - for ($now = $daystart; $now <= $dayend && ($limit == 0 || count($items) < $limit); $now += 60 * 1440) { |
|
1757 | - $nowtime = $this->gmtime($now); |
|
1758 | - if ($nowtime["tm_wday"] > 0 && $nowtime["tm_wday"] < 6) { // only add items in the given timespace |
|
1747 | + |
|
1748 | + if ($this->recur["subtype"] == 0) { |
|
1749 | + // Every Nth day |
|
1750 | + for ($now = $daystart; $now <= $dayend && ($limit == 0 || count($items) < $limit); $now += 60 * $this->recur["everyn"]) { |
|
1759 | 1751 | $this->processOccurrenceItem($items, $start, $end, $now, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
1760 | 1752 | } |
1761 | 1753 | } |
1762 | - } |
|
1763 | - |
|
1764 | - break; |
|
1754 | + else { |
|
1755 | + // Every workday |
|
1756 | + for ($now = $daystart; $now <= $dayend && ($limit == 0 || count($items) < $limit); $now += 60 * 1440) { |
|
1757 | + $nowtime = $this->gmtime($now); |
|
1758 | + if ($nowtime["tm_wday"] > 0 && $nowtime["tm_wday"] < 6) { // only add items in the given timespace |
|
1759 | + $this->processOccurrenceItem($items, $start, $end, $now, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1760 | + } |
|
1761 | + } |
|
1762 | + } |
|
1765 | 1763 | |
1766 | - case 11: |
|
1767 | - // Weekly |
|
1768 | - if ($this->recur["everyn"] <= 0) { |
|
1769 | - $this->recur["everyn"] = 1; |
|
1770 | - } |
|
1764 | + break; |
|
1771 | 1765 | |
1772 | - // If sliding flag is set then move to 'n' weeks |
|
1773 | - if ($this->recur['regen']) { |
|
1774 | - $daystart += (60 * 60 * 24 * 7 * $this->recur["everyn"]); |
|
1775 | - } |
|
1766 | + case 11: |
|
1767 | + // Weekly |
|
1768 | + if ($this->recur["everyn"] <= 0) { |
|
1769 | + $this->recur["everyn"] = 1; |
|
1770 | + } |
|
1776 | 1771 | |
1777 | - for ($now = $daystart; $now <= $dayend && ($limit == 0 || count($items) < $limit); $now += (60 * 60 * 24 * 7 * $this->recur["everyn"])) { |
|
1772 | + // If sliding flag is set then move to 'n' weeks |
|
1778 | 1773 | if ($this->recur['regen']) { |
1779 | - $this->processOccurrenceItem($items, $start, $end, $now, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1774 | + $daystart += (60 * 60 * 24 * 7 * $this->recur["everyn"]); |
|
1780 | 1775 | } |
1781 | - else { |
|
1782 | - // Loop through the whole following week to the first occurrence of the week, add each day that is specified |
|
1783 | - for ($wday = 0; $wday < 7; ++$wday) { |
|
1784 | - $daynow = $now + $wday * 60 * 60 * 24; |
|
1785 | - // checks weather the next coming day in recurring pattern is less than or equal to end day of the recurring item |
|
1786 | - if ($daynow <= $dayend) { |
|
1787 | - $nowtime = $this->gmtime($daynow); // Get the weekday of the current day |
|
1788 | - if (($this->recur["weekdays"] & (1 << $nowtime["tm_wday"]))) { // Selected ? |
|
1789 | - $this->processOccurrenceItem($items, $start, $end, $daynow, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1776 | + |
|
1777 | + for ($now = $daystart; $now <= $dayend && ($limit == 0 || count($items) < $limit); $now += (60 * 60 * 24 * 7 * $this->recur["everyn"])) { |
|
1778 | + if ($this->recur['regen']) { |
|
1779 | + $this->processOccurrenceItem($items, $start, $end, $now, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1780 | + } |
|
1781 | + else { |
|
1782 | + // Loop through the whole following week to the first occurrence of the week, add each day that is specified |
|
1783 | + for ($wday = 0; $wday < 7; ++$wday) { |
|
1784 | + $daynow = $now + $wday * 60 * 60 * 24; |
|
1785 | + // checks weather the next coming day in recurring pattern is less than or equal to end day of the recurring item |
|
1786 | + if ($daynow <= $dayend) { |
|
1787 | + $nowtime = $this->gmtime($daynow); // Get the weekday of the current day |
|
1788 | + if (($this->recur["weekdays"] & (1 << $nowtime["tm_wday"]))) { // Selected ? |
|
1789 | + $this->processOccurrenceItem($items, $start, $end, $daynow, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1790 | + } |
|
1790 | 1791 | } |
1791 | 1792 | } |
1792 | 1793 | } |
1793 | 1794 | } |
1794 | - } |
|
1795 | 1795 | |
1796 | - break; |
|
1797 | - |
|
1798 | - case 12: |
|
1799 | - // Monthly |
|
1800 | - if ($this->recur["everyn"] <= 0) { |
|
1801 | - $this->recur["everyn"] = 1; |
|
1802 | - } |
|
1796 | + break; |
|
1803 | 1797 | |
1804 | - // Loop through all months from start to end of occurrence, starting at beginning of first month |
|
1805 | - for ($now = $this->monthStartOf($daystart); $now <= $dayend && ($limit == 0 || count($items) < $limit); $now += $this->daysInMonth($now, $this->recur["everyn"]) * 24 * 60 * 60) { |
|
1806 | - if (isset($this->recur["monthday"]) && ($this->recur['monthday'] != "undefined") && !$this->recur['regen']) { // Day M of every N months |
|
1807 | - $difference = 1; |
|
1808 | - if ($this->daysInMonth($now, $this->recur["everyn"]) < $this->recur["monthday"]) { |
|
1809 | - $difference = $this->recur["monthday"] - $this->daysInMonth($now, $this->recur["everyn"]) + 1; |
|
1810 | - } |
|
1811 | - $daynow = $now + (($this->recur["monthday"] - $difference) * 24 * 60 * 60); |
|
1812 | - // checks weather the next coming day in recurrence pattern is less than or equal to end day of the recurring item |
|
1813 | - if ($daynow <= $dayend) { |
|
1814 | - $this->processOccurrenceItem($items, $start, $end, $daynow, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1815 | - } |
|
1798 | + case 12: |
|
1799 | + // Monthly |
|
1800 | + if ($this->recur["everyn"] <= 0) { |
|
1801 | + $this->recur["everyn"] = 1; |
|
1816 | 1802 | } |
1817 | - elseif (isset($this->recur["nday"], $this->recur["weekdays"])) { // Nth [weekday] of every N months |
|
1818 | - // Sanitize input |
|
1819 | - if ($this->recur["weekdays"] == 0) { |
|
1820 | - $this->recur["weekdays"] = 1; |
|
1821 | - } |
|
1822 | 1803 | |
1823 | - // If nday is not set to the last day in the month |
|
1824 | - if ($this->recur["nday"] < 5) { |
|
1825 | - // keep the track of no. of time correct selection pattern(like 2nd weekday, 4th fiday, etc.)is matched |
|
1826 | - $ndaycounter = 0; |
|
1827 | - // Find matching weekday in this month |
|
1828 | - for ($day = 0, $total = $this->daysInMonth($now, 1); $day < $total; ++$day) { |
|
1829 | - $daynow = $now + $day * 60 * 60 * 24; |
|
1830 | - $nowtime = $this->gmtime($daynow); // Get the weekday of the current day |
|
1804 | + // Loop through all months from start to end of occurrence, starting at beginning of first month |
|
1805 | + for ($now = $this->monthStartOf($daystart); $now <= $dayend && ($limit == 0 || count($items) < $limit); $now += $this->daysInMonth($now, $this->recur["everyn"]) * 24 * 60 * 60) { |
|
1806 | + if (isset($this->recur["monthday"]) && ($this->recur['monthday'] != "undefined") && !$this->recur['regen']) { // Day M of every N months |
|
1807 | + $difference = 1; |
|
1808 | + if ($this->daysInMonth($now, $this->recur["everyn"]) < $this->recur["monthday"]) { |
|
1809 | + $difference = $this->recur["monthday"] - $this->daysInMonth($now, $this->recur["everyn"]) + 1; |
|
1810 | + } |
|
1811 | + $daynow = $now + (($this->recur["monthday"] - $difference) * 24 * 60 * 60); |
|
1812 | + // checks weather the next coming day in recurrence pattern is less than or equal to end day of the recurring item |
|
1813 | + if ($daynow <= $dayend) { |
|
1814 | + $this->processOccurrenceItem($items, $start, $end, $daynow, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1815 | + } |
|
1816 | + } |
|
1817 | + elseif (isset($this->recur["nday"], $this->recur["weekdays"])) { // Nth [weekday] of every N months |
|
1818 | + // Sanitize input |
|
1819 | + if ($this->recur["weekdays"] == 0) { |
|
1820 | + $this->recur["weekdays"] = 1; |
|
1821 | + } |
|
1831 | 1822 | |
1832 | - if ($this->recur["weekdays"] & (1 << $nowtime["tm_wday"])) { // Selected ? |
|
1833 | - ++$ndaycounter; |
|
1834 | - } |
|
1835 | - // check the selected pattern is same as asked Nth weekday,If so set the firstday |
|
1836 | - if ($this->recur["nday"] == $ndaycounter) { |
|
1837 | - $firstday = $day; |
|
1823 | + // If nday is not set to the last day in the month |
|
1824 | + if ($this->recur["nday"] < 5) { |
|
1825 | + // keep the track of no. of time correct selection pattern(like 2nd weekday, 4th fiday, etc.)is matched |
|
1826 | + $ndaycounter = 0; |
|
1827 | + // Find matching weekday in this month |
|
1828 | + for ($day = 0, $total = $this->daysInMonth($now, 1); $day < $total; ++$day) { |
|
1829 | + $daynow = $now + $day * 60 * 60 * 24; |
|
1830 | + $nowtime = $this->gmtime($daynow); // Get the weekday of the current day |
|
1831 | + |
|
1832 | + if ($this->recur["weekdays"] & (1 << $nowtime["tm_wday"])) { // Selected ? |
|
1833 | + ++$ndaycounter; |
|
1834 | + } |
|
1835 | + // check the selected pattern is same as asked Nth weekday,If so set the firstday |
|
1836 | + if ($this->recur["nday"] == $ndaycounter) { |
|
1837 | + $firstday = $day; |
|
1838 | 1838 | |
1839 | - break; |
|
1839 | + break; |
|
1840 | + } |
|
1840 | 1841 | } |
1842 | + // $firstday is the day of the month on which the asked pattern of nth weekday matches |
|
1843 | + $daynow = $now + $firstday * 60 * 60 * 24; |
|
1841 | 1844 | } |
1842 | - // $firstday is the day of the month on which the asked pattern of nth weekday matches |
|
1843 | - $daynow = $now + $firstday * 60 * 60 * 24; |
|
1844 | - } |
|
1845 | - else { |
|
1846 | - // Find last day in the month ($now is the firstday of the month) |
|
1847 | - $NumDaysInMonth = $this->daysInMonth($now, 1); |
|
1848 | - $daynow = $now + (($NumDaysInMonth - 1) * 24 * 60 * 60); |
|
1845 | + else { |
|
1846 | + // Find last day in the month ($now is the firstday of the month) |
|
1847 | + $NumDaysInMonth = $this->daysInMonth($now, 1); |
|
1848 | + $daynow = $now + (($NumDaysInMonth - 1) * 24 * 60 * 60); |
|
1849 | 1849 | |
1850 | - $nowtime = $this->gmtime($daynow); |
|
1851 | - while (($this->recur["weekdays"] & (1 << $nowtime["tm_wday"])) == 0) { |
|
1852 | - $daynow -= 86400; |
|
1853 | 1850 | $nowtime = $this->gmtime($daynow); |
1851 | + while (($this->recur["weekdays"] & (1 << $nowtime["tm_wday"])) == 0) { |
|
1852 | + $daynow -= 86400; |
|
1853 | + $nowtime = $this->gmtime($daynow); |
|
1854 | + } |
|
1854 | 1855 | } |
1855 | - } |
|
1856 | 1856 | |
1857 | - /* |
|
1857 | + /* |
|
1858 | 1858 | * checks weather the next coming day in recurrence pattern is less than or equal to end day of the * recurring item.Also check weather the coming day in recurrence pattern is greater than or equal to start * of recurring pattern, so that appointment that fall under the recurrence range are only displayed. |
1859 | 1859 | */ |
1860 | - if ($daynow <= $dayend && $daynow >= $daystart) { |
|
1861 | - $this->processOccurrenceItem($items, $start, $end, $daynow, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1860 | + if ($daynow <= $dayend && $daynow >= $daystart) { |
|
1861 | + $this->processOccurrenceItem($items, $start, $end, $daynow, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1862 | + } |
|
1862 | 1863 | } |
1863 | - } |
|
1864 | - elseif ($this->recur['regen']) { |
|
1865 | - $next_month_start = $now + ($this->daysInMonth($now, 1) * 24 * 60 * 60); |
|
1866 | - $now = $daystart + ($this->daysInMonth($next_month_start, $this->recur['everyn']) * 24 * 60 * 60); |
|
1864 | + elseif ($this->recur['regen']) { |
|
1865 | + $next_month_start = $now + ($this->daysInMonth($now, 1) * 24 * 60 * 60); |
|
1866 | + $now = $daystart + ($this->daysInMonth($next_month_start, $this->recur['everyn']) * 24 * 60 * 60); |
|
1867 | 1867 | |
1868 | - if ($now <= $dayend) { |
|
1869 | - $this->processOccurrenceItem($items, $daystart, $end, $now, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1868 | + if ($now <= $dayend) { |
|
1869 | + $this->processOccurrenceItem($items, $daystart, $end, $now, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1870 | + } |
|
1870 | 1871 | } |
1871 | 1872 | } |
1872 | - } |
|
1873 | - |
|
1874 | - break; |
|
1875 | 1873 | |
1876 | - case 13: |
|
1877 | - // Yearly |
|
1878 | - if ($this->recur["everyn"] <= 0) { |
|
1879 | - $this->recur["everyn"] = 12; |
|
1880 | - } |
|
1874 | + break; |
|
1881 | 1875 | |
1882 | - for ($now = $this->yearStartOf($daystart); $now <= $dayend && ($limit == 0 || count($items) < $limit); $now += $this->daysInMonth($now, $this->recur["everyn"]) * 24 * 60 * 60) { |
|
1883 | - if (isset($this->recur["monthday"]) && !$this->recur['regen']) { // same as monthly, but in a specific month |
|
1884 | - // recur["month"] is in minutes since the beginning of the year |
|
1885 | - $month = $this->monthOfYear($this->recur["month"]); // $month is now month of year [0..11] |
|
1886 | - $monthday = $this->recur["monthday"]; // $monthday is day of the month [1..31] |
|
1887 | - $monthstart = $now + $this->daysInMonth($now, $month) * 24 * 60 * 60; // $monthstart is the timestamp of the beginning of the month |
|
1888 | - if ($monthday > $this->daysInMonth($monthstart, 1)) { |
|
1889 | - $monthday = $this->daysInMonth($monthstart, 1); |
|
1890 | - } // Cap $monthday on month length (eg 28 feb instead of 29 feb) |
|
1891 | - $daynow = $monthstart + ($monthday - 1) * 24 * 60 * 60; |
|
1892 | - $this->processOccurrenceItem($items, $start, $end, $daynow, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1876 | + case 13: |
|
1877 | + // Yearly |
|
1878 | + if ($this->recur["everyn"] <= 0) { |
|
1879 | + $this->recur["everyn"] = 12; |
|
1893 | 1880 | } |
1894 | - elseif (isset($this->recur["nday"], $this->recur["weekdays"])) { // Nth [weekday] in month X of every N years |
|
1895 | - // Go the correct month |
|
1896 | - $monthnow = $now + $this->daysInMonth($now, $this->monthOfYear($this->recur["month"])) * 24 * 60 * 60; |
|
1897 | 1881 | |
1898 | - // Find first matching weekday in this month |
|
1899 | - for ($wday = 0; $wday < 7; ++$wday) { |
|
1900 | - $daynow = $monthnow + $wday * 60 * 60 * 24; |
|
1901 | - $nowtime = $this->gmtime($daynow); // Get the weekday of the current day |
|
1882 | + for ($now = $this->yearStartOf($daystart); $now <= $dayend && ($limit == 0 || count($items) < $limit); $now += $this->daysInMonth($now, $this->recur["everyn"]) * 24 * 60 * 60) { |
|
1883 | + if (isset($this->recur["monthday"]) && !$this->recur['regen']) { // same as monthly, but in a specific month |
|
1884 | + // recur["month"] is in minutes since the beginning of the year |
|
1885 | + $month = $this->monthOfYear($this->recur["month"]); // $month is now month of year [0..11] |
|
1886 | + $monthday = $this->recur["monthday"]; // $monthday is day of the month [1..31] |
|
1887 | + $monthstart = $now + $this->daysInMonth($now, $month) * 24 * 60 * 60; // $monthstart is the timestamp of the beginning of the month |
|
1888 | + if ($monthday > $this->daysInMonth($monthstart, 1)) { |
|
1889 | + $monthday = $this->daysInMonth($monthstart, 1); |
|
1890 | + } // Cap $monthday on month length (eg 28 feb instead of 29 feb) |
|
1891 | + $daynow = $monthstart + ($monthday - 1) * 24 * 60 * 60; |
|
1892 | + $this->processOccurrenceItem($items, $start, $end, $daynow, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1893 | + } |
|
1894 | + elseif (isset($this->recur["nday"], $this->recur["weekdays"])) { // Nth [weekday] in month X of every N years |
|
1895 | + // Go the correct month |
|
1896 | + $monthnow = $now + $this->daysInMonth($now, $this->monthOfYear($this->recur["month"])) * 24 * 60 * 60; |
|
1897 | + |
|
1898 | + // Find first matching weekday in this month |
|
1899 | + for ($wday = 0; $wday < 7; ++$wday) { |
|
1900 | + $daynow = $monthnow + $wday * 60 * 60 * 24; |
|
1901 | + $nowtime = $this->gmtime($daynow); // Get the weekday of the current day |
|
1902 | 1902 | |
1903 | - if ($this->recur["weekdays"] & (1 << $nowtime["tm_wday"])) { // Selected ? |
|
1904 | - $firstday = $wday; |
|
1903 | + if ($this->recur["weekdays"] & (1 << $nowtime["tm_wday"])) { // Selected ? |
|
1904 | + $firstday = $wday; |
|
1905 | 1905 | |
1906 | - break; |
|
1906 | + break; |
|
1907 | + } |
|
1907 | 1908 | } |
1908 | - } |
|
1909 | 1909 | |
1910 | - // Same as above (monthly) |
|
1911 | - $daynow = $monthnow + ($firstday + ($this->recur["nday"] - 1) * 7) * 60 * 60 * 24; |
|
1910 | + // Same as above (monthly) |
|
1911 | + $daynow = $monthnow + ($firstday + ($this->recur["nday"] - 1) * 7) * 60 * 60 * 24; |
|
1912 | 1912 | |
1913 | - while ($this->monthStartOf($daynow) != $this->monthStartOf($monthnow)) { |
|
1914 | - $daynow -= 7 * 60 * 60 * 24; |
|
1915 | - } |
|
1913 | + while ($this->monthStartOf($daynow) != $this->monthStartOf($monthnow)) { |
|
1914 | + $daynow -= 7 * 60 * 60 * 24; |
|
1915 | + } |
|
1916 | 1916 | |
1917 | - $this->processOccurrenceItem($items, $start, $end, $daynow, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1918 | - } |
|
1919 | - elseif ($this->recur['regen']) { |
|
1920 | - $year_starttime = $this->gmtime($now); |
|
1921 | - $is_next_leapyear = $this->isLeapYear($year_starttime['tm_year'] + 1900 + 1); // +1 next year |
|
1922 | - $now = $daystart + ($is_next_leapyear ? 31622400 /* Leap year in seconds */ : 31536000 /* year in seconds */); |
|
1917 | + $this->processOccurrenceItem($items, $start, $end, $daynow, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1918 | + } |
|
1919 | + elseif ($this->recur['regen']) { |
|
1920 | + $year_starttime = $this->gmtime($now); |
|
1921 | + $is_next_leapyear = $this->isLeapYear($year_starttime['tm_year'] + 1900 + 1); // +1 next year |
|
1922 | + $now = $daystart + ($is_next_leapyear ? 31622400 /* Leap year in seconds */ : 31536000 /* year in seconds */); |
|
1923 | 1923 | |
1924 | - if ($now <= $dayend) { |
|
1925 | - $this->processOccurrenceItem($items, $daystart, $end, $now, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1924 | + if ($now <= $dayend) { |
|
1925 | + $this->processOccurrenceItem($items, $daystart, $end, $now, $this->recur["startocc"], $this->recur["endocc"], $this->tz, $remindersonly); |
|
1926 | + } |
|
1926 | 1927 | } |
1927 | 1928 | } |
1928 | - } |
|
1929 | 1929 | } |
1930 | 1930 | // to get all exception items |
1931 | 1931 | if (!empty($this->recur['changed_occurrences'])) { |
@@ -842,12 +842,12 @@ discard block |
||
842 | 842 | |
843 | 843 | $dayofweek = gmdate("w", $monthbegindow); |
844 | 844 | for ($i = 0; $i < 7; ++$i) { |
845 | - if ($nday == 5 && (($dayofweek - $i) % 7 >= 0) && (1 << (($dayofweek - $i) % 7)) & $weekdays) { |
|
845 | + if ($nday == 5 && (($dayofweek - $i) % 7 >= 0) && (1 << (($dayofweek - $i) % 7))&$weekdays) { |
|
846 | 846 | $day = gmdate("j", $monthbegindow) - $i; |
847 | 847 | |
848 | 848 | break; |
849 | 849 | } |
850 | - if ($nday != 5 && (1 << (($dayofweek + $i) % 7)) & $weekdays) { |
|
850 | + if ($nday != 5 && (1 << (($dayofweek + $i) % 7))&$weekdays) { |
|
851 | 851 | $day = (($nday - 1) * 7) + ($i + 1); |
852 | 852 | |
853 | 853 | break; |
@@ -887,12 +887,12 @@ discard block |
||
887 | 887 | // Set start on the right day |
888 | 888 | $dayofweek = gmdate("w", $monthbegindow); |
889 | 889 | for ($i = 0; $i < 7; ++$i) { |
890 | - if ($nday == 5 && (($dayofweek - $i) % 7) >= 0 && (1 << (($dayofweek - $i) % 7)) & $weekdays) { |
|
890 | + if ($nday == 5 && (($dayofweek - $i) % 7) >= 0 && (1 << (($dayofweek - $i) % 7))&$weekdays) { |
|
891 | 891 | $day = $i; |
892 | 892 | |
893 | 893 | break; |
894 | 894 | } |
895 | - if ($nday != 5 && (1 << (($dayofweek + $i) % 7)) & $weekdays) { |
|
895 | + if ($nday != 5 && (1 << (($dayofweek + $i) % 7))&$weekdays) { |
|
896 | 896 | $day = ($nday - 1) * 7 + ($i + 1); |
897 | 897 | |
898 | 898 | break; |
@@ -1144,12 +1144,12 @@ discard block |
||
1144 | 1144 | |
1145 | 1145 | $dayofweek = gmdate("w", $occenddate); |
1146 | 1146 | for ($i = 0; $i < 7; ++$i) { |
1147 | - if ($nday == 5 && (($dayofweek - $i) % 7) >= 0 && (1 << (($dayofweek - $i) % 7)) & $weekdays) { |
|
1147 | + if ($nday == 5 && (($dayofweek - $i) % 7) >= 0 && (1 << (($dayofweek - $i) % 7))&$weekdays) { |
|
1148 | 1148 | $occenddate -= $i * 24 * 60 * 60; |
1149 | 1149 | |
1150 | 1150 | break; |
1151 | 1151 | } |
1152 | - if ($nday != 5 && (1 << (($dayofweek + $i) % 7)) & $weekdays) { |
|
1152 | + if ($nday != 5 && (1 << (($dayofweek + $i) % 7))&$weekdays) { |
|
1153 | 1153 | $occenddate += ($i + (($nday - 1) * 7)) * 24 * 60 * 60; |
1154 | 1154 | |
1155 | 1155 | break; |
@@ -1918,7 +1918,7 @@ discard block |
||
1918 | 1918 | } |
1919 | 1919 | elseif ($this->recur['regen']) { |
1920 | 1920 | $year_starttime = $this->gmtime($now); |
1921 | - $is_next_leapyear = $this->isLeapYear($year_starttime['tm_year'] + 1900 + 1); // +1 next year |
|
1921 | + $is_next_leapyear = $this->isLeapYear($year_starttime['tm_year'] + 1900 + 1); // +1 next year |
|
1922 | 1922 | $now = $daystart + ($is_next_leapyear ? 31622400 /* Leap year in seconds */ : 31536000 /* year in seconds */); |
1923 | 1923 | |
1924 | 1924 | if ($now <= $dayend) { |
@@ -1540,8 +1540,7 @@ discard block |
||
1540 | 1540 | if (isset($exception->asbody)) { |
1541 | 1541 | $this->setASbody($exception->asbody, $exceptionprops, $appointmentprops); |
1542 | 1542 | $mapiexception["body"] = $exceptionprops[$appointmentprops["body"]] = |
1543 | - (isset($exceptionprops[$appointmentprops["body"]])) ? $exceptionprops[$appointmentprops["body"]] : |
|
1544 | - ((isset($exceptionprops[$appointmentprops["html"]])) ? $exceptionprops[$appointmentprops["html"]] : ""); |
|
1543 | + (isset($exceptionprops[$appointmentprops["body"]])) ? $exceptionprops[$appointmentprops["body"]] : ((isset($exceptionprops[$appointmentprops["html"]])) ? $exceptionprops[$appointmentprops["html"]] : ""); |
|
1545 | 1544 | } |
1546 | 1545 | |
1547 | 1546 | array_push($recur["changed_occurrences"], $mapiexception); |
@@ -1616,7 +1615,7 @@ discard block |
||
1616 | 1615 | $org[PR_ADDRTYPE] = isset($representingprops[$appointmentprops["sentrepresentingaddt"]]) ? $representingprops[$appointmentprops["sentrepresentingaddt"]] : $props[$appointmentprops["sentrepresentingaddt"]]; |
1617 | 1616 | $org[PR_SMTP_ADDRESS] = $org[PR_EMAIL_ADDRESS] = isset($representingprops[$appointmentprops["sentrepresentingemail"]]) ? $representingprops[$appointmentprops["sentrepresentingemail"]] : $props[$appointmentprops["sentrepresentingemail"]]; |
1618 | 1617 | $org[PR_SEARCH_KEY] = isset($representingprops[$appointmentprops["sentrepresentinsrchk"]]) ? $representingprops[$appointmentprops["sentrepresentinsrchk"]] : $props[$appointmentprops["sentrepresentinsrchk"]]; |
1619 | - $org[PR_RECIPIENT_FLAGS] = recipOrganizer | recipSendable; |
|
1618 | + $org[PR_RECIPIENT_FLAGS] = recipOrganizer|recipSendable; |
|
1620 | 1619 | $org[PR_RECIPIENT_TYPE] = MAPI_ORIG; |
1621 | 1620 | |
1622 | 1621 | array_push($recips, $org); |
@@ -2494,7 +2493,7 @@ discard block |
||
2494 | 2493 | $props[$properties["emailaddresstype{$cnt}"]] = "SMTP"; |
2495 | 2494 | $props[$properties["emailaddressentryid{$cnt}"]] = mapi_createoneoff($name, "SMTP", $emailAddress); |
2496 | 2495 | $nremails[] = $cnt - 1; |
2497 | - $abprovidertype |= 2 ^ ($cnt - 1); |
|
2496 | + $abprovidertype |= 2^($cnt - 1); |
|
2498 | 2497 | } |
2499 | 2498 | } |
2500 | 2499 |