Layout and other changes
Before Width: | Height: | Size: 44 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 71 KiB |
Before Width: | Height: | Size: 263 B After Width: | Height: | Size: 1.5 KiB |
|
@ -28,14 +28,18 @@ If (!defined("in_astat")) {
|
|||
die("Dieses Script kann nicht ausserhalb des Frameworks laufen!");
|
||||
}
|
||||
$session->page_begin("Nickpage", FALSE);
|
||||
use Smarty\Smarty;
|
||||
|
||||
class nickpage extends module{
|
||||
var $mybb_conf,$session;
|
||||
|
||||
function __construct(){
|
||||
parent::__construct();
|
||||
$this->mybb_conf = $this->fetchboardconfig();
|
||||
}
|
||||
|
||||
function output(){
|
||||
global $module,$tpl,$config,$db,$log,$core,$error, $session;
|
||||
global $module,$config,$db,$log,$core,$error, $session;
|
||||
|
||||
$count=20;
|
||||
|
||||
|
@ -49,12 +53,13 @@ class nickpage extends module{
|
|||
$user['sitetitle']='Nickpage nicht gefunden';
|
||||
}else{
|
||||
$parser=new textparser();
|
||||
|
||||
$loggedin = false;
|
||||
$db->free_result($result);
|
||||
|
||||
$user['sitetitle']='Nickpage von '.$user['username'];
|
||||
|
||||
$result=$db->query("SELECT * FROM `" . $this->mybb_conf['prefix'] . "users` WHERE `uid`='".$user['fuid']."' LIMIT 1");
|
||||
if($session->userdata['uid']!=0){
|
||||
$loggedin = true;
|
||||
}
|
||||
$result=$db->query("SELECT * FROM `" . $this->mybb_conf["prefix"] . "users` WHERE `uid`='".$user['fuid']."' LIMIT 1");
|
||||
$forum=$db->fetch_array($result);
|
||||
$db->free_result($result);
|
||||
|
||||
|
@ -62,7 +67,7 @@ class nickpage extends module{
|
|||
$chat=$db->fetch_array($result);
|
||||
$db->free_result($result);
|
||||
|
||||
$result=$db->query("SELECT count(`id`) as `count` FROM `" . $config['prefix'] . "npguestbook` WHERE `guid`='".$user['uid']."'");
|
||||
$result=$db->query("SELECT count(`id`) as `count` FROM `" . $config["prefix"] . "npguestbook` WHERE `guid`='".$user['uid']."'");
|
||||
$gb_count=$db->fetch_array($result);
|
||||
$gb_pages=ceil($gb_count['count']/$count);
|
||||
$db->free_result($result);
|
||||
|
@ -76,8 +81,8 @@ class nickpage extends module{
|
|||
}else{
|
||||
$user['age'] = 'unbekannt';
|
||||
}
|
||||
|
||||
if(!$_GET['page'] || $_GET['page']=="first"){
|
||||
$page = 0;
|
||||
if(!isset($_GET['page']) || $_GET['page']=="first"){
|
||||
$start=0;
|
||||
}elseif($_GET['page']=="last"){
|
||||
$page=$gb_pages-1;
|
||||
|
@ -118,10 +123,10 @@ class nickpage extends module{
|
|||
$user['chattime']=$this->intervall($chat['chattime']);
|
||||
$user['reviewnum']=$reviews['count'];
|
||||
switch($chat['rights']){
|
||||
case(3):
|
||||
case(99):
|
||||
$user['chatright']='Chatadmin';
|
||||
break;
|
||||
case(2):
|
||||
case(50):
|
||||
$user['chatright']='Chat-VIP';
|
||||
break;
|
||||
}
|
||||
|
@ -136,6 +141,7 @@ class nickpage extends module{
|
|||
}
|
||||
//$forum['buddylist'];
|
||||
if($session->userdata['uid']!=""){
|
||||
|
||||
$result=$db->query("SELECT `buddylist` FROM `" . $this->mybb_conf["prefix"] . "users` WHERE `uid`='".$session->userdata['fuid']."' LIMIT 1");
|
||||
$friends=$db->fetch_array($result);
|
||||
$db->free_result($result);
|
||||
|
@ -174,16 +180,17 @@ class nickpage extends module{
|
|||
$db->free_result($result);
|
||||
}
|
||||
}
|
||||
$tpl->assign('friends',$friendl);
|
||||
$tpl->assign('user',$user);
|
||||
$tpl->assign('forum',$forum);
|
||||
$tpl->assign('domain',$config['domain']);
|
||||
$tpl->assign('gb',$gb);
|
||||
$tpl->assign('pagination',$pagination);
|
||||
//$content=$this->tpl->fetch('nickpage_content.tpl');
|
||||
|
||||
$this->tpl->assign('friends',$friendl);
|
||||
$this->tpl->assign('user',$user);
|
||||
$this->tpl->assign('forum',$forum);
|
||||
$this->tpl->assign('loggedin',$loggedin);
|
||||
$this->tpl->assign('domain',$config['domain']);
|
||||
$this->tpl->assign('gb',$gb);
|
||||
$this->tpl->assign('pagination',$pagination);
|
||||
$content=$this->tpl->fetch('nickpage.tpl');
|
||||
}
|
||||
$tpl->assign('user',$user);
|
||||
$core->make_page($content,TRUE,$config['fullpath'].'/modules/nickpage/templates/default/nickpage.tpl',NULL,NULL);
|
||||
$core->make_page($content,TRUE,$config['fullpath'].'/modules/nickpage/templates/default/nickpage_content.tpl',NULL,NULL);
|
||||
}
|
||||
|
||||
function output_edit(){
|
||||
|
|
|
@ -13,13 +13,15 @@
|
|||
<div id="content-wrap">
|
||||
<div class="row add-bottom">
|
||||
<div class="six columns add-bottom">
|
||||
<h3>Über {$user.username}</h3>
|
||||
<h3>Über {$user.username} <img src="images/{$user.gender}.png" style="float: right;"></h3>
|
||||
<p><img class="pull-left" src="/forum/{$user.np_picture}" alt="Ist das {$user.username}?">
|
||||
{$user.fid2}</p><div id="gender"><img src="/npimages/{$user.gender}.png" /></div>
|
||||
{$user.fid2}</p>
|
||||
</div>
|
||||
<div class="six columns add-bottom">
|
||||
<h3>Über mich:</h3>
|
||||
{if $user.birthdayprivacy != none}
|
||||
<p>Alter: {$user.age}<br />
|
||||
{/if}
|
||||
<ul>
|
||||
<li><a href="//{$domain}/forum/private.php?action=send&uid={$user.fuid}">PN an {$user.username}</a></li>
|
||||
<li>Forenposts: <a href="//{$domain}/forum/search.php?action=finduser&uid={$user.fuid}">{$forum.postnum}</a></li>
|
||||
|
@ -48,9 +50,10 @@
|
|||
</div>
|
||||
</div> <!-- Row End-->
|
||||
{/if}
|
||||
<hr>
|
||||
|
||||
<div class="row section-head">
|
||||
{if $gb!=""}
|
||||
<hr>
|
||||
{$pagination}
|
||||
{foreach from=$gb item=g}
|
||||
<div class="twelve columns">
|
||||
|
@ -73,13 +76,22 @@
|
|||
</nav>
|
||||
|
||||
</div>
|
||||
|
||||
<hr>
|
||||
{else}
|
||||
<hr>
|
||||
<div class="twelve columns">
|
||||
<p>Keine Einträge. Schreib doch einfach einen. ;-)</p>
|
||||
</div>
|
||||
<hr>
|
||||
{/if}
|
||||
{if $loggedin==true}
|
||||
<h3>Gästebucheintrag schreiben:</h3>
|
||||
<form action="/np/{$user.username}/gbentry" method="post">
|
||||
<textarea name="gbeintrag" id="gb"></textarea>
|
||||
<input type="hidden" name="user" value="{$g.username}" />
|
||||
<input type="submit" class="button" name="submit" value="Absenden">
|
||||
</form>
|
||||
{/if}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<footer>
|
||||
|
|
|
@ -38,7 +38,11 @@
|
|||
================================================== -->
|
||||
<script src="{$themepath}/js/modernizr.js"></script>
|
||||
<script defer src="{$themepath}/js/fontawesome/all.min.js"></script>
|
||||
<!--<script src="{$themepath}/js/jquery-3.2.1.min.js"></script>-->
|
||||
|
||||
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
|
||||
<script src="{$themepath}/js/wysibb/jquery.wysibb.min.js"></script>
|
||||
<link rel="stylesheet" href="{$themepath}/js/wysibb/theme/default/wbbtheme.css" />
|
||||
<!-- Favicons
|
||||
================================================== -->
|
||||
<link rel="shortcut icon" href="favicon.png" />
|
||||
|
@ -46,10 +50,17 @@
|
|||
|
||||
<!-- Java Script
|
||||
================================================== -->
|
||||
<script src="{$themepath}/js/jquery-3.2.1.min.js"></script>
|
||||
|
||||
<script src="{$themepath}/js/main.js"></script>
|
||||
<script src="/js/odo/odometer.min.js"></script>
|
||||
{$footer}
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
var wbbOpt = {
|
||||
buttons: "bold,italic,underline,strike,sup,sub,|,img,link,|,code,quote"
|
||||
}
|
||||
$("#gb").wysibb(wbbOpt);
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|