diff --git a/core/Tracker/GoalManager.php b/core/Tracker/GoalManager.php
index 7f7052679275071e6e742ccc7b213d34a629bb6d..0b8f6be10753f6b65f682f62ff84db7f6396176d 100644
--- a/core/Tracker/GoalManager.php
+++ b/core/Tracker/GoalManager.php
@@ -572,7 +572,7 @@ class GoalManager
             $newRow = $this->getItemRowEnriched($goal, $item);
             Common::printDebug($newRow);
             $updateParts = $sqlBind = array();
-            foreach ($newRow AS $name => $value) {
+            foreach ($newRow as $name => $value) {
                 $updateParts[] = $name . " = ?";
                 $sqlBind[] = $value;
             }
@@ -761,7 +761,7 @@ class GoalManager
     protected function updateExistingConversion($newGoal, $updateWhere)
     {
         $updateParts = $sqlBind = $updateWhereParts = array();
-        foreach ($newGoal AS $name => $value) {
+        foreach ($newGoal as $name => $value) {
             $updateParts[] = $name . " = ?";
             $sqlBind[] = $value;
         }
diff --git a/core/Tracker/Visit.php b/core/Tracker/Visit.php
index 072acf4efa3d85f121089967598467f257e6f30c..5bd716db67634ff3de1d4886563c45d3549df2a3 100644
--- a/core/Tracker/Visit.php
+++ b/core/Tracker/Visit.php
@@ -242,7 +242,7 @@ class Visit implements VisitInterface
         $visitor->setVisitorColumn('time_spent_ref_action', $this->visitorInfo['time_spent_ref_action']);
 
         // update visitorInfo
-        foreach ($valuesToUpdate AS $name => $value) {
+        foreach ($valuesToUpdate as $name => $value) {
             $this->visitorInfo[$name] = $value;
         }
 
@@ -450,7 +450,7 @@ class Visit implements VisitInterface
                         AND idvisit = ?";
         // build sql query
         $updateParts = $sqlBind = array();
-        foreach ($valuesToUpdate AS $name => $value) {
+        foreach ($valuesToUpdate as $name => $value) {
             // Case where bind parameters don't work
             if(strpos($value, $name) !== false) {
                 //$name = 'visit_total_events'
diff --git a/core/Translate/Filter/ByBaseTranslations.php b/core/Translate/Filter/ByBaseTranslations.php
index 1c265debe79b897b0baa527b82a0b055712b700b..755c669e2bc90428271b1f05b3d34ed21a924998 100644
--- a/core/Translate/Filter/ByBaseTranslations.php
+++ b/core/Translate/Filter/ByBaseTranslations.php
@@ -37,7 +37,7 @@ class ByBaseTranslations extends FilterAbstract
     {
         $cleanedTranslations = array();
 
-        foreach ($translations AS $pluginName => $pluginTranslations) {
+        foreach ($translations as $pluginName => $pluginTranslations) {
 
             if (empty($this->baseTranslations[$pluginName])) {
                 $this->filteredData[$pluginName] = $pluginTranslations;
diff --git a/core/Translate/Filter/ByParameterCount.php b/core/Translate/Filter/ByParameterCount.php
index 3832c8f262280e04a87192ed16df65dd1789e812..72f7fd24d41911284a108722f60ecbf3c505f9f5 100644
--- a/core/Translate/Filter/ByParameterCount.php
+++ b/core/Translate/Filter/ByParameterCount.php
@@ -37,9 +37,9 @@ class ByParameterCount extends FilterAbstract
     {
         $cleanedTranslations = array();
 
-        foreach ($translations AS $pluginName => $pluginTranslations) {
+        foreach ($translations as $pluginName => $pluginTranslations) {
 
-            foreach ($pluginTranslations AS $key => $translation) {
+            foreach ($pluginTranslations as $key => $translation) {
 
                 if (isset($this->baseTranslations[$pluginName][$key])) {
                     $baseTranslation = $this->baseTranslations[$pluginName][$key];
diff --git a/core/Translate/Filter/EmptyTranslations.php b/core/Translate/Filter/EmptyTranslations.php
index 1d77de7b9810a4bfdafd7d1f08625ead17b7d201..3c67f1f50dd47fb998361aef953c39a97e00cfa8 100644
--- a/core/Translate/Filter/EmptyTranslations.php
+++ b/core/Translate/Filter/EmptyTranslations.php
@@ -25,7 +25,7 @@ class EmptyTranslations extends FilterAbstract
     {
         $translationsBefore = $translations;
 
-        foreach ($translations AS $plugin => &$pluginTranslations) {
+        foreach ($translations as $plugin => &$pluginTranslations) {
 
             $pluginTranslations = array_filter($pluginTranslations, function ($value) {
                 return !empty($value) && '' != trim($value);
diff --git a/core/Translate/Filter/EncodedEntities.php b/core/Translate/Filter/EncodedEntities.php
index 7c35614fb2d1a175eea5b43a1a6dec812790a265..58b7d084710016e1d3f51e1457bbf222f3b54550 100644
--- a/core/Translate/Filter/EncodedEntities.php
+++ b/core/Translate/Filter/EncodedEntities.php
@@ -25,8 +25,8 @@ class EncodedEntities extends FilterAbstract
      */
     public function filter($translations)
     {
-        foreach ($translations AS $pluginName => $pluginTranslations) {
-            foreach ($pluginTranslations AS $key => $translation) {
+        foreach ($translations as $pluginName => $pluginTranslations) {
+            foreach ($pluginTranslations as $key => $translation) {
 
                 // remove encoded entities
                 $decoded = Translate::clean($translation);
diff --git a/core/Translate/Filter/UnnecassaryWhitespaces.php b/core/Translate/Filter/UnnecassaryWhitespaces.php
index 38df742e4143d2d96d92ead82c863266bb76d66f..b104b30a1c981253e9c1166ea604568c1d103eed 100644
--- a/core/Translate/Filter/UnnecassaryWhitespaces.php
+++ b/core/Translate/Filter/UnnecassaryWhitespaces.php
@@ -35,8 +35,8 @@ class UnnecassaryWhitespaces extends FilterAbstract
      */
     public function filter($translations)
     {
-        foreach ($translations AS $pluginName => $pluginTranslations) {
-            foreach ($pluginTranslations AS $key => $translation) {
+        foreach ($translations as $pluginName => $pluginTranslations) {
+            foreach ($pluginTranslations as $key => $translation) {
 
                 $baseTranslation = '';
                 if (isset($this->baseTranslations[$pluginName][$key])) {
diff --git a/core/Translate/Writer.php b/core/Translate/Writer.php
index d15f14e4dafda9ee8eeecfae671985d5c85edee6..391decdc89fe37613d161740ecb903e8e0de3bbb 100644
--- a/core/Translate/Writer.php
+++ b/core/Translate/Writer.php
@@ -292,7 +292,7 @@ class Writer
 
         $this->validationMessage = null;
 
-        foreach ($this->validators AS $validator) {
+        foreach ($this->validators as $validator) {
             if (!$validator->isValid($this->translations)) {
                 $this->validationMessage = $validator->getMessage();
                 return false;
@@ -362,7 +362,7 @@ class Writer
 
         $cleanedTranslations = $this->translations;
 
-        foreach ($this->filters AS $filter) {
+        foreach ($this->filters as $filter) {
 
             $cleanedTranslations = $filter->filter($cleanedTranslations);
             $filteredData = $filter->getFilteredData();
diff --git a/core/Updates/1.7.2-rc7.php b/core/Updates/1.7.2-rc7.php
index 87ae2fc035e10df6cce8ca3e680e0f600a349042..3966d8c86dca1885e06dd2d4ab50e6c429aeaf6d 100755
--- a/core/Updates/1.7.2-rc7.php
+++ b/core/Updates/1.7.2-rc7.php
@@ -30,7 +30,7 @@ class Updates_1_7_2_rc7 extends Updates
     {
         try {
             $dashboards = Db::fetchAll('SELECT * FROM `' . Common::prefixTable('user_dashboard') . '`');
-            foreach ($dashboards AS $dashboard) {
+            foreach ($dashboards as $dashboard) {
                 $idDashboard = $dashboard['iddashboard'];
                 $login = $dashboard['login'];
                 $layout = $dashboard['layout'];
diff --git a/core/Updates/1.8.3-b1.php b/core/Updates/1.8.3-b1.php
index 33ddbeeeaa2b4c89f375edda06ca2742a14faca2..7a00ec20b3f890b574cd14ceb8498266c4968fba 100644
--- a/core/Updates/1.8.3-b1.php
+++ b/core/Updates/1.8.3-b1.php
@@ -60,7 +60,7 @@ class Updates_1_8_3_b1 extends Updates
             // - delete Common::prefixTable('pdf')
 
             $reports = Db::fetchAll('SELECT * FROM `' . Common::prefixTable('pdf') . '`');
-            foreach ($reports AS $report) {
+            foreach ($reports as $report) {
 
                 $idreport = $report['idreport'];
                 $idsite = $report['idsite'];
diff --git a/plugins/Dashboard/Dashboard.php b/plugins/Dashboard/Dashboard.php
index 4fcbeb086d85c007d8580d1429fe92ead304327c..cb545465ff215f99e053c88bd2434d06544aa84d 100644
--- a/plugins/Dashboard/Dashboard.php
+++ b/plugins/Dashboard/Dashboard.php
@@ -112,7 +112,7 @@ class Dashboard extends \Piwik\Plugin
             ' WHERE login = ? ORDER BY iddashboard', array($login));
 
         $nameless = 1;
-        foreach ($dashboards AS &$dashboard) {
+        foreach ($dashboards as &$dashboard) {
 
             if (empty($dashboard['name'])) {
                 $dashboard['name'] = Piwik::translate('Dashboard_DashboardOf', $login);
diff --git a/plugins/DevicesDetection/Controller.php b/plugins/DevicesDetection/Controller.php
index bb3190bf2d35b06de73e8190b87261bb508b5ba5..33802daf51a149f708a5cd09caf3432c3986e3a1 100644
--- a/plugins/DevicesDetection/Controller.php
+++ b/plugins/DevicesDetection/Controller.php
@@ -83,7 +83,7 @@ class Controller extends \Piwik\Plugin\Controller
             case 'brands':
                 $availableBrands = \DeviceDetector\Parser\Device\DeviceParserAbstract::$deviceBrands;
 
-                foreach ($availableBrands AS $short => $name) {
+                foreach ($availableBrands as $short => $name) {
                     if ($name != 'Unknown') {
                         $list[$name] = getBrandLogo($name);
                     }
@@ -93,7 +93,7 @@ class Controller extends \Piwik\Plugin\Controller
             case 'browsers':
                 $availableBrowsers = \DeviceDetector\Parser\Client\Browser::getAvailableBrowsers();
 
-                foreach ($availableBrowsers AS $short => $name) {
+                foreach ($availableBrowsers as $short => $name) {
                     $list[$name] = getBrowserLogoExtended($short);
                 }
                 break;
@@ -101,7 +101,7 @@ class Controller extends \Piwik\Plugin\Controller
             case 'browserfamilies':
                 $availableBrowserFamilies = \DeviceDetector\Parser\Client\Browser::getAvailableBrowserFamilies();
 
-                foreach ($availableBrowserFamilies AS $name => $browsers) {
+                foreach ($availableBrowserFamilies as $name => $browsers) {
                     $list[$name] = getBrowserFamilyLogoExtended($name);
                 }
                 break;
@@ -109,7 +109,7 @@ class Controller extends \Piwik\Plugin\Controller
             case 'os':
                 $availableOSs = \DeviceDetector\Parser\OperatingSystem::getAvailableOperatingSystems();
 
-                foreach ($availableOSs AS $short => $name) {
+                foreach ($availableOSs as $short => $name) {
                     $list[$name] = getOsLogoExtended($short);
                 }
                 break;
@@ -117,7 +117,7 @@ class Controller extends \Piwik\Plugin\Controller
             case 'osfamilies':
                 $osFamilies = \DeviceDetector\Parser\OperatingSystem::getAvailableOperatingSystemFamilies();
 
-                foreach ($osFamilies AS $name => $oss) {
+                foreach ($osFamilies as $name => $oss) {
                     $list[$name] = getOsFamilyLogoExtended($name);
                 }
                 break;
@@ -125,7 +125,7 @@ class Controller extends \Piwik\Plugin\Controller
             case 'devicetypes':
                 $deviceTypes = \DeviceDetector\Parser\Device\DeviceParserAbstract::getAvailableDeviceTypes();
 
-                foreach ($deviceTypes AS $name => $id) {
+                foreach ($deviceTypes as $name => $id) {
                     $list[$name] = getDeviceTypeLogo($name);
                 }
                 break;
diff --git a/plugins/LanguagesManager/API.php b/plugins/LanguagesManager/API.php
index 09277e70989023d5ec4b5c52c981c41c1a90e08a..0ab9ef680bd5c3da174662d0263f3a84a652663d 100644
--- a/plugins/LanguagesManager/API.php
+++ b/plugins/LanguagesManager/API.php
@@ -90,7 +90,7 @@ class API extends \Piwik\Plugin\API
 
         // merge with plugin translations if any
         $pluginFiles = glob(sprintf('%s/plugins/*/lang/en.json', PIWIK_INCLUDE_PATH));
-        foreach ($pluginFiles AS $file) {
+        foreach ($pluginFiles as $file) {
 
             $data = file_get_contents($file);
             $pluginTranslations = json_decode($data, true);
@@ -105,7 +105,7 @@ class API extends \Piwik\Plugin\API
 
             // merge with plugin translations if any
             $pluginFiles = glob(sprintf('%s/plugins/*/lang/%s.json', PIWIK_INCLUDE_PATH, $filename));
-            foreach ($pluginFiles AS $file) {
+            foreach ($pluginFiles as $file) {
 
                 $data = file_get_contents($file);
                 $pluginTranslations = json_decode($data, true);
diff --git a/plugins/LanguagesManager/Commands/CompareKeys.php b/plugins/LanguagesManager/Commands/CompareKeys.php
index a5998f79caf21b9c57bb9f24b9bfd14ca64791c6..088bb492aeb12ae2f89c262f7d271bc5c9c4c647 100644
--- a/plugins/LanguagesManager/Commands/CompareKeys.php
+++ b/plugins/LanguagesManager/Commands/CompareKeys.php
@@ -58,10 +58,10 @@ class CompareKeys extends ConsoleCommand
 
         $unnecessary = $outdated = $missing = array();
 
-        foreach ($categories AS $category)
+        foreach ($categories as $category)
         {
             if (!empty($englishFromOTrance[$category])) {
-                foreach ($englishFromOTrance[$category] AS $key => $value) {
+                foreach ($englishFromOTrance[$category] as $key => $value) {
                     if(!array_key_exists($category, $availableTranslations) || !array_key_exists($key, $availableTranslations[$category])) {
                         $unnecessary[] = sprintf('%s_%s', $category, $key);
                         continue;
@@ -72,7 +72,7 @@ class CompareKeys extends ConsoleCommand
                 }
             }
             if (!empty($availableTranslations[$category])) {
-                foreach ($availableTranslations[$category] AS $key => $value) {
+                foreach ($availableTranslations[$category] as $key => $value) {
                     if(!array_key_exists($category, $englishFromOTrance) || !array_key_exists($key, $englishFromOTrance[$category])) {
                         $missing[] = sprintf('%s_%s', $category, $key);
                         continue;
diff --git a/plugins/LanguagesManager/Commands/CreatePull.php b/plugins/LanguagesManager/Commands/CreatePull.php
index 1ea87f524a868ae8b0e10c9704ce2b88d899e8d0..036547ec67660c0cf78087a3a2bc3e847ea36499 100644
--- a/plugins/LanguagesManager/Commands/CreatePull.php
+++ b/plugins/LanguagesManager/Commands/CreatePull.php
@@ -96,7 +96,7 @@ class CreatePull extends ConsoleCommand
         shell_exec('git add lang/. > /dev/null 2>&1');
 
         if (empty($plugin)) {
-            foreach (Update::getPluginsInCore() AS $pluginName) {
+            foreach (Update::getPluginsInCore() as $pluginName) {
                 shell_exec(sprintf('git add plugins/%s/lang/. > /dev/null 2>&1', $pluginName));
             }
         }
@@ -133,7 +133,7 @@ class CreatePull extends ConsoleCommand
 
         $languageCodesTouched = array();
         if (!empty($addedFiles[1])) {
-            foreach ($addedFiles[1] AS $addedFile) {
+            foreach ($addedFiles[1] as $addedFile) {
                 $languageInfo = $this->getLanguageInfoByIsoCode($addedFile);
                 $messages[$addedFile] = sprintf('- Added %s (%s changes / %s translated)\n', $languageInfo['english_name'], $linesSumByLang[$addedFile], $languageInfo['percentage_complete']);
             }
@@ -141,7 +141,7 @@ class CreatePull extends ConsoleCommand
         }
 
         if (!empty($modifiedFiles[1])) {
-            foreach ($modifiedFiles[1] AS $modifiedFile) {
+            foreach ($modifiedFiles[1] as $modifiedFile) {
                 $languageInfo = $this->getLanguageInfoByIsoCode($modifiedFile);
                 $messages[$modifiedFile] = sprintf('- Updated %s (%s changes / %s translated)\n', $languageInfo['english_name'], $linesSumByLang[$modifiedFile], $languageInfo['percentage_complete']);
             }
@@ -169,7 +169,7 @@ class CreatePull extends ConsoleCommand
     private function getLanguageInfoByIsoCode($isoCode)
     {
         $languages = API::getInstance()->getAvailableLanguagesInfo();
-        foreach ($languages AS $languageInfo) {
+        foreach ($languages as $languageInfo) {
             if ($languageInfo['code'] == $isoCode) {
                 return $languageInfo;
             }
diff --git a/plugins/LanguagesManager/Commands/FetchFromOTrance.php b/plugins/LanguagesManager/Commands/FetchFromOTrance.php
index f8e93cb12f9ea0027b31ebb3d739f6850dd9e2ee..c55b33a1a76d0a7d4974eae8303c47d8472c246c 100644
--- a/plugins/LanguagesManager/Commands/FetchFromOTrance.php
+++ b/plugins/LanguagesManager/Commands/FetchFromOTrance.php
@@ -140,7 +140,7 @@ class FetchFromOTrance extends ConsoleCommand
         $progress = $this->getHelperSet()->get('progress');
 
         $progress->start($output, count($filesToConvert));
-        foreach ($filesToConvert AS $filename) {
+        foreach ($filesToConvert as $filename) {
 
             require_once $filename;
             $basename = explode(".", basename($filename));
diff --git a/plugins/LanguagesManager/Commands/LanguageCodes.php b/plugins/LanguagesManager/Commands/LanguageCodes.php
index 7f584ea14d33a3fc667122d445891a506d8c3106..1a4fad066bce6dc6b1962add916d1a3a804d2fba 100644
--- a/plugins/LanguagesManager/Commands/LanguageCodes.php
+++ b/plugins/LanguagesManager/Commands/LanguageCodes.php
@@ -29,7 +29,7 @@ class LanguageCodes extends ConsoleCommand
         $languages = API::getInstance()->getAvailableLanguageNames();
 
         $languageCodes = array();
-        foreach ($languages AS $languageInfo) {
+        foreach ($languages as $languageInfo) {
             $languageCodes[] = $languageInfo['code'];
         }
 
diff --git a/plugins/LanguagesManager/Commands/LanguageNames.php b/plugins/LanguagesManager/Commands/LanguageNames.php
index cffe727b1f7b1f91b7715af642f38932f424181d..2bb590882e2c1d43f129e888bfb18c9743d2db7d 100644
--- a/plugins/LanguagesManager/Commands/LanguageNames.php
+++ b/plugins/LanguagesManager/Commands/LanguageNames.php
@@ -29,7 +29,7 @@ class LanguageNames extends ConsoleCommand
         $languages = API::getInstance()->getAvailableLanguageNames();
 
         $languageNames = array();
-        foreach ($languages AS $languageInfo) {
+        foreach ($languages as $languageInfo) {
             $languageNames[] = $languageInfo['english_name'];
         }
 
diff --git a/plugins/LanguagesManager/Commands/Update.php b/plugins/LanguagesManager/Commands/Update.php
index 224124396f96e9cf53aa6020e38203ac6df2163c..26927682626d6892e3a087f69b18248d3430fd8f 100644
--- a/plugins/LanguagesManager/Commands/Update.php
+++ b/plugins/LanguagesManager/Commands/Update.php
@@ -47,7 +47,7 @@ class Update extends ConsoleCommand
         $languages = API::getInstance()->getAvailableLanguageNames();
 
         $languageCodes = array();
-        foreach ($languages AS $languageInfo) {
+        foreach ($languages as $languageInfo) {
             $languageCodes[] = $languageInfo['code'];
         }
 
@@ -65,7 +65,7 @@ class Update extends ConsoleCommand
 
         $progress->start($output, count($files));
 
-        foreach ($files AS $filename) {
+        foreach ($files as $filename) {
 
             $progress->advance();
 
@@ -106,7 +106,7 @@ class Update extends ConsoleCommand
             // update core modules that aren't in their own repo
             if (empty($plugin)) {
 
-                foreach (self::getPluginsInCore() AS $pluginName) {
+                foreach (self::getPluginsInCore() as $pluginName) {
 
                     // update translation files
                     $command = $this->getApplication()->find('translations:set');
diff --git a/plugins/Referrers/API.php b/plugins/Referrers/API.php
index 91fe2dbab209d25ee8846d4a994cd4784e2614b9..01854ac9f1198618e29d5afa4a3d46eb86352de7 100644
--- a/plugins/Referrers/API.php
+++ b/plugins/Referrers/API.php
@@ -251,7 +251,7 @@ class API extends \Piwik\Plugin\API
             $dataTables = $searchEngines->getDataTables();
 
             // find first datatable containing data
-            foreach ($dataTables AS $subTable) {
+            foreach ($dataTables as $subTable) {
 
                 $subTableRow = $subTable->getRowFromIdSubDataTable($idSubtable);
                 if (!empty($subTableRow)) {
diff --git a/plugins/Referrers/functions.php b/plugins/Referrers/functions.php
index 40391ee6d659d97a23ec23222b2fe2255652e282..8f7a4023dfbbf6231f773cf7ddd5c6cbbfc2de52 100644
--- a/plugins/Referrers/functions.php
+++ b/plugins/Referrers/functions.php
@@ -37,7 +37,7 @@ function getPathFromUrl($url)
 function getSocialMainUrl($url)
 {
     $social  = getSocialNetworkFromDomain($url);
-    foreach (Common::getSocialUrls() AS $domain => $name) {
+    foreach (Common::getSocialUrls() as $domain => $name) {
 
         if($name == $social) {
 
@@ -55,7 +55,7 @@ function getSocialMainUrl($url)
  */
 function getSocialNetworkFromDomain($url)
 {
-    foreach (Common::getSocialUrls() AS $domain => $name) {
+    foreach (Common::getSocialUrls() as $domain => $name) {
 
         if(preg_match('/(^|[\.\/])'.$domain.'([\.\/]|$)/', $url)) {
 
@@ -76,7 +76,7 @@ function getSocialNetworkFromDomain($url)
  */
 function isSocialUrl($url, $socialName = false)
 {
-    foreach (Common::getSocialUrls() AS $domain => $name) {
+    foreach (Common::getSocialUrls() as $domain => $name) {
 
         if (preg_match('/(^|[\.\/])'.$domain.'([\.\/]|$)/', $url) && ($socialName === false || $name == $socialName)) {
 
diff --git a/plugins/UserSettings/API.php b/plugins/UserSettings/API.php
index 5d1db6f0893732a853555f40c827f52c38ad7ceb..9cae146d629555cfc745a119680f984c1cd3c352 100644
--- a/plugins/UserSettings/API.php
+++ b/plugins/UserSettings/API.php
@@ -104,11 +104,11 @@ class API extends \Piwik\Plugin\API
         $dataTables = array($dataTable);
 
         if (!($dataTable instanceof DataTable\Map)) {
-            foreach ($dataTables AS $table) {
+            foreach ($dataTables as $table) {
                 if ($table->getRowsCount() == 0) {
                     continue;
                 }
-                foreach ($requiredRows AS $requiredRow => $key) {
+                foreach ($requiredRows as $requiredRow => $key) {
                     $row = $table->getRowFromLabel($requiredRow);
                     if (empty($row)) {
                         $table->addRowsFromSimpleArray(array(
@@ -184,14 +184,14 @@ class API extends \Piwik\Plugin\API
         // walk through the results and calculate the percentage
         foreach ($dataTableMap as $key => $table) {
             // get according browserType table
-            foreach ($browserTypesArray AS $k => $browsers) {
+            foreach ($browserTypesArray as $k => $browsers) {
                 if ($k == $key) {
                     $browserType = $browsers;
                 }
             }
 
             // get according visitsSum
-            foreach ($visitSumsArray AS $k => $visits) {
+            foreach ($visitSumsArray as $k => $visits) {
                 if ($k == $key) {
                     if (is_object($visits)) {
                         if ($visits->getRowsCount() == 0) {
diff --git a/tests/PHPUnit/Fixture.php b/tests/PHPUnit/Fixture.php
index d09ee974f34ae3a2af4ea9f16135e75deccf2247..255153e3672e011d501828ba7d263dbacc1e1a84 100644
--- a/tests/PHPUnit/Fixture.php
+++ b/tests/PHPUnit/Fixture.php
@@ -342,7 +342,7 @@ class Fixture extends PHPUnit_Framework_Assert
         try {
             $manager = \Piwik\Plugin\Manager::getInstance();
             $plugins = $manager->getLoadedPlugins();
-            foreach ($plugins AS $plugin) {
+            foreach ($plugins as $plugin) {
                 $plugin->uninstall();
             }
             \Piwik\Plugin\Manager::getInstance()->unloadPlugins();
diff --git a/tests/PHPUnit/Integration/Core/PiwikTest.php b/tests/PHPUnit/Integration/Core/PiwikTest.php
index 03726d3e801646ca242e1a074d1a94964c4178e5..ebf606de72dffac7caebd5b338bac33ef35851f8 100644
--- a/tests/PHPUnit/Integration/Core/PiwikTest.php
+++ b/tests/PHPUnit/Integration/Core/PiwikTest.php
@@ -78,7 +78,7 @@ class Core_PiwikTest extends DatabaseTestCase
             '-1', '0', '1', '1.5', '-1.5', '21111', '89898', '99999999999', '-4565656',
             '1e3', '0x123', "-1e-2",
         );
-        foreach ($valid AS $key => $value) {
+        foreach ($valid as $key => $value) {
             $valid[$key] = array($value);
         }
         return $valid;
@@ -100,7 +100,7 @@ class Core_PiwikTest extends DatabaseTestCase
         $notValid = array(
             '-1.0.0', '1,2', '--1', '-.', '- 1', '1-',
         );
-        foreach ($notValid AS $key => $value) {
+        foreach ($notValid as $key => $value) {
             $notValid[$key] = array($value);
         }
         return $notValid;
@@ -189,7 +189,7 @@ class Core_PiwikTest extends DatabaseTestCase
             'alpha>beta',
             'alpha?beta',
         );
-        foreach ($notValid AS $key => $value) {
+        foreach ($notValid as $key => $value) {
             $notValid[$key] = array($value);
         }
         return $notValid;
@@ -214,7 +214,7 @@ class Core_PiwikTest extends DatabaseTestCase
             'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa',
             'shoot_puck@the-goal.com',
         );
-        foreach ($valid AS $key => $value) {
+        foreach ($valid as $key => $value) {
             $valid[$key] = array($value);
         }
         return $valid;
diff --git a/tests/PHPUnit/Integration/Core/SegmentTest.php b/tests/PHPUnit/Integration/Core/SegmentTest.php
index f26cd92e140ed59816f73919a0da2880160847c1..17667bf59c297b2f2f19d7e3d6d8e7064aa9294f 100644
--- a/tests/PHPUnit/Integration/Core/SegmentTest.php
+++ b/tests/PHPUnit/Integration/Core/SegmentTest.php
@@ -33,7 +33,7 @@ class SegmentTest extends DatabaseTestCase
     protected function _filterWhitsSpaces($valueToFilter)
     {
         if (is_array($valueToFilter)) {
-            foreach ($valueToFilter AS $key => $value) {
+            foreach ($valueToFilter as $key => $value) {
                 $valueToFilter[$key] = $this->_filterWhitsSpaces($value);
             }
             return $valueToFilter;
diff --git a/tests/PHPUnit/Integration/Core/WidgetsListTest.php b/tests/PHPUnit/Integration/Core/WidgetsListTest.php
index 7afd9dc0a5fa369a1394064fd3ff08a991302212..08c2e14c0dff792ed73e3042bbd28d3f502da86b 100644
--- a/tests/PHPUnit/Integration/Core/WidgetsListTest.php
+++ b/tests/PHPUnit/Integration/Core/WidgetsListTest.php
@@ -57,7 +57,7 @@ class Core_WidgetsListTest extends DatabaseTestCase
         // number of main categories
         $this->assertEquals(count($numberOfWidgets), count($widgets));
 
-        foreach ($numberOfWidgets AS $category => $widgetCount) {
+        foreach ($numberOfWidgets as $category => $widgetCount) {
             $this->assertEquals($widgetCount, count($widgets[$category]), sprintf("Widget: %s", $category));
         }
     }
@@ -89,7 +89,7 @@ class Core_WidgetsListTest extends DatabaseTestCase
             'Goals_Goals' => 2,
         );
 
-        foreach ($numberOfWidgets AS $category => $widgetCount) {
+        foreach ($numberOfWidgets as $category => $widgetCount) {
             $this->assertEquals($widgetCount, count($widgets[$category]));
         }
     }
@@ -122,7 +122,7 @@ class Core_WidgetsListTest extends DatabaseTestCase
             'Goals_Ecommerce' => 5,
         );
 
-        foreach ($numberOfWidgets AS $category => $widgetCount) {
+        foreach ($numberOfWidgets as $category => $widgetCount) {
             $this->assertEquals($widgetCount, count($widgets[$category]));
         }
     }
diff --git a/tests/PHPUnit/Plugins/LanguagesManagerTest.php b/tests/PHPUnit/Plugins/LanguagesManagerTest.php
index 617f7941ef7d826fcd13b0b4d8b0e971ce724671..13cb46c6e628f67049ad42537cb8a0ca42a65ab6 100755
--- a/tests/PHPUnit/Plugins/LanguagesManagerTest.php
+++ b/tests/PHPUnit/Plugins/LanguagesManagerTest.php
@@ -34,7 +34,7 @@ class Test_LanguagesManager extends PHPUnit_Framework_TestCase
 
         $pluginsWithTranslation = array();
 
-        foreach ($plugins AS $plugin) {
+        foreach ($plugins as $plugin) {
 
             if (API::getInstance()->getPluginTranslationsForLanguage($plugin, 'en')) {
 
@@ -43,11 +43,11 @@ class Test_LanguagesManager extends PHPUnit_Framework_TestCase
         }
 
         $return = array();
-        foreach ($languages AS $language) {
+        foreach ($languages as $language) {
             if ($language != 'en') {
                 $return[] = array($language, null);
 
-                foreach ($pluginsWithTranslation AS $plugin) {
+                foreach ($pluginsWithTranslation as $plugin) {
 
                     $return[] = array($language, $plugin);
                 }
diff --git a/tests/PHPUnit/Plugins/ReferrersTest.php b/tests/PHPUnit/Plugins/ReferrersTest.php
index f160e63d341361af3f0af57d5f527297e6b3ffcc..3818457093f09a22377a3f4b124bba4241d5aec2 100644
--- a/tests/PHPUnit/Plugins/ReferrersTest.php
+++ b/tests/PHPUnit/Plugins/ReferrersTest.php
@@ -21,7 +21,7 @@ class ReferrersTest extends PHPUnit_Framework_TestCase
         include PIWIK_PATH_TEST_TO_ROOT . '/core/DataFiles/SearchEngines.php';
 
         $searchEngines = array();
-        foreach ($GLOBALS['Piwik_SearchEngines'] AS $url => $searchEngine) {
+        foreach ($GLOBALS['Piwik_SearchEngines'] as $url => $searchEngine) {
             $searchEngines[] = array($url, $searchEngine);
         }
         return $searchEngines;