本文整理汇总了PHP中pathang::render方法的典型用法代码示例。如果您正苦于以下问题:PHP pathang::render方法的具体用法?PHP pathang::render怎么用?PHP pathang::render使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类pathang
的用法示例。
在下文中一共展示了pathang::render方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: krishna
public function krishna()
{
$request = pathang::getInstance('request');
$request->page = 'color';
$request->color = 'red';
pathang::render('sample', 'krishna');
}
示例2: showMembers
public function showMembers()
{
$count = pathang::getInstance('pathang')->FEEDSTACK->MEMBER_COUNT;
$from = pathang::getInstance('request')->get('from');
if ($from) {
$members = pathang::GetModel('usermain')->listMembers($count, $from);
} else {
$members = pathang::GetModel('usermain')->listMembers($count);
}
$users = new stdClass();
foreach ($members as $a => $b) {
$temp = new stdClass();
foreach ($b as $x => $y) {
$temp->{$x} = $y;
}
$temp->image = '';
$temp->profile_link = ROOT . $temp->username;
$users->{$a} = $temp;
}
$result = pathang::GetHelper('userlog')->getUsersImage($users);
$basket = pathang::GetInstance('basket');
$basket->set('members', $result);
$basket->set('count', $count);
$basket->set('heading', 'Members');
if ($from) {
pathang::render('members', 'members_loadmore');
} else {
pathang::render('members');
}
}
示例3: theme
public function theme()
{
$request = pathang::getInstance('request');
$request->page = 'color';
$request->color = 'voilet';
pathang::render('sample', 'themes');
}
示例4: admin
public function admin()
{
$n2 = strtoupper(pathang::getInstance('node')->get('n2'));
$liveuser_id = null;
$liveuser = pathang::GetInstance('session')->get('liveuser');
if ($liveuser) {
$liveuser_id = $liveuser->id;
}
$isadmin = pathang::getModel('userlog')->isAdmin($liveuser_id);
if (!$isadmin) {
pathang::GetInstance('pathang')->SITE->PAGE = 'login';
$basket = pathang::GetInstance('basket');
$basket->set('heading', 'Restricted Access !');
$basket->set('message', 'You dont have enough privilege to acces this page. Sorry for the inconvenience. ');
pathang::render('general', 'errorpage');
exit;
} else {
if ($n2 == null) {
$n2 = 'main';
}
pathang::getController('admin')->{$n2}();
}
}
示例5: logout
public function logout()
{
$session = pathang::getInstance('session');
$session->destroy();
pathang::getInstance('pathang')->SITE->PAGE = 'login';
pathang::render('userlog', 'login');
}
示例6: crop
public function crop()
{
$user = pathang::getInstance('node')->get('n1');
$basket = pathang::GetInstance('basket');
$liveuser = pathang::getInstance('session')->get('liveuser')->username;
if ($user == $liveuser) {
pathang::getInstance('pathang')->SITE->PAGE = 'no_responsive';
pathang::render('profile', 'crop');
} else {
pathang::getInstance('pathang')->SITE->PAGE = 'login';
$basket->set('heading', 'Restricted Access');
$basket->set('message', 'You dont have enough permission to access this page.');
pathang::render('general', 'errorpage');
exit;
}
}
示例7: page
public function page()
{
$request = pathang::getInstance('request');
$basket = pathang::getInstance('basket');
if ($request->get('post')) {
file_put_contents('app/views/general/about.php', $request->Get('about'));
file_put_contents('app/views/general/terms.php', $request->Get('terms'));
file_put_contents('app/views/general/contact.php', $request->Get('contact'));
}
$about = file_get_contents(ROOT . 'about.html');
$terms = file_get_contents(ROOT . 'terms.html');
$contact = file_get_contents(ROOT . 'contact.html');
$basket->set('about', $about);
$basket->set('terms', $terms);
$basket->set('contact', $contact);
pathang::render('admin', 'page');
}
示例8: showLikers
public function showLikers()
{
$request = pathang::getInstance('request');
$feed_id = $request->get('feed_id');
$likersArray = pathang::getModel('feed')->feedLikers($feed_id);
$feedLikers = new stdclass();
foreach ($likersArray as $a => $b) {
$feedLikerObj = new stdClass();
foreach ($b as $c => $d) {
$feedLikerObj->{$c} = $d;
}
$feedLikerObj->image = '';
$feedLikerObj->profile_link = ROOT . $feedLikerObj->username;
$feedLikerObj->image = pathang::getHelper('userlog')->getUserImage($feedLikerObj);
$feedLikers->{$a} = $feedLikerObj;
}
pathang::getInstance('basket')->set('likers', $feedLikers);
pathang::render('feed', 'feed_likers');
}