layout.phtml 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. <?php FreshRSS::preLayout(); ?>
  2. <!DOCTYPE html>
  3. <html lang="<?php echo FreshRSS_Context::$user_conf->language; ?>" xml:lang="<?php echo FreshRSS_Context::$user_conf->language; ?>">
  4. <head>
  5. <meta charset="UTF-8" />
  6. <meta name="viewport" content="initial-scale=1.0" />
  7. <?php echo self::headStyle(); ?>
  8. <script id="jsonVars" type="application/json">
  9. <?php $this->renderHelper('javascript_vars'); ?>
  10. </script>
  11. <?php echo self::headScript(); ?>
  12. <link rel="shortcut icon" id="favicon" type="image/x-icon" sizes="16x16 64x64" href="<?php echo Minz_Url::display('/favicon.ico'); ?>" />
  13. <link rel="icon msapplication-TileImage apple-touch-icon" type="image/png" sizes="256x256" href="<?php echo Minz_Url::display('/themes/icons/favicon-256.png'); ?>" />
  14. <link rel="prefetch" href="<?php echo FreshRSS_Themes::icon('starred', true); ?>" />
  15. <link rel="prefetch" href="<?php echo FreshRSS_Themes::icon('non-starred', true); ?>" />
  16. <link rel="prefetch" href="<?php echo FreshRSS_Themes::icon('read', true); ?>" />
  17. <link rel="prefetch" href="<?php echo FreshRSS_Themes::icon('unread', true); ?>" />
  18. <link rel="apple-touch-icon" href="<?php echo Minz_Url::display('/themes/icons/apple-touch-icon.png'); ?>" />
  19. <meta name="apple-mobile-web-app-capable" content="yes" />
  20. <meta name="apple-mobile-web-app-status-bar-style" content="black" />
  21. <meta name="apple-mobile-web-app-title" content="<?php echo FreshRSS_Context::$system_conf->title; ?>">
  22. <meta name="msapplication-TileColor" content="#FFF" />
  23. <?php if (!FreshRSS_Context::$system_conf->allow_referrer) { ?>
  24. <meta name="referrer" content="never" />
  25. <?php
  26. }
  27. flush();
  28. if (isset($this->callbackBeforeContent)) {
  29. call_user_func($this->callbackBeforeContent, $this);
  30. }
  31. ?>
  32. <?php echo self::headTitle(); ?>
  33. <?php
  34. $url_base = Minz_Request::currentRequest();
  35. if (FreshRSS_Context::$next_id !== '') {
  36. $url_next = $url_base;
  37. $url_next['params']['next'] = FreshRSS_Context::$next_id;
  38. $url_next['params']['ajax'] = 1;
  39. ?>
  40. <link id="prefetch" rel="next prefetch" href="<?php echo Minz_Url::display($url_next); ?>" />
  41. <?php
  42. } if (isset($this->rss_title)) {
  43. $url_rss = $url_base;
  44. $url_rss['a'] = 'rss';
  45. if (FreshRSS_Context::$user_conf->since_hours_posts_per_rss) {
  46. $url_rss['params']['hours'] = FreshRSS_Context::$user_conf->since_hours_posts_per_rss;
  47. }
  48. ?>
  49. <link rel="alternate" type="application/rss+xml" title="<?php echo $this->rss_title; ?>" href="<?php echo Minz_Url::display($url_rss); ?>" />
  50. <?php } if (FreshRSS_Context::$system_conf->allow_robots) { ?>
  51. <meta name="description" content="<?php echo htmlspecialchars(FreshRSS_Context::$name . ' | ' . FreshRSS_Context::$description, ENT_COMPAT, 'UTF-8'); ?>" />
  52. <?php } else { ?>
  53. <meta name="robots" content="noindex,nofollow" />
  54. <?php } ?>
  55. </head>
  56. <body class="<?php echo Minz_Request::actionName(); ?>">
  57. <?php $this->partial('header'); ?>
  58. <div id="global">
  59. <?php $this->render(); ?>
  60. </div>
  61. <?php
  62. $msg = '';
  63. $status = 'closed';
  64. if (isset($this->notification)) {
  65. $msg = $this->notification['content'];
  66. $status = $this->notification['type'];
  67. invalidateHttpCache();
  68. }
  69. ?>
  70. <div id="notification" class="notification <?php echo $status; ?>">
  71. <span class="msg"><?php echo $msg; ?></span>
  72. <a class="close" href=""><?php echo _i('close'); ?></a>
  73. </div>
  74. </body>
  75. </html>