original_string: public static function setBasicVariablesAdminView(View $view)
      {
          self::notifyWhenTrackingStatisticsDisabled();
          self::notifyIfEAcceleratorIsUsed();
          self::notifyIfURLIsNotSecure();
  
          $view->topMenu = MenuTop::getInstance()->getMenu();
  
          $view->isDataPurgeSettingsEnabled = self::isDataPurgeSettingsEnabled();
          $enableFrames = PiwikConfig::getInstance()->General['enable_framed_settings'];
          $view->enableFrames = $enableFrames;
  
          if (!$enableFrames) {
              $view->setXFrameOptions('sameorigin');
          }
  
          $view->isSuperUser = Piwik::hasUserSuperUserAccess();
  
          self::notifyAnyInvalidLicense();
          self::notifyAnyInvalidPlugin();
          self::notifyWhenPhpVersionIsEOL();
          self::notifyWhenPhpVersionIsNotCompatibleWithNextMajorPiwik();
          self::notifyWhenDebugOnDemandIsEnabled('debug');
          self::notifyWhenDebugOnDemandIsEnabled('debug_on_demand');
  
          /**
           * Posted when rendering an admin page and notifications about any warnings or errors should be triggered.
           * You can use it for example when you have a plugin that needs to be configured in order to work and the
           * plugin has not been configured yet. It can be also used to cancel / remove other notifications by calling 
           * eg `Notification\Manager::cancel($notificationId)`.
           *
           * **Example**
           *
           *     public function onTriggerAdminNotifications(Piwik\Widget\WidgetsList $list)
           *     {
           *         if ($pluginFooIsNotConfigured) {
           *              $notification = new Notification('The plugin foo has not been configured yet');
           *              $notification->context = Notification::CONTEXT_WARNING;
           *              Notification\Manager::notify('fooNotConfigured', $notification);
           *         }
           *     }
           *
           */
          Piwik::postEvent('Controller.triggerAdminNotifications');
  
          $view->adminMenu = MenuAdmin::getInstance()->getMenu();
  
          $notifications = $view->notifications;
  
          if (empty($notifications)) {
              $view->notifications = NotificationManager::getAllNotificationsToDisplay();
              NotificationManager::cancelAllNonPersistent();
          }
      }
code: public static function setBasicVariablesAdminView(View $view)
      {
          self::notifyWhenTrackingStatisticsDisabled();
          self::notifyIfEAcceleratorIsUsed();
          self::notifyIfURLIsNotSecure();
  
          $view->topMenu = MenuTop::getInstance()->getMenu();
  
          $view->isDataPurgeSettingsEnabled = self::isDataPurgeSettingsEnabled();
          $enableFrames = PiwikConfig::getInstance()->General['enable_framed_settings'];
          $view->enableFrames = $enableFrames;
  
          if (!$enableFrames) {
              $view->setXFrameOptions('sameorigin');
          }
  
          $view->isSuperUser = Piwik::hasUserSuperUserAccess();
  
          self::notifyAnyInvalidLicense();
          self::notifyAnyInvalidPlugin();
          self::notifyWhenPhpVersionIsEOL();
          self::notifyWhenPhpVersionIsNotCompatibleWithNextMajorPiwik();
          self::notifyWhenDebugOnDemandIsEnabled('debug');
          self::notifyWhenDebugOnDemandIsEnabled('debug_on_demand');
  
          /**
           * Posted when rendering an admin page and notifications about any warnings or errors should be triggered.
           * You can use it for example when you have a plugin that needs to be configured in order to work and the
           * plugin has not been configured yet. It can be also used to cancel / remove other notifications by calling 
           * eg `Notification\Manager::cancel($notificationId)`.
           *
           * **Example**
           *
           *     public function onTriggerAdminNotifications(Piwik\Widget\WidgetsList $list)
           *     {
           *         if ($pluginFooIsNotConfigured) {
           *              $notification = new Notification('The plugin foo has not been configured yet');
           *              $notification->context = Notification::CONTEXT_WARNING;
           *              Notification\Manager::notify('fooNotConfigured', $notification);
           *         }
           *     }
           *
           */
          Piwik::postEvent('Controller.triggerAdminNotifications');
  
          $view->adminMenu = MenuAdmin::getInstance()->getMenu();
  
          $notifications = $view->notifications;
  
          if (empty($notifications)) {
              $view->notifications = NotificationManager::getAllNotificationsToDisplay();
              NotificationManager::cancelAllNonPersistent();
          }
      }
