correctly set and use logged user
This commit is contained in:
commit
17946fbcbf
207 changed files with 18910 additions and 0 deletions
1
views/binary/binary.tpl
Normal file
1
views/binary/binary.tpl
Normal file
|
|
@ -0,0 +1 @@
|
|||
<?=$intermediate?>
|
||||
1
views/binary/error/index.tpl
Normal file
1
views/binary/error/index.tpl
Normal file
|
|
@ -0,0 +1 @@
|
|||
<?=_('Error')?>: <?=$code?>: <?=$string?>
|
||||
1
views/binary/media/index.tpl
Normal file
1
views/binary/media/index.tpl
Normal file
|
|
@ -0,0 +1 @@
|
|||
<?=$file?>
|
||||
1
views/binary/uploads/index.tpl
Normal file
1
views/binary/uploads/index.tpl
Normal file
|
|
@ -0,0 +1 @@
|
|||
<?=$file?>
|
||||
13
views/error.tpl
Normal file
13
views/error.tpl
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<title>Service Unavailable</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<p>Die Anwendung steht zur Zeit leider nicht zur Verfügung.</p>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
2
views/fault/error/index.tpl
Normal file
2
views/fault/error/index.tpl
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
<h1>Fehler</h1>
|
||||
<p class="error"><?=$code?>: <?=$string?></p>
|
||||
16
views/fault/fault.tpl
Normal file
16
views/fault/fault.tpl
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<title>The Legend of Z</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>The Legend of Z</h1>
|
||||
<article>
|
||||
<?=$intermediate?>
|
||||
</article>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
72
views/html/charactergroups/group.tpl
Normal file
72
views/html/charactergroups/group.tpl
Normal file
|
|
@ -0,0 +1,72 @@
|
|||
<div class="moodpic">
|
||||
<img src="http://s1.directupload.net/images/140323/tpzvoy5c.png">
|
||||
</div>
|
||||
<h1><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h1>
|
||||
<h2><a href="<?=$linker->link(array('index',$seminary['url']),1)?>"><?=_('Character Groups')?></a></h2>
|
||||
<section class="gdata cf">
|
||||
<div class="gbanner">
|
||||
<img src="http://s1.directupload.net/images/140325/3eqybn4i.png">
|
||||
</div>
|
||||
<div class="gdesc">
|
||||
<h3><?=$group['name']?></h3>
|
||||
<span>Schweb wie ein Schmetterling! Stich wie eine Biene!</span>
|
||||
</div>
|
||||
<ul>
|
||||
<li><i class="fa fa-th-list fa-fw"></i>7. Platz</li>
|
||||
<li><i class="fa fa-lightbulb-o fa-fw"></i><?=$group['xps']?> XP</li>
|
||||
<li><i class="fa fa-users fa-fw"></i>6 Mitglieder</li>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h1><i class="fa fa-users fa-fw"></i><?=_('Characters')?></h1>
|
||||
<ul class="gchars cf">
|
||||
<?php foreach($characters as &$character) : ?>
|
||||
<li>
|
||||
<p><img src="http://s7.directupload.net/images/140325/e2wdqhqa.png"></p>
|
||||
<p><a href="<?=$linker->link(array('characters','character',$seminary['url'],$character['url']))?>"><?=$character['name']?></a></p>
|
||||
<p><small><?=$character['xps']?> XP</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<p><img src="http://s7.directupload.net/images/140325/e2wdqhqa.png"></p>
|
||||
<p><a href="<?=$linker->link(array('characters','character',$seminary['url'],$character['url']))?>"><?=$character['name']?></a></p>
|
||||
<p><small><?=$character['xps']?> XP</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<p><img src="http://s7.directupload.net/images/140325/e2wdqhqa.png"></p>
|
||||
<p><a href="<?=$linker->link(array('characters','character',$seminary['url'],$character['url']))?>"><?=$character['name']?></a></p>
|
||||
<p><small><?=$character['xps']?> XP</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<p><img src="http://s7.directupload.net/images/140325/e2wdqhqa.png"></p>
|
||||
<p><a href="<?=$linker->link(array('characters','character',$seminary['url'],$character['url']))?>"><?=$character['name']?></a></p>
|
||||
<p><small><?=$character['xps']?> XP</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<p><img src="http://s7.directupload.net/images/140325/e2wdqhqa.png"></p>
|
||||
<p><a href="<?=$linker->link(array('characters','character',$seminary['url'],$character['url']))?>"><?=$character['name']?></a></p>
|
||||
<p><small><?=$character['xps']?> XP</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<p><img src="http://s7.directupload.net/images/140325/e2wdqhqa.png"></p>
|
||||
<p><a href="<?=$linker->link(array('characters','character',$seminary['url'],$character['url']))?>"><?=$character['name']?></a></p>
|
||||
<p><small><?=$character['xps']?> XP</small></p>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h1><i class="fa fa-pencil-square-o fa-fw"></i><?=_('Quests')?></h1>
|
||||
<ul class="gquests">
|
||||
<?php foreach($quests as &$quest) : ?>
|
||||
<li class="cf">
|
||||
<p>
|
||||
<span class="date"><?=$dateFormatter->format(new \DateTime($quest['created']))?></span>
|
||||
<a href="<?=$linker->link(array('charactergroupsquests','quest',$seminary['url'],$groupsgroup['url'],$quest['url']))?>" class="fwb"><?=$quest['title']?></a>
|
||||
<span class="xp"><?=$quest['group_xps']?> / <?=$quest['xps']?> XP</span>
|
||||
</p>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
</section>
|
||||
17
views/html/charactergroups/groupsgroup.tpl
Normal file
17
views/html/charactergroups/groupsgroup.tpl
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
<h1><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h1>
|
||||
<h2><a href="<?=$linker->link(array('index',$seminary['url']),1)?>"><?=_('Character Groups')?></a></h2>
|
||||
<h3><?=$groupsgroup['name']?></h3>
|
||||
|
||||
<ul>
|
||||
<?php foreach($groups as &$group) : ?>
|
||||
<li><a href="<?=$linker->link(array('group',$seminary['url'],$groupsgroup['url'],$group['url']),1)?>"><?=$group['name']?> (<?=$group['xps']?> XPs)</a></li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><?=_('Character Groups Quests')?></h3>
|
||||
<ul>
|
||||
<?php foreach($quests as &$quest) : ?>
|
||||
<li><a href="<?=$linker->link(array('charactergroupsquests','quest',$seminary['url'],$groupsgroup['url'],$quest['url']))?>"><?=$quest['title']?></a></li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
8
views/html/charactergroups/index.tpl
Normal file
8
views/html/charactergroups/index.tpl
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<h1><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h1>
|
||||
<h2><?=_('Character Groups')?></h2>
|
||||
|
||||
<ul>
|
||||
<?php foreach($groupsgroups as &$group) : ?>
|
||||
<li><a href="<?=$linker->link(array('groupsgroup',$seminary['url'],$group['url']),1)?>"><?=$group['name']?></a></li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
46
views/html/charactergroupsquests/quest.tpl
Normal file
46
views/html/charactergroupsquests/quest.tpl
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
<h2><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h2>
|
||||
<h3><?=$seminary['title']?></h3>
|
||||
<h4><?=_('Character Groups Quests')?></h4>
|
||||
<h5><?=$quest['title']?></h5>
|
||||
|
||||
<?php if(!is_null($media)) : ?>
|
||||
<img src="<?=$linker->link(array('media','seminary',$seminary['url'],$media['url']))?>" />
|
||||
<?php endif ?>
|
||||
|
||||
<section>
|
||||
<p>XPs: <?=$quest['xps']?></p>
|
||||
<h1><?=_('Description')?></h1>
|
||||
<p><?=\hhu\z\Utils::t($quest['description'])?></p>
|
||||
<?php if(!empty($quest['rules'])) : ?>
|
||||
<h1><?=_('Rules')?></h1>
|
||||
<p><?=\hhu\z\Utils::t($quest['rules'])?></p>
|
||||
<?php endif ?>
|
||||
</section>
|
||||
|
||||
<?php if(!empty($quest['von_text'])) : ?>
|
||||
<section>
|
||||
<h1><?=_('Won Quest')?></h1>
|
||||
<p><?=\hhu\z\Utils::t($quest['won_text'])?></p>
|
||||
</section>
|
||||
<?php endif ?>
|
||||
<?php if(!empty($quest['lost_text'])) : ?>
|
||||
<section>
|
||||
<h1><?=_('Lost Quest')?></h1>
|
||||
<p><?=\hhu\z\Utils::t($quest['lost_text'])?></p>
|
||||
</section>
|
||||
<?php endif ?>
|
||||
|
||||
<section>
|
||||
<h1><?=$groupsgroup['name']?></h1>
|
||||
<table>
|
||||
<tbody>
|
||||
<?php foreach($groups as &$group) : ?>
|
||||
<tr>
|
||||
<td><?=$dateFormatter->format(new \DateTime($group['created']))?></td>
|
||||
<td><a href="<?=$linker->link(array('charactergroups','group',$seminary['url'],$groupsgroup['url'],$group['url']))?>"><?=$group['name']?></a></td>
|
||||
<td><?=$group['xps']?>/<?=$quest['xps']?> XPs</td>
|
||||
</tr>
|
||||
<?php endforeach ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</section>
|
||||
160
views/html/characters/character.tpl
Normal file
160
views/html/characters/character.tpl
Normal file
|
|
@ -0,0 +1,160 @@
|
|||
<h1><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h1>
|
||||
<h2><a href="<?=$linker->link(array('index',$seminary['url']),1)?>"><?=_('Characters')?></a></h2>
|
||||
<h3><i class="fa fa-user fa-fw"></i><?=$character['name']?></h3>
|
||||
|
||||
<section class="cf">
|
||||
<div class="cinfo">
|
||||
<div class="cdata">
|
||||
<div class="xpbar">
|
||||
<span style="width:<?=round($character['quest_xps']*100/$seminary['achievable_xps'])?>%"></span>
|
||||
</div>
|
||||
<p><small><?=_('Total progress')?>: <?=round($character['quest_xps']*100/$seminary['achievable_xps'])?> %</small></p>
|
||||
</div>
|
||||
<div class="cdata square">
|
||||
<p class="value"><?=$character['xplevel']['level']?></p>
|
||||
<p><small><?=_('Level')?></small></p>
|
||||
</div>
|
||||
<div class="cdata square">
|
||||
<p class="value"><?=$character['xps']?></p>
|
||||
<p><small>XP</small></p>
|
||||
</div>
|
||||
<div class="cdata square blue">
|
||||
<p class="value"><?=$character['rank']?>.</p>
|
||||
<p><small><?=_('Rank')?></small></p>
|
||||
</div>
|
||||
|
||||
<h1><i class="fa fa-certificate fa-fw"></i><?=_('Achievements')?></h1>
|
||||
<ul class="crewards">
|
||||
<li>
|
||||
<p class="unlocked"><i class="fa fa-check-circle fa-fw"></i>Aktive Beteiligung</p>
|
||||
</li>
|
||||
<li>
|
||||
<p class="unlocked"><i class="fa fa-check-circle fa-fw"></i>+ 0,3 Notenbonus</p>
|
||||
</li>
|
||||
<li>
|
||||
<p><i class="fa fa-lock fa-fw"></i>+ 0,7 Notenbonus <span class="locked">(noch 300 XP)</span></p>
|
||||
</li>
|
||||
<li>
|
||||
<p><i class="fa fa-lock fa-fw"></i>+ 1,0 Notenbonus <span class="locked">(noch 500 XP)</span></p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="cportrait">
|
||||
<?php if(!is_null($character['avatar_url'])) : ?>
|
||||
<img src="<?=$linker->link(array('media','seminary',$seminary['url'],$character['avatar_url']))?>" alt="<?=$character['avatar_description']?>" />
|
||||
<?php endif ?>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h1><i class="fa fa-users fa-fw"></i><?=_('Character Groups')?></h1>
|
||||
<ul class="cgroups cf">
|
||||
<?php foreach($groups as &$group) : ?>
|
||||
<li class="cf">
|
||||
<img src="http://s1.directupload.net/images/140325/3eqybn4i.png">
|
||||
<a href="<?=$linker->link(array('charactergroups','group',$seminary['url'],$group['charactergroupsgroup_url'],$group['url']))?>"><?=$group['name']?></a><p><span><?=$group['xps']?> XPs</span></p>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<div class="cf">
|
||||
<section class="fll48">
|
||||
<h1><i class="fa fa-trophy fa-fw"></i>Neue Achievements</h1>
|
||||
<ul class="cranks">
|
||||
<li>
|
||||
<a href="#" title="Achievement-Titel"><img src="http://legende-von-zyren.de/img/achieve/1b.jpg"></a>
|
||||
<p><a href="#">Des Königs neue Quests</a></p>
|
||||
<p><small>erreicht am: 14.07.2014</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" title="Achievement-Titel"><img src="http://legende-von-zyren.de/img/achieve/2b.jpg"></a>
|
||||
<p><a href="#">Des Königs neue Quests</a></p>
|
||||
<p><small>erreicht am: 14.07.2014</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" title="Achievement-Titel"><img src="http://legende-von-zyren.de/img/achieve/3b.jpg"></a>
|
||||
<p><a href="#">Des Königs neue Quests</a></p>
|
||||
<p><small>erreicht am: 14.07.2014</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" title="Achievement-Titel"><img src="http://legende-von-zyren.de/img/achieve/4b.jpg"></a>
|
||||
<p><a href="#">Des Königs neue Quests</a></p>
|
||||
<p><small>erreicht am: 14.07.2014</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" title="Achievement-Titel"><img src="http://legende-von-zyren.de/img/achieve/5b.jpg"></a>
|
||||
<p><a href="#">Des Königs neue Quests</a></p>
|
||||
<p><small>erreicht am: 14.07.2014</small></p>
|
||||
</li>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<section class="flr48">
|
||||
<h1><i class="fa fa-list fa-fw"></i>Ranking</h1>
|
||||
<ul class="cranks">
|
||||
<li>
|
||||
<a href="#" title="Achievement-Titel"><img src="http://s7.directupload.net/images/140325/e2wdqhqa.png"></a>
|
||||
<p>7. <a href="#">Anduin</a></p>
|
||||
<p><small>Level 27 (1500 XP)</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" title="Achievement-Titel"><img src="http://s1.directupload.net/images/140325/upv2dg2r.png"></a>
|
||||
<p>8. <a href="#">Jaina</a></p>
|
||||
<p><small>Level 26 (1400 XP)</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" title="Achievement-Titel"><img src="http://s14.directupload.net/images/140325/x9ny5kgu.png"></a>
|
||||
<p class="fwb">9. <a href="#">Uther</a></p>
|
||||
<p><small>Level 25 (1300 XP)</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" title="Achievement-Titel"><img src="http://s7.directupload.net/images/140325/e2wdqhqa.png"></a>
|
||||
<p>10. <a href="#">Lothar</a></p>
|
||||
<p><small>Level 24 (1200 XP)</small></p>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" title="Achievement-Titel"><img src="http://s1.directupload.net/images/140325/whre34td.png"></a>
|
||||
<p>11. <a href="#">Morris</a></p>
|
||||
<p><small>Level 23 (1100 XP)</small></p>
|
||||
</li>
|
||||
</ul>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<section>
|
||||
<h1><i class="fa fa-book fa-fw"></i>Thematischer Fortschritt</h1>
|
||||
<ul class="ctopics cf">
|
||||
<li>
|
||||
<p><small><a href="#">Klassifikation</a> (3/5)</small></p>
|
||||
<div class="xpbar">
|
||||
<span style="width:60%"></span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<p><small><a href="#">Thesauri</a> (1/10)</small></p>
|
||||
<div class="xpbar">
|
||||
<span style="width:10%"></span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<p><small><a href="#">Indexierung</a> (3/5)</small></p>
|
||||
<div class="xpbar">
|
||||
<span style="width:20%"></span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<p><small><a href="#">Recherche</a> (3/5)</small></p>
|
||||
<div class="xpbar">
|
||||
<span style="width:80%"></span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<p><small><a href="#">Folksonomies</a> (3/5)</small></p>
|
||||
<div class="xpbar">
|
||||
<span style="width:70%"></span>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
8
views/html/characters/index.tpl
Normal file
8
views/html/characters/index.tpl
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<h1><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h1>
|
||||
<h2><?=_('Characters')?></h2>
|
||||
|
||||
<ul>
|
||||
<?php foreach($characters as &$character) : ?>
|
||||
<li><a href="<?=$linker->link(array('character',$seminary['url'],$character['url']),1)?>"><?=$character['name']?></a> (<?=$character['xps']?> XPs, <?=_('Level')?> <?=$character['xplevel']['level']?><?php if(!is_null($character['xplevel']['name'])) : ?>: <?=$character['xplevel']['name']?><?php endif ?>)</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
2
views/html/error/index.tpl
Normal file
2
views/html/error/index.tpl
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
<h1><?=_('Error')?></h1>
|
||||
<p class="error"><?=$code?>: <?=$string?></p>
|
||||
52
views/html/html.tpl
Normal file
52
views/html/html.tpl
Normal file
|
|
@ -0,0 +1,52 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<title>The Legend of Z</title>
|
||||
<meta name="viewport" content="width=device-width,initial-scale=1.0">
|
||||
<link href="http://fonts.googleapis.com/css?family=Open+Sans:400,700" rel="stylesheet" type="text/css">
|
||||
<link href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css" rel="stylesheet">
|
||||
<link rel="stylesheet" type="text/css" href="<?=$linker->link(array('css','desktop.css'))?>" media="all" />
|
||||
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
|
||||
<script type="text/javascript" src="/js/jquery.nicescroll.min.js"></script>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(
|
||||
function() {
|
||||
$("#qtextbox").niceScroll({autohidemode:false,cursorcolor:"#c2beb9"});
|
||||
}
|
||||
);
|
||||
</script>
|
||||
<!--[if lt IE 9]>
|
||||
<script type="text/javascript" src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
|
||||
<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/respond.js/1.4.2/respond.js"></script>
|
||||
<![endif]-->
|
||||
<script type="text/javascript" src="/js/dnd.js"></script>
|
||||
<meta name="description" content="">
|
||||
<meta name="robots" content="noindex,follow">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<header>
|
||||
<nav>
|
||||
<input type="checkbox" id="toggle">
|
||||
<label for="toggle" class="toggle" onclick><a id="navicon"><i class="fa fa-bars"></i>Menü</a></label>
|
||||
<?php if(!is_null($loggedUser)) : ?>
|
||||
<?php if(!is_null($loggedCharacter)) : ?>
|
||||
<a href="<?=$linker->link(array('characters','character',$loggedSeminary['url'],$loggedCharacter['url']))?>" id="profile"><i class="fa fa-user fa-fw"></i><?=$loggedCharacter['name']?><span class="circlenote"><?=$loggedCharacter['xplevel']?></span></a>
|
||||
<?php else : ?>
|
||||
<a href="<?=$linker->link(array('users',$loggedUser['url']))?>" id="profile"><i class="fa fa-user fa-fw"></i><?=$loggedUser['username']?></a>
|
||||
<?php endif ?>
|
||||
<?php endif ?>
|
||||
<?=$menu?>
|
||||
<?php if(!is_null($loggedSeminary)) : ?>
|
||||
<?=$seminarymenu?>
|
||||
<?php endif ?>
|
||||
</nav>
|
||||
</header>
|
||||
<article class="wrap">
|
||||
<?=$intermediate?>
|
||||
</article>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
36
views/html/introduction/index.tpl
Normal file
36
views/html/introduction/index.tpl
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
<h1><?=_('Introduction')?></h1>
|
||||
<p>Ein Projekt zum Thema „Gamification im Lehrumfeld“ – basierend auf <a href="http://legende-von-zyren.de">Die Legende von Zyren</a>.</p>
|
||||
|
||||
<?php if(is_null($userId)) : ?>
|
||||
<h2><?=_('Login')?></h2>
|
||||
<form method="post" action="<?=$linker->link(array('users','login'))?>">
|
||||
<fieldset>
|
||||
<label for="username"><?=_('Username')?>:</label>
|
||||
<input name="username" type="text" placeholder="<?=_('Username')?>" title="<?=_('Username')?>" required="required" /><br />
|
||||
<label for="password"><?=_('Password')?>:</label>
|
||||
<input name="password" type="password" placeholder="<?=_('Password')?>" title="<?=_('Password')?>" required="required" /><br />
|
||||
</fieldset>
|
||||
<input type="submit" name="login" value="<?=_('Login')?>" />
|
||||
<?=_('or')?> <a href="<?=$linker->link(array('users','register'))?>"><?=_('register yourself')?></a>
|
||||
</form>
|
||||
<?php endif ?>
|
||||
|
||||
<h2>Entwickler</h2>
|
||||
<ul>
|
||||
<li itemscope itemtype="http://schema.org/Person">
|
||||
<span itemprop="name">Oliver Hanraths</span><br />
|
||||
Programmierung und Datenbank
|
||||
</li>
|
||||
<li itemscope itemtype="http://schema.org/Person">
|
||||
<span itemprop="name">Daniel Miskovic</span><br />
|
||||
GUI und Webdesign
|
||||
</li>
|
||||
<li itemscope itemtype="http://schema.org/Person">
|
||||
<span itemprop="name">Kathrin Knautz</span>, <span itemprop="honorificSuffix">B.A., M.A.</span><br />
|
||||
Leitung
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<p itemscope itemtype="http://schema.org/CollegeOrUniversity">
|
||||
<a itemprop="name" href="http://www.uni-duesseldorf.de">Heinrich-Heine-Universität Düsseldorf</a>
|
||||
</p>
|
||||
11
views/html/menu/index.tpl
Normal file
11
views/html/menu/index.tpl
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
<menu>
|
||||
<li><a href="<?=$linker->link(array(), 0, true, array(), true)?>">The Legend of Z</a></li>
|
||||
<?php if(!is_null($loggedUser) && count(array_intersect(array('admin','moderator'),$loggedUser['roles'])) > 0) : ?><li><a href="<?=$linker->link('users')?>"><i class="fa fa-users fa-fw"></i><?=_('Users')?></a></li><?php endif ?>
|
||||
<?php if(!is_null($loggedUser)) : ?><li><a href="<?=$linker->link('usersgroups')?>"><i class="fa fa-users fa-fw"></i><?=_('Usergroups')?></a></li><?php endif ?>
|
||||
<?php if(!is_null($loggedUser)) : ?><li><a href="<?=$linker->link('seminaries')?>"><i class="fa fa-pencil-square-o fa-fw"></i><?=_('Seminaries')?></a></li><?php endif ?>
|
||||
<?php if(is_null($loggedUser)) : ?>
|
||||
<li><a href="<?=$linker->link(array('users','login'))?>"><i class="fa fa-sign-in fa-fw"></i><?=_('Login')?></a></li>
|
||||
<?php else : ?>
|
||||
<li><a href="<?=$linker->link(array('users','logout'))?>"><i class="fa fa-sign-out fa-fw"></i><?=_('Logout')?></a></li>
|
||||
<?php endif ?>
|
||||
</menu>
|
||||
60
views/html/questgroups/questgroup.tpl
Normal file
60
views/html/questgroups/questgroup.tpl
Normal file
|
|
@ -0,0 +1,60 @@
|
|||
<?php if(!is_null($picture)) : ?>
|
||||
<div class="moodpic">
|
||||
<img src="<?=$linker->link(array('media','seminary',$seminary['url'],$picture['url']))?>" />
|
||||
</div>
|
||||
<?php endif ?>
|
||||
<h1><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h1>
|
||||
|
||||
<?=$questgroupshierarchypath?>
|
||||
|
||||
<?php if(!is_null($questgroup['hierarchy'])) : ?>
|
||||
<h2><?=$questgroup['hierarchy']['title_singular']?> <?=$questgroup['hierarchy']['questgroup_pos']?>: <?=$questgroup['title']?></h2>
|
||||
<?php else : ?>
|
||||
<h2><?=$questgroup['title']?></h2>
|
||||
<?php endif ?>
|
||||
<?php foreach($texts as &$text) : ?>
|
||||
<p><?=\hhu\z\Utils::t($text['text'])?></p>
|
||||
<?php endforeach ?>
|
||||
|
||||
<?php if(!is_null($childquestgroupshierarchy)) : ?>
|
||||
<?php foreach($childquestgroupshierarchy as &$hierarchy) : ?>
|
||||
<?php if(count($hierarchy['questgroups']) > 0) : ?>
|
||||
<h3><?=$hierarchy['title_plural']?></h3>
|
||||
<ul class="qg">
|
||||
<?php foreach($hierarchy['questgroups'] as &$group) : ?>
|
||||
<li class="cf">
|
||||
<span class="qgicon"><i class="fa fa-check-square-o"></i></span>
|
||||
<div class="qgtitle"><a href="<?=$linker->link(array('questgroups','questgroup',$seminary['url'],$group['url']))?>"><?=$group['title']?></a></div>
|
||||
<div class="qgprogress cf">
|
||||
<p class="xpinfo">Fortschritt:</p>
|
||||
<div class="xpbar">
|
||||
<span style="width:<?=round($group['character_xps']/$group['xps']*100)?>%"></span>
|
||||
</div>
|
||||
<p class="xpnumeric"><?=$group['character_xps']?> / <?=$group['xps']?> XP</p>
|
||||
</div>
|
||||
</li>
|
||||
<?php endforeach?>
|
||||
</ul>
|
||||
<?php endif ?>
|
||||
<?php endforeach ?>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if(isset($quests) && !is_null($quests)) : ?>
|
||||
<h3><?=_('Quests')?></h3>
|
||||
<ul class="qglist">
|
||||
<?php foreach($quests as &$quest) : ?>
|
||||
<li class="qgtitle">
|
||||
<a href="<?=$linker->link(array('quests','quest',$seminary['url'],$questgroup['url'],$quest['url']))?>" <?php if($quest['solved']) : ?>class="solved"<?php endif ?>><i class="fa <?=($quest['solved']) ? 'fa-check-square-o' : 'fa-share-square-o'?> fa-fw"></i><?=$quest['title']?></a>
|
||||
<?php if(count($quest['relatedQuestgroups']) > 0) : ?>
|
||||
<ul class="gplist">
|
||||
<?php foreach($quest['relatedQuestgroups'] as &$relatedQuestgroup) : ?>
|
||||
<li class="qgtitle">
|
||||
<a href="<?=$linker->link(array('questgroups','questgroup',$seminary['url'],$relatedQuestgroup['url']))?>" class="bonus"><i class="fa fa-share-square-o fa-fw"><?=$relatedQuestgroup['title']?></i></a>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
<?php endif ?>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
<?php endif ?>
|
||||
17
views/html/questgroupshierarchypath/index.tpl
Normal file
17
views/html/questgroupshierarchypath/index.tpl
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
<?php if(count($parentquestgroupshierarchy) > 0) : ?>
|
||||
<ul class="breadcrumbs">
|
||||
<?php foreach($parentquestgroupshierarchy as &$hierarchy) : ?>
|
||||
<li>
|
||||
<i class="fa fa-chevron-right fa-fw"></i>
|
||||
<?php if(array_key_exists('hierarchy', $hierarchy)) : ?>
|
||||
<?php if(!is_null($hierarchy['hierarchy'])) : ?>
|
||||
<?=$hierarchy['hierarchy']['title_singular']?><?php if(array_key_exists('questgroup_pos', $hierarchy['hierarchy'])) : ?> <?=$hierarchy['hierarchy']['questgroup_pos']?><?php endif ?>:
|
||||
<?php endif ?>
|
||||
<a href="<?=$linker->link(array('questgroups','questgroup',$seminary['url'],$hierarchy['url']))?>"><?=$hierarchy['title']?></a>
|
||||
<?php else : ?>
|
||||
<a href="<?=$linker->link(array('quests','quest',$seminary['url'],$hierarchy['questgroup']['url'],$hierarchy['url']))?>"><?=$hierarchy['title']?></a>
|
||||
<?php endif ?>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
<?php endif ?>
|
||||
0
views/html/quests/index.tpl
Normal file
0
views/html/quests/index.tpl
Normal file
96
views/html/quests/quest.tpl
Normal file
96
views/html/quests/quest.tpl
Normal file
|
|
@ -0,0 +1,96 @@
|
|||
<?php if(!is_null($questgroup['picture'])) : ?>
|
||||
<div class="moodpic">
|
||||
<img src="<?=$linker->link(array('media','seminary',$seminary['url'],$questgroup['picture']['url']))?>" />
|
||||
</div>
|
||||
<?php endif ?>
|
||||
<h1><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h1>
|
||||
<?=$questgroupshierarchypath?>
|
||||
<h2><?=$quest['title']?></h2>
|
||||
|
||||
<?php if(count($questtexts) > 0) : ?>
|
||||
<section>
|
||||
<h1 id="questtext"><?=$questtexttype['type']?></h1>
|
||||
|
||||
|
||||
|
||||
<div id="qtextbox">
|
||||
<?php foreach($questtexts as &$questtext) : ?>
|
||||
<p class="qtext cf">
|
||||
<?php if(array_key_exists('media', $questtext)) : ?><img src="<?=$linker->link(array('media','seminary',$seminary['url'],$questtext['media']['url']))?>" /><?php endif ?>
|
||||
<?=\hhu\z\Utils::t($questtext['text'])?>
|
||||
</p>
|
||||
<?php if(count($questtext['relatedQuestsgroups']) > 0 || !empty($questtext['abort_text'])) : ?>
|
||||
<ul>
|
||||
<?php foreach($questtext['relatedQuestsgroups'] as &$relatedQuestgroup) : ?>
|
||||
<li><a href="<?=$linker->link(array('questgroups','questgroup',$seminary['url'],$relatedQuestgroup['url']))?>"><?=$relatedQuestgroup['entry_text']?></a></li>
|
||||
<?php endforeach ?>
|
||||
<?php if(!empty($questtext['abort_text'])) : ?>
|
||||
<li><a href="<?=$linker->link(array('quest',$seminary['url'],$relatedquesttext['quest']['questgroup_url'],$relatedquesttext['quest']['url'],$relatedquesttext['type_url']),1)?>"><?=$questtext['abort_text']?></a></li>
|
||||
<?php endif ?>
|
||||
</ul>
|
||||
<?php endif ?>
|
||||
<?php endforeach ?>
|
||||
</div>
|
||||
</section>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if(!is_null($queststatustext)) : ?>
|
||||
<section>
|
||||
<?php if($queststatus == 'solved') : ?>
|
||||
<h1><?=_('solved')?></h1>
|
||||
<?php elseif($queststatus == 'unsolved') : ?>
|
||||
<h1><?=_('unsolved')?></h1>
|
||||
<?php endif ?>
|
||||
<p><?=\hhu\z\Utils::t($queststatustext)?></p>
|
||||
</section>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if(!is_null($task)) : ?>
|
||||
<section>
|
||||
<h1 id="task"><?=_('Task')?></h1>
|
||||
<p><?=\hhu\z\Utils::t($quest['task'])?></p>
|
||||
<?=$task?>
|
||||
|
||||
<?php if($solved) : ?>
|
||||
<p><?=_('Task already successfully solved')?>:</p>
|
||||
<ul>
|
||||
<li><a href="<?=$linker->link(null,0,false,array('show-answer'=>'true'),true,'task')?>"><?=_('Show answer')?></a></li>
|
||||
<li><a href="<?=$linker->link('Epilog',5)?>">Aufgabe Überspringen</a></l>
|
||||
</ul>
|
||||
<?php endif ?>
|
||||
</section>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if(!is_null($nextquests) || !is_null($nextquestgroup)) : ?>
|
||||
<section>
|
||||
<?php if(count($nextquests) > 0) : ?>
|
||||
<ul>
|
||||
<?php foreach($nextquests as &$nextquest) : ?>
|
||||
<?php if($nextquest['id'] == $relatedquesttext['quest']['id']) : ?>
|
||||
<li>
|
||||
<?=_('Quest')?>:
|
||||
<?php if($nextquest['entered'] || !$charactedHasChoosenNextQuest) : ?>
|
||||
<a href="<?=$linker->link(array($nextquest['questgroup_url'],$nextquest['url'],$relatedquesttext['type_url']),3)?>"><?=$nextquest['title']?></a>
|
||||
<?php else : ?>
|
||||
<?=$nextquest['title']?>
|
||||
<?php endif ?>
|
||||
</li>
|
||||
<?php else : ?>
|
||||
<li>
|
||||
<?=_('Quest')?>:
|
||||
<?php if($nextquest['entered'] || !$charactedHasChoosenNextQuest) : ?>
|
||||
<a href="<?=$linker->link(array($nextquest['questgroup_url'],$nextquest['url']),3)?>"><?=$nextquest['title']?></a>
|
||||
<?php else : ?>
|
||||
<?=$nextquest['title']?>
|
||||
<?php endif ?>
|
||||
</li>
|
||||
<?php endif ?>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
<?php elseif(!is_null($nextquestgroup)) : ?>
|
||||
<a href="<?=$linker->link(array('questgroups','questgroup',$seminary['url'],$nextquestgroup['url']))?>"><?=$nextquestgroup['hierarchy']['title_singular']?> <?=$nextquestgroup['hierarchy']['questgroup_pos']?>: <?=$nextquestgroup['title']?></a>
|
||||
<?php else : ?>
|
||||
Spiel vorbei
|
||||
<?php endif ?>
|
||||
</section>
|
||||
<?php endif ?>
|
||||
17
views/html/quests/submission.tpl
Normal file
17
views/html/quests/submission.tpl
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
<?php if(!is_null($questgroup['picture'])) : ?>
|
||||
<div class="moodpic">
|
||||
<img src="<?=$linker->link(array('media','index',$seminary['url'],$questgroup['picture']['url']))?>" />
|
||||
</div>
|
||||
<?php endif ?>
|
||||
<h1><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h1>
|
||||
<?=$questgroupshierarchypath?>
|
||||
<h2><?=$quest['title']?></h2>
|
||||
|
||||
<?php if(!is_null($media)) : ?>
|
||||
<img src="<?=$linker->link(array('media','index',$seminary['url'],$media['url']))?>" />
|
||||
<?php endif ?>
|
||||
|
||||
<h2><?=sprintf(_('Submission of %s'),$character['name'])?></h2>
|
||||
<section>
|
||||
<?=$output?>
|
||||
</section>
|
||||
41
views/html/quests/submissions.tpl
Normal file
41
views/html/quests/submissions.tpl
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
<?php if(!is_null($questgroup['picture'])) : ?>
|
||||
<div class="moodpic">
|
||||
<img src="<?=$linker->link(array('media','index',$seminary['url'],$questgroup['picture']['url']))?>" />
|
||||
</div>
|
||||
<?php endif ?>
|
||||
<h1><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h1>
|
||||
<?=$questgroupshierarchypath?>
|
||||
<h2><?=$quest['title']?></h2>
|
||||
|
||||
<?php if(!is_null($media)) : ?>
|
||||
<img src="<?=$linker->link(array('media','index',$seminary['url'],$media['url']))?>" />
|
||||
<?php endif ?>
|
||||
|
||||
<section>
|
||||
<h1><?=_('submitted')?></h1>
|
||||
<ul>
|
||||
<?php foreach($submittedSubmissionCharacters as &$character) : ?>
|
||||
<li>
|
||||
<a href="<?=$linker->link(array('submission',$seminary['url'],$questgroup['url'],$quest['url'],$character['url']),1)?>"><?=$character['name']?></a>
|
||||
</li>
|
||||
<?php endforeach?>
|
||||
</ul>
|
||||
|
||||
<h1><?=_('unsolved')?></h1>
|
||||
<ul>
|
||||
<?php foreach($unsolvedSubmissionCharacters as &$character) : ?>
|
||||
<li>
|
||||
<a href="<?=$linker->link(array('submission',$seminary['url'],$questgroup['url'],$quest['url'],$character['url']),1)?>"><?=$character['name']?></a>
|
||||
</li>
|
||||
<?php endforeach?>
|
||||
</ul>
|
||||
|
||||
<h1><?=_('solved')?></h1>
|
||||
<ul>
|
||||
<?php foreach($solvedSubmissionCharacters as &$character) : ?>
|
||||
<li>
|
||||
<a href="<?=$linker->link(array('submission',$seminary['url'],$questgroup['url'],$quest['url'],$character['url']),1)?>"><?=$character['name']?></a>
|
||||
</li>
|
||||
<?php endforeach?>
|
||||
</ul>
|
||||
</section>
|
||||
10
views/html/seminaries/create.tpl
Normal file
10
views/html/seminaries/create.tpl
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
<h1><?=_('Seminaries')?></h1>
|
||||
<h2><?=_('New seminary')?></h2>
|
||||
|
||||
<form method="post" action="<?=$linker->link('create', 1)?>">
|
||||
<fieldset>
|
||||
<label for="title"><?=_('Title')?>:</label>
|
||||
<input type="text" name="title" placeholder="<?=_('Title')?>" /><br />
|
||||
</fieldset>
|
||||
<input type="submit" name="create" value="<?=_('create')?>" />
|
||||
</form>
|
||||
8
views/html/seminaries/delete.tpl
Normal file
8
views/html/seminaries/delete.tpl
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<h1><?=_('Seminaries')?></h1>
|
||||
<h2><?=_('Delete seminary')?></h2>
|
||||
|
||||
<?=sprintf(_('Should the seminary “%s” really be deleted?'), $seminary['title'])?>
|
||||
<form method="post">
|
||||
<input type="submit" name="delete" value="<?=_('delete')?>" />
|
||||
<input type="submit" name="not-delete" value="<?=_('cancel')?>" />
|
||||
</form>
|
||||
10
views/html/seminaries/edit.tpl
Normal file
10
views/html/seminaries/edit.tpl
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
<h1><?=_('Seminaries')?></h1>
|
||||
<h2><?=_('Edit seminary')?></h2>
|
||||
|
||||
<form method="post">
|
||||
<fieldset>
|
||||
<label for="title"><?=_('Title')?>:</label>
|
||||
<input type="text" name="title" placeholder="<?=_('Title')?>" value="<?=$seminary['title']?>" /><br />
|
||||
</fieldset>
|
||||
<input type="submit" name="save" value="<?=_('save')?>" />
|
||||
</form>
|
||||
17
views/html/seminaries/index.tpl
Normal file
17
views/html/seminaries/index.tpl
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
<h1><?=_('Seminaries')?></h1>
|
||||
<nav>
|
||||
<li><a href="<?=$linker->link('create', 1)?>"><?=_('Create new seminary')?></a></li>
|
||||
</nav>
|
||||
<ul>
|
||||
<?php foreach($seminaries as &$seminary) : ?>
|
||||
<li>
|
||||
<?php if(array_key_exists('media', $seminary)) : ?>
|
||||
<img src="<?=$linker->link(array('media','index',$seminary['media']['url']))?>" />
|
||||
<?php endif ?>
|
||||
<h2><a href="<?=$linker->link(array('seminary', $seminary['url']), 1)?>"><?=$seminary['title']?></a></h2>
|
||||
<details>
|
||||
<summary><?=sprintf(_('created by %s on %s'), $seminary['creator']['username'], $dateFormatter->format(new \DateTime($seminary['created'])))?></summary>
|
||||
</details>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
43
views/html/seminaries/seminary.tpl
Normal file
43
views/html/seminaries/seminary.tpl
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
<?php if(!is_null($media)) : ?>
|
||||
<div class="moodpic">
|
||||
<img src="<?=$linker->link(array('media','index',$media['url']))?>">
|
||||
</div>
|
||||
<?php endif ?>
|
||||
|
||||
<h1><a href="<?=$linker->link(array('seminaries',$seminary['url']))?>"><?=$seminary['title']?></a></h1>
|
||||
<p><?=\hhu\z\Utils::t($seminary['description'])?></p>
|
||||
|
||||
<?php foreach($questgroupshierarchy as &$hierarchy) : ?>
|
||||
<h2><?=$hierarchy['title_plural']?></h2>
|
||||
<ul class="questgroups cf">
|
||||
<?php foreach($hierarchy['questgroups'] as &$group) : ?>
|
||||
<li>
|
||||
<?php if(!is_null($group['picture'])) : ?>
|
||||
<img src="<?=$linker->link(array('media','seminary',$seminary['url'],$group['picture']['url']))?>">
|
||||
<?php endif ?>
|
||||
<section>
|
||||
<p class="fwb"><?=$hierarchy['title_singular']?> <?=$group['pos']?>:
|
||||
<a href="<?=$linker->link(array('questgroups','questgroup',$seminary['url'],$group['url']))?>"><?=$group['title']?></a></p>
|
||||
<div class="cf">
|
||||
<div class="xpbar">
|
||||
<span style="width:<?=round($group['character_xps']*100/$group['xps'])?>%"></span>
|
||||
</div>
|
||||
<p class="xpnumeric"><?=$group['character_xps']?> / <?=$group['xps']?> XP</p>
|
||||
</div>
|
||||
<?php if(array_key_exists('text', $group)) : ?>
|
||||
<p><?=$group['text']?></p>
|
||||
<?php endif ?>
|
||||
<a href="<?=$linker->link(array('questgroups','questgroup',$seminary['url'],$group['url']))?>" class="cta orange">Auf ins Abenteuer!</a>
|
||||
</section>
|
||||
</li>
|
||||
<?php endforeach?>
|
||||
</ul>
|
||||
<?php endforeach ?>
|
||||
|
||||
<nav>
|
||||
<li><a href="<?=$linker->link('edit', 3)?>"><?=_('Edit seminary')?></a></li>
|
||||
<li><a href="<?=$linker->link('delete', 3)?>"><?=_('Delete seminary')?></a></li>
|
||||
</nav>
|
||||
<p>
|
||||
<?=sprintf(_('created by %s on %s'), $seminary['creator']['username'], $dateFormatter->format(new \DateTime($seminary['created'])))?>
|
||||
</p>
|
||||
7
views/html/seminarymenu/index.tpl
Normal file
7
views/html/seminarymenu/index.tpl
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
<menu>
|
||||
<li><a href="<?=$linker->link(array('seminaries',$loggedSeminary['url']))?>"><?=$loggedSeminary['title']?></a></li>
|
||||
<?php if(count(array_intersect(array('admin','moderator'),$loggedUser['roles'])) > 0) : ?><li><a href="<?=$linker->link(array('characters',$loggedSeminary['url']))?>"><i class="fa fa-users fa-fw"></i><?=_('Characters')?></a></li><?php endif ?>
|
||||
<li><a href="<?=$linker->link(array('charactergroups','index',$loggedSeminary['url']))?>"><i class="fa fa-users fa-fw"></i><?=_('Character Groups')?></a></li>
|
||||
<li><a href="<?=$linker->link(array('achievements','index',$loggedSeminary['url']))?>"><i class="fa fa-trophy fa-fw"></i><?=_('Achievements')?></a></li>
|
||||
<li><a href="<?=$linker->link(array('library','index',$loggedSeminary['url']))?>"><i class="fa fa-book fa-fw"></i><?=_('Library')?></a></li>
|
||||
</menu>
|
||||
5
views/html/userroles/user.tpl
Normal file
5
views/html/userroles/user.tpl
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
<ul>
|
||||
<?php foreach($roles as &$role) : ?>
|
||||
<li><?=$role['name']?></li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
18
views/html/users/create.tpl
Normal file
18
views/html/users/create.tpl
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
<h1><?=_('Users')?></h1>
|
||||
<h2><?=_('New user')?></h2>
|
||||
|
||||
<form method="post" action="<?=$linker->link('create', 1)?>">
|
||||
<fieldset>
|
||||
<label for="username"><?=_('Username')?>:</label>
|
||||
<input type="text" name="username" placeholder="<?=_('Username')?>" /><br />
|
||||
<label for="prename"><?=_('Prename')?>:</label>
|
||||
<input name="prename" type="text" placeholder="<?=_('Prename')?>" /><br />
|
||||
<label for="surname"><?=_('Surname')?>:</label>
|
||||
<input name="surname" type="text" placeholder="<?=_('Surname')?>" /><br />
|
||||
<label for="email"><?=_('E‑mail address')?>:</label>
|
||||
<input type="email" name="email" placeholder="<?=_('E‑mail address')?>" /><br />
|
||||
<label for="password"><?=_('Password')?>:</label>
|
||||
<input type="password" name="password" placeholder="<?=_('Password')?>" /><br />
|
||||
</fieldset>
|
||||
<input type="submit" name="create" value="<?=_('create')?>" />
|
||||
</form>
|
||||
8
views/html/users/delete.tpl
Normal file
8
views/html/users/delete.tpl
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<h1><?=_('Users')?></h1>
|
||||
<h2><?=_('Delete user')?></h2>
|
||||
|
||||
<?=sprintf(_('Should the user “%s” (%s) really be deleted?'), $user['username'], $user['email'])?>
|
||||
<form method="post">
|
||||
<input type="submit" name="delete" value="<?=_('delete')?>" />
|
||||
<input type="submit" name="not-delete" value="<?=_('cancel')?>" />
|
||||
</form>
|
||||
18
views/html/users/edit.tpl
Normal file
18
views/html/users/edit.tpl
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
<h1><?=_('Users')?></h1>
|
||||
<h2><?=_('Edit user')?></h2>
|
||||
|
||||
<form method="post">
|
||||
<fieldset>
|
||||
<label for="username"><?=_('Username')?>:</label>
|
||||
<input type="text" name="username" placeholder="<?=_('Username')?>" value="<?=$user['username']?>" /><br />
|
||||
<label for="prename"><?=_('Prename')?>:</label>
|
||||
<input name="prename" type="text" placeholder="<?=_('Prename')?>" value="<?=$user['prename']?>" /><br />
|
||||
<label for="surname"><?=_('Surname')?>:</label>
|
||||
<input name="surname" type="text" placeholder="<?=_('Surname')?>" value="<?=$user['surname']?>" /><br />
|
||||
<label for="email"><?=_('E‑mail address')?>:</label>
|
||||
<input type="email" name="email" placeholder="<?=_('E‑mail address')?>" value="<?=$user['email']?>" /><br />
|
||||
<label for="password"><?=_('Password')?>:</label>
|
||||
<input type="password" name="password" placeholder="<?=_('Password')?>" /><br />
|
||||
</fieldset>
|
||||
<input type="submit" name="save" value="<?=_('save')?>" />
|
||||
</form>
|
||||
14
views/html/users/index.tpl
Normal file
14
views/html/users/index.tpl
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
<h1><?=_('Users')?></h1>
|
||||
<nav>
|
||||
<li><a href="<?=$linker->link('create', 1)?>"><?=_('Create new user')?></a></li>
|
||||
</nav>
|
||||
<ul>
|
||||
<?php foreach($users as &$user) : ?>
|
||||
<li>
|
||||
<h2><a href="<?=$linker->link(array('user', $user['username']), 1)?>"><?=$user['username']?></a></h2>
|
||||
<details>
|
||||
<summary><?=sprintf(_('registered on %s'), $dateFormatter->format(new \DateTime($user['created'])))?></summary>
|
||||
</details>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
15
views/html/users/login.tpl
Normal file
15
views/html/users/login.tpl
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
<h1><?=_('Users')?></h1>
|
||||
|
||||
<h2><?=_('Login')?></h2>
|
||||
<?php if($failed) : ?>
|
||||
<p class="invalid"><?=_('Login failed')?>.</p>
|
||||
<?php endif ?>
|
||||
<form method="post" action="<?=$linker->link(array(), 2)?>">
|
||||
<fieldset>
|
||||
<label for="username"><?=_('Username')?>:</label>
|
||||
<input name="username" type="text" placeholder="<?=_('Username')?>" value="<?=$username?>" required="required" /><br />
|
||||
<label for="password"><?=_('Password')?>:</label>
|
||||
<input name="password" type="password" placeholder="<?=_('Password')?>" required="required" /><br />
|
||||
</fieldset>
|
||||
<input type="submit" name="login" value="<?=_('Login')?>" />
|
||||
</form>
|
||||
0
views/html/users/logout.tpl
Normal file
0
views/html/users/logout.tpl
Normal file
88
views/html/users/register.tpl
Normal file
88
views/html/users/register.tpl
Normal file
|
|
@ -0,0 +1,88 @@
|
|||
<h1><?=_('Users')?></h1>
|
||||
|
||||
<h2><?=_('Registration')?></h2>
|
||||
<?php if(!empty($validation)) : ?>
|
||||
<ul>
|
||||
<?php foreach($validation as $field => &$settings) : ?>
|
||||
<?php if($settings !== true) : ?>
|
||||
<li>
|
||||
<ul>
|
||||
<?php foreach($settings as $setting => $value) : ?>
|
||||
<li>
|
||||
<?php switch($field) {
|
||||
case 'username':
|
||||
switch($setting) {
|
||||
case 'minlength': printf(_('Username is too short (min. %d chars)'), $value);
|
||||
break;
|
||||
case 'maxlength': printf(_('Username is too long (max. %d chars)'), $value);
|
||||
break;
|
||||
case 'regex': echo _('Username contains illegal characters');
|
||||
break;
|
||||
default: echo _('Username invalid');
|
||||
}
|
||||
break;
|
||||
case 'prename':
|
||||
switch($setting) {
|
||||
case 'minlength': printf(_('Prename is too short (min. %d chars)'), $value);
|
||||
break;
|
||||
case 'maxlength': printf(_('Prename is too long (max. %d chars)'), $value);
|
||||
break;
|
||||
case 'regex': printf(_('Prename contains illegal characters'));
|
||||
break;
|
||||
default: echo _('Prename invalid');
|
||||
}
|
||||
break;
|
||||
case 'surname':
|
||||
switch($setting) {
|
||||
case 'minlength': printf(_('Surname is too short (min. %d chars)'), $value);
|
||||
break;
|
||||
case 'maxlength': printf(_('Surname is too long (max. %d chars)'), $value);
|
||||
break;
|
||||
case 'regex': printf(_('Surname contains illegal characters'));
|
||||
break;
|
||||
default: echo _('Surname invalid');
|
||||
}
|
||||
break;
|
||||
case 'email':
|
||||
switch($setting) {
|
||||
case 'regex': echo _('E‑mail address invalid');
|
||||
break;
|
||||
default: echo _('E‑mail address invalid');
|
||||
}
|
||||
break;
|
||||
case 'password':
|
||||
switch($setting) {
|
||||
case 'minlength': printf(_('Password is too short (min. %d chars)'), $value);
|
||||
break;
|
||||
case 'maxlength': printf(_('Password is too long (max. %d chars)'), $value);
|
||||
break;
|
||||
default: echo _('Password invalid');
|
||||
}
|
||||
break;
|
||||
default:
|
||||
echo $exception->getMessage();
|
||||
break;
|
||||
} ?>
|
||||
</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
</li>
|
||||
<?php endif ?>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
<?php endif ?>
|
||||
<form method="post" action="<?=$linker->link(array(), 2)?>">
|
||||
<fieldset>
|
||||
<label for="username"><?=_('Username')?>:</label>
|
||||
<input name="username" type="text" placeholder="<?=_('Username')?>" title="<?=_('Username')?>" required="required" maxlength="<?=$validationSettings['username']['maxlength']?>" value="<?=$username?>" <?=(array_key_exists('username', $validation)) ? 'class="invalid"' : null?> /><br />
|
||||
<label for="prename"><?=_('Prename')?>:</label>
|
||||
<input name="prename" type="text" placeholder="<?=_('Prename')?>" title="<?=_('Prename')?>" required="required" maxlength="<?=$validationSettings['prename']['maxlength']?>" value="<?=$prename?>" <?=(array_key_exists('prename', $validation)) ? 'class="invalid"' : null?> /><br />
|
||||
<label for="surname"><?=_('Surname')?>:</label>
|
||||
<input name="surname" type="text" placeholder="<?=_('Surname')?>" title="<?=_('Surname')?>" required="required" maxlength="<?=$validationSettings['surname']['maxlength']?>" value="<?=$surname?>" <?=(array_key_exists('surname', $validation)) ? 'class="invalid"' : null?> /><br />
|
||||
<label for="email"><?=_('E‑mail address')?>:</label>
|
||||
<input name="email" type="email" placeholder="<?=_('E‑mail address')?>" title="<?=_('E‑mail address')?>" required="required" value="<?=$email?>" <?=(array_key_exists('email', $validation)) ? 'class="invalid"' : null?> /><br />
|
||||
<label for="password"><?=_('Password')?>:</label>
|
||||
<input name="password" type="password" placeholder="<?=_('Password')?>" title="<?=_('Password')?>" required="required" maxlength="<?=$validationSettings['password']['maxlength']?>" <?=(array_key_exists('password', $validation)) ? 'class="invalid"' : null?> /><br />
|
||||
</fieldset>
|
||||
<input type="submit" name="register" value="<?=_('Register')?>" />
|
||||
</form>
|
||||
19
views/html/users/user.tpl
Normal file
19
views/html/users/user.tpl
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
<h1><?=_('Users')?></h1>
|
||||
<h2><?=$user['username']?></h2>
|
||||
<nav>
|
||||
<li><a href="<?=$linker->link('edit', 3)?>"><?=_('Edit user')?></a></li>
|
||||
<li><a href="<?=$linker->link('delete', 3)?>"><?=_('Delete user')?></a></li>
|
||||
</nav>
|
||||
<p>
|
||||
<?=sprintf(_('registered on %s'), $dateFormatter->format(new \DateTime($user['created'])))?>
|
||||
</p>
|
||||
|
||||
<h2><?=_('Characters')?></h2>
|
||||
<ul>
|
||||
<?php foreach($characters as &$character) : ?>
|
||||
<li><a href="<?=$linker->link(array('characters','character',$character['seminary_url'],$character['url']))?>"><?=$character['name']?></a> (<?=$character['xps']?> XPs, <?=_('Level')?> <?=$character['xplevel']['level']?><?php if(!is_null($character['xplevel']['name'])) : ?>: <?=$character['xplevel']['name']?><?php endif ?>) (<a href="<?=$linker->link(array('seminaries',$character['seminary_url']))?>"><?=$character['seminary_title']?></a>)</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
|
||||
<h2><?=_('Roles')?></h2>
|
||||
<?=$userroles?>
|
||||
1
views/inlineerror.tpl
Normal file
1
views/inlineerror.tpl
Normal file
|
|
@ -0,0 +1 @@
|
|||
<p>Dieser Teil der Anwendung steht zur Zeit leider nicht zur Verfügung.</p>
|
||||
Loading…
Add table
Add a link
Reference in a new issue