widget.modx-security.php 1003 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. /*
  3. * This file is part of MODX Revolution.
  4. *
  5. * Copyright (c) MODX, LLC. All Rights Reserved.
  6. *
  7. * For complete copyright and license information, see the COPYRIGHT and LICENSE
  8. * files found in the top-level directory of this distribution.
  9. */
  10. /*
  11. * This file is part of MODX Revolution.
  12. *
  13. * Copyright (c) MODX, LLC. All Rights Reserved.
  14. *
  15. * For complete copyright and license information, see the COPYRIGHT and LICENSE
  16. * files found in the top-level directory of this distribution.
  17. */
  18. class modDashboardWidgetSecurityFeed extends modDashboardWidgetInterface {
  19. public function render() {
  20. $enabled = $this->modx->getOption('feed_modx_security_enabled',null,true);
  21. if (!$enabled) {
  22. return '';
  23. }
  24. return '<div id="modx-security-feed-container" class="feed-loading" data-feed="news"><i class="icon icon-refresh icon-spin" aria-hidden="true"></i> ' . $this->modx->lexicon('loading') . '</div>';
  25. }
  26. }
  27. return 'modDashboardWidgetSecurityFeed';