code_tokens: public static function setBasicVariablesAdminView ( View $ view ) { self :: notifyWhenTrackingStatisticsDisabled ( ) ; self :: notifyIfEAcceleratorIsUsed ( ) ; self :: notifyIfURLIsNotSecure ( ) ; $ view -> topMenu = MenuTop :: getInstance ( ) -> getMenu ( ) ; $ view -> isDataPurgeSettingsEnabled = self :: isDataPurgeSettingsEnabled ( ) ; $ enableFrames = PiwikConfig :: getInstance ( ) -> General [ 'enable_framed_settings' ] ; $ view -> enableFrames = $ enableFrames ; if ( ! $ enableFrames ) { $ view -> setXFrameOptions ( 'sameorigin' ) ; } $ view -> isSuperUser = Piwik :: hasUserSuperUserAccess ( ) ; self :: notifyAnyInvalidLicense ( ) ; self :: notifyAnyInvalidPlugin ( ) ; self :: notifyWhenPhpVersionIsEOL ( ) ; self :: notifyWhenPhpVersionIsNotCompatibleWithNextMajorPiwik ( ) ; self :: notifyWhenDebugOnDemandIsEnabled ( 'debug' ) ; self :: notifyWhenDebugOnDemandIsEnabled ( 'debug_on_demand' ) ; /**
           * Posted when rendering an admin page and notifications about any warnings or errors should be triggered.
           * You can use it for example when you have a plugin that needs to be configured in order to work and the
           * plugin has not been configured yet. It can be also used to cancel / remove other notifications by calling 
           * eg `Notification\Manager::cancel($notificationId)`.
           *
           * **Example**
           *
           *     public function onTriggerAdminNotifications(Piwik\Widget\WidgetsList $list)
           *     {
           *         if ($pluginFooIsNotConfigured) {
           *              $notification = new Notification('The plugin foo has not been configured yet');
           *              $notification->context = Notification::CONTEXT_WARNING;
           *              Notification\Manager::notify('fooNotConfigured', $notification);
           *         }
           *     }
           *
           */ Piwik :: postEvent ( 'Controller.triggerAdminNotifications' ) ; $ view -> adminMenu = MenuAdmin :: getInstance ( ) -> getMenu ( ) ; $ notifications = $ view -> notifications ; if ( empty ( $ notifications ) ) { $ view -> notifications = NotificationManager :: getAllNotificationsToDisplay ( ) ; NotificationManager :: cancelAllNonPersistent ( ) ; } }
docstring: Assigns view properties that would be useful to views that render admin pages.
  
  Assigns the following variables:
  
  - **statisticsNotRecorded** - Set to true if the `[Tracker] record_statistics` INI
  config is `0`. If not `0`, this variable will not be defined.
  - **topMenu** - The result of `MenuTop::getInstance()->getMenu()`.
  - **enableFrames** - The value of the `[General] enable_framed_pages` INI config option. If
  true, {@link Piwik\View::setXFrameOptions()} is called on the view.
  - **isSuperUser** - Whether the current user is a superuser or not.
  - **usingOldGeoIPPlugin** - Whether this Piwik install is currently using the old GeoIP
  plugin or not.
  - **invalidPluginsWarning** - Set if some of the plugins to load (determined by INI configuration)
  are invalid or missing.
  - **phpVersion** - The current PHP version.
  - **phpIsNewEnough** - Whether the current PHP version is new enough to run Piwik.
  - **adminMenu** - The result of `MenuAdmin::getInstance()->getMenu()`.
  
  @param View $view
  @api
docstring_tokens: Assigns view properties that would be useful to views that render admin pages .