]> git.mxchange.org Git - friendica.git/blob - view/theme/frio/php/standard.php
Merge pull request #9734 from annando/issue-9704
[friendica.git] / view / theme / frio / php / standard.php
1 <?php
2 /**
3  * @copyright Copyright (C) 2020, Friendica
4  *
5  * @license GNU AGPL version 3 or any later version
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU Affero General Public License as
9  * published by the Free Software Foundation, either version 3 of the
10  * License, or (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15  * GNU Affero General Public License for more details.
16  *
17  * You should have received a copy of the GNU Affero General Public License
18  * along with this program.  If not, see <https://www.gnu.org/licenses/>.
19  *
20  * The default site template
21  */
22
23 ?>
24 <!DOCTYPE html >
25 <html>
26 <head>
27         <title><?php if(!empty($page['title'])) echo $page['title'] ?></title>
28         <meta name="viewport" content="initial-scale=1.0">
29         <meta request="<?php echo htmlspecialchars($_REQUEST['pagename']) ?>">
30         <script type="text/javascript">var baseurl="<?php echo Friendica\DI::baseUrl() ?>";</script>
31         <script type="text/javascript">var frio="<?php echo "view/theme/frio"; ?>";</script>
32         <?php $baseurl = Friendica\DI::baseUrl(); ?>
33         <?php $frio = "view/theme/frio"; ?>
34         <?php if(!empty($page['htmlhead'])) echo $page['htmlhead']; ?>
35 </head>
36 <body id="top">
37 <?php if($_SERVER['REQUEST_URI'] == "/"){header('Location: /login');} ?>
38 <a href="#content" class="sr-only sr-only-focusable"><?php echo DI::l10n()->t('Skip to main content'); ?></a>
39 <?php
40         if(!empty($page['nav'])) {
41         echo    str_replace("~config.sitename~",Friendica\DI::config()->get('config','sitename'),
42                         str_replace("~system.banner~",Friendica\DI::config()->get('system','banner'),
43                         $page['nav']
44         ));};
45 ?>
46         <main>
47
48                 <div class="container">
49                         <div class="row">
50 <?php
51                                         echo"
52                                         <aside class=\"col-lg-3 col-md-3 hidden-sm hidden-xs\">
53                                                 "; if(!empty($page['aside'])) echo $page['aside']; echo"
54                                                 "; if(!empty($page['right_aside'])) echo $page['right_aside']; echo"
55                                                 "; include('includes/photo_side.php'); echo"
56                                         </aside>
57
58                                         <div class=\"col-lg-8 col-md-8 col-sm-12 col-xs-12\" id=\"content\">
59                                                 <section class=\"sectiontop\">
60                                                                 <div class=\"panel "; echo $a->argv[0]; echo "-content-wrapper\">
61                                                                         <div class=\"panel-body\">";
62                                                                                 if(!empty($page['content'])) echo $page['content']; echo"
63                                                                                 <div id=\"pause\"></div> <!-- The pause/resume Ajax indicator -->
64                                                                         </div>
65                                                                 </div>
66                                                 </section>
67                                         </div>
68                                                 ";
69 ?>
70                         </div><!--row-->
71                 </div><!-- container -->
72
73                 <div id="back-to-top" title="back to top">⇧</div>
74         </main>
75
76 <footer>
77 <span id="notifsound"></span>
78 <script>
79         $("#menu-toggle").click(function(e) {
80                 e.preventDefault();
81                 $("#wrapper").toggleClass("toggled");
82         });
83 </script>
84 <script type="text/javascript">
85         $.fn.enterKey = function (fnc, mod) {
86                 return this.each(function () {
87                         $(this).keypress(function (ev) {
88                                 var keycode = (ev.keyCode ? ev.keyCode : ev.which);
89                                 if ((keycode == '13' || keycode == '10') && (!mod || ev[mod + 'Key'])) {
90                                         fnc.call(this, ev);
91                                 }
92                         })
93                 })
94         }
95
96         $('textarea').enterKey(function() {$(this).closest('form').submit(); }, 'ctrl')
97         $('input').enterKey(function() {$(this).closest('form').submit(); }, 'ctrl')
98 </script>
99
100 <script>
101 var pagetitle = null;
102 $("nav").bind('nav-update', function(e,data)
103 {
104         if (pagetitle==null) pagetitle = document.title;
105         var count = $(data).find('notif').attr('count');
106         if (count>0)
107         {
108                 document.title = "("+count+") "+pagetitle;
109                 /* document.getElementById('notifsound').innerHTML='<object type="audio/mpeg" width="0" height="0" data="<?=$frio?>/audios/901.mp3"><param name="notif" value="<?=$frio?>/audios/901.mp3" /><param name="autostart" value="true" /><param name="loop" value="false" /></object>'; */
110         }
111         else
112         {
113                 document.title = pagetitle;
114         }
115 });
116 </script>
117 <script src="<?=$frio?>/js/theme.js"></script>
118 <script src="<?=$frio?>/frameworks/bootstrap/js/bootstrap.min.js"></script>
119 <script src="<?=$frio?>/frameworks/jasny/js/jasny-bootstrap.min.js"></script>
120 <script src="<?=$frio?>/frameworks/bootstrap-select/js/bootstrap-select.min.js"></script>
121 <script src="<?=$frio?>/frameworks/ekko-lightbox/ekko-lightbox.min.js"></script>
122 <script src="<?=$frio?>/frameworks/justifiedGallery/jquery.justifiedGallery.min.js"></script>
123
124 <!-- Modal  -->
125 <div id="modal" class="modal fade" tabindex="-1" role="dialog">
126         <div class="modal-dialog modal-full-screen">
127                 <div class="modal-content">
128                         <div id="modal-header" class="modal-header">
129                                 <button id="modal-cloase" type="button" class="close" data-dismiss="modal">
130                                         &times;
131                                 </button>
132                                 <h4 id="modal-title" class="modal-title"></h4>
133                         </div>
134                         <div id="modal-body" class="modal-body">
135                                 <!-- /# content goes here -->
136                         </div>
137                 </div>
138         </div>
139 </div>
140 </footer>
141 </body>