Style.php - <?php class Audentio_UIX_ControllerAdmin_Style extends XFCP_Audentio_UIX_ControllerAdmin_Style cfw public function actionIndex cfw

Style.php - <?php class Audentio_UIX_ControllerAdmin_Style...

This preview shows page 1 - 2 out of 2 pages.

<?php class Audentio_UIX_ControllerAdmin_Style extends XFCP_Audentio_UIX_ControllerAdmin_Style { public function actionIndex() { $xenOptions = XenForo_Application::getOptions(); $response = parent::actionIndex(); $adStyles = false; if ($xenOptions->uix_checkForUnassociatedStyles) { /** @var $registry XenForo_Model_DataRegistry */ $registry = $this->getModelFromCache('XenForo_Model_DataRegistry'); $startTime = $registry->get('uix_checkStylesStart'); if ($startTime === null) { $startTime = 0; } if ($startTime > XenForo_Application::$time - 3600) { $styleModel = $this->_getStyleModel(); $audentioModel = $this- >getModelFromCache('Audentio_UIX_Model_Audentio'); $apiStyles = $audentioModel->getStylesFromApi(); if (is_array($apiStyles)) { $adStyles = $styleModel->getAudentioStyles('uix_pid'); $parsedStyles = array(); foreach ($apiStyles as $apiStyle) { if ($apiStyle['purchased'] == 1) { $parsedStyles[$apiStyle['name']] = $apiStyle['pid']; } } foreach ($response->params['styles'] as &$style) { if (array_key_exists($style['title'], $parsedStyles) && $style['parent_id'] == 0 && !array_key_exists($parsedStyles[$style['title']], $adStyles)) { $style['unassociated'] = true; $style['unassociated_pid'] =

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture