widget.modx-news.php 629 B

1234567891011121314151617181920212223
  1. <?php
  2. /**
  3. * @package modx
  4. * @subpackage dashboard
  5. */
  6. /**
  7. * @package modx
  8. * @subpackage dashboard
  9. */
  10. class modDashboardWidgetNewsFeed extends modDashboardWidgetInterface {
  11. /**
  12. * @return string
  13. */
  14. public function render() {
  15. $enabled = $this->modx->getOption('feed_modx_news_enabled',null,true);
  16. if (!$enabled) {
  17. return '';
  18. }
  19. return '<div id="modx-news-feed-container" class="feed-loading" data-feed="news"><i class="icon icon-refresh icon-spin" aria-hidden="true"></i> ' . $this->modx->lexicon('loading') . '</div>';
  20. }
  21. }
  22. return 'modDashboardWidgetNewsFeed';