YaWK  24.1
Yet another WebKit
mailbox.php
Go to the documentation of this file.
1 <?php
2 // check if language is set
3 if (!isset($language) || (!isset($lang)))
4 { // inject (add) language tags to core $lang array
5  $lang = \YAWK\language::inject(@$lang, "../system/plugins/messages/language/");
6 }
7 // TEMPLATE WRAPPER - HEADER & breadcrumbs
8 echo "
9  <!-- Content Wrapper. Contains page content -->
10  <div class=\"content-wrapper\" id=\"content-FX\">
11  <!-- Content Header (Page header) -->
12  <section class=\"content-header\">";
13 /* draw Title on top */
14 echo \YAWK\backend::getTitle($lang['MSG_MAILBOX'], $lang['MSG_INBOX_SUBTITLE']);
15 echo"<ol class=\"breadcrumb\">
16  <li><a href=\"index.php\" title=\"$lang[DASHBOARD]\"><i class=\"fa fa-dashboard\"></i> $lang[DASHBOARD]</a></li>
17  <li><a href=\"index.php?page=plugins\" title=\"$lang[PLUGINS]\"> $lang[PLUGINS]</a></li>
18  <li><a href=\"index.php?plugin=messages\" title=\"$lang[MESSAGING]\"> $lang[MESSAGING]</a></li>
19  <li class=\"active\"><a href=\"index.php?plugin=messages&pluginpage=mailbox\" title=\"Mailbox\"> $lang[MAILBOX]</a></li>
20  </ol>
21  </section>
22  <!-- Main content -->
23  <section class=\"content\">";
24 ?>
25 <a class="btn btn-default pull-right" title="<?php echo $lang['REFRESH'];?>" href="index.php?plugin=messages&pluginpage=mailbox">
26 <i class="fa fa-refresh"></i></a>
27 
28 <a class="btn btn-success pull-right" title="<?php echo $lang['MSG_COMPOSE'];?>" href="index.php?plugin=messages&pluginpage=mailbox&active=compose">
29 <i class="fa fa-plus"></i> &nbsp;<?php print $lang['MSG_COMPOSE']; ?></a>
30 
31 
32 <?php
33 /* page content start here */
34 include '../system/plugins/messages/classes/messages.php';
35 $messages = new \YAWK\PLUGINS\MESSAGES\messages($db, "backend");
36 
37 // check if a msg ID is sent via GET
38 if (isset($_GET['msg_id']) && is_numeric($_GET['msg_id']))
39 { // single message view
40  echo $messages->MessageView($db, $_GET['msg_id'], $lang);
41 }
42 else
43 // no message to display
44 { // therefor init mailbox
45  echo $messages->init($db, $lang);
46 }
static inject(array $lang, string $pathToFile)
allow plugins to inject language tags to $lang array
Definition: language.php:439
function a
Definition: browser.js:14
$messages
Definition: mailbox.php:35
print $lang['MSG_COMPOSE']
Definition: mailbox.php:14
print $page title
Definition: page-edit.php:377
print $_GET['id']
Definition: page-edit.php:357
function i(e, t)
Definition: plyr.js:1
<!-- backend language -->< h3 >< i class="fa fa-language"></i > & nbsp