本文整理匯總了PHP中tsurl函數的典型用法代碼示例。如果您正苦於以下問題:PHP tsurl函數的具體用法?PHP tsurl怎麽用?PHP tsurl使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了tsurl函數的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: index
public function index()
{
$page = isset($_GET['page']) ? intval($_GET['page']) : '1';
$url = tsurl('feed', 'index', array('page' => ''));
$lstart = $page * 20 - 20;
$arrFeeds = $this->findAll('feed', null, 'addtime desc', null, $lstart . ',20');
$feedNum = $this->findCount("feed");
$pageUrl = pagination($feedNum, 20, $page, $url);
if ($page > 1) {
$title = '社區動態 - 第' . $page . '頁';
} else {
$title = '社區動態';
}
foreach ($arrFeeds as $key => $item) {
$data = json_decode($item['data'], true);
if (is_array($data)) {
foreach ($data as $key => $itemTmp) {
$tmpkey = '{' . $key . '}';
$tmpdata[$tmpkey] = stripslashes(urldecode($itemTmp));
}
}
$arrFeed[] = array('user' => aac('user')->getOneUser($item['userid']), 'content' => strtr($item['template'], $tmpdata), 'addtime' => $item['addtime']);
}
include template('index');
}
示例2: add
public function add()
{
$js = intval($_GET['js']);
$userid = aac('user')->isLogin(1);
//判斷發布者狀態
/*
if(aac('user')->isPublisher()==false) {
getJson('不好意思,你還沒有權限發布內容!',$js);
}
*/
if ($_POST['token'] != $_SESSION['token']) {
getJson('非法操作!', $js);
}
$content = tsClean($_POST['content']);
if ($content == '') {
getJson('內容不能為空', $js);
}
$isaudit = 0;
//過濾內容開始
aac('system')->antiWord($content);
//過濾內容結束
$weiboid = $this->create('weibo', array('userid' => $userid, 'locationid' => aac('user')->getLocationId($userid), 'content' => $content, 'isaudit' => $isaudit, 'addtime' => date('Y-m-d H:i:s'), 'uptime' => date('Y-m-d H:i:s')));
//feed開始
$feed_template = '<span class="pl">說:</span><div class="quote"><span class="inq">{content}</span> <span><a class="j a_saying_reply" href="{link}" rev="unfold">回應</a></span></div>';
$feed_data = array('link' => tsurl('weibo', 'show', array('id' => $weiboid)), 'content' => cututf8(t($content), '0', '50'));
aac('feed')->add($userid, $feed_template, $feed_data);
//feed結束
getJson('發布成功!', $js, 2, tsurl('weibo', 'show', array('id' => $weiboid)));
}
示例3: tsurl
?>
">最新圖</a></li>
<?php
if ($ac == 'album' && $ts == 'user') {
?>
<li role="presentation" class="active"><a href="<?php
echo tsurl('photo', 'album', array(ts => user, userid => $userid));
?>
">我的圖</a></li>
<?php
}
if ($ts != 'user' && intval($TS_USER['userid']) > '0') {
?>
<li role="presentation"><a href="<?php
echo tsurl('photo', 'album', array(ts => user, userid => $TS_USER['userid']));
?>
">我的圖</a></li>
<?php
}
?>
<li role="presentation" <?php
if ($ac == 'create') {
?>
class="active"<?php
}
?>
><a href="<?php
echo tsurl('photo', 'create');
?>
">創建圖</a></li>
</ul>
示例4: tsurl
}
?>
><a href="<?php
echo tsurl('message', 'friend');
?>
"><i class="icon-envelope"></i>私信</a></li>
</ul>
<ul class="menus">
<li <?php
if ($app == 'my' && $ac == 'setting') {
?>
class="active"<?php
}
?>
><a href="<?php
echo tsurl('my', 'setting', array('ts' => 'base'));
?>
"><i class="icon-gear"></i>賬戶設置</a></li>
<li <?php
if ($app == 'my' && $ac == 'score') {
?>
class="active"<?php
}
?>
><a href="<?php
echo tsurl('my', 'score');
?>
"><i class="icon-money"></i>積分</a></li>
</ul>
</div>
示例5: tsurl
<li class="br"><span class="fs14"><a href="<?php
echo tsurl('user', 'group', array('id' => $strUser['userid']));
?>
"><?php
echo $strUser['count_group'];
?>
</a></span><br />文化</li>
<li><span class="fs14"><a href="<?php
echo tsurl('user', 'follow', array('id' => $strUser['userid']));
?>
"><?php
echo $strUser['count_follow'];
?>
</a></span><br />關注</li>
<li class="br"><span class="fs14"><a href="<?php
echo tsurl('user', 'followed', array('id' => $strUser['userid']));
?>
"><?php
echo $strUser['count_followed'];
?>
</a></span><br />粉絲</li>
</ul>
<div class="fmore">
<?php
if ($strUser['signed']) {
echo nl2br(htmlspecialchars($strUser['signed']));
?>
<br /><?php
} elseif ($strUser['userid'] == $TS_USER['userid']) {
?>
簽名:親~還沒有簽名,趕快去寫一個吧<br /><?php
示例6: tsurl
?>
"><?php
echo $item['title'];
?>
</a>
<?php
} else {
echo $item['title'];
?>
</a>
<?php
}
if ($item['postby'] == 1) {
?>
<a href="<?php
echo tsurl('home', 'phone');
?>
"><img align="absmiddle" alt="通過Iphone手機端發布" title="通過Iphone手機端發布" src="<?php
echo SITE_URL;
?>
public/images/ios.jpg" /></a><?php
}
?>
</div>
<div class="topic_info">
<div class="re_desc"><?php
echo $item['desc'];
?>
</div>
</div>
</div>
示例7: tsurl
echo tsurl('group', 'edit', array('groupid' => $strGroup['groupid'], 'ts' => 'type'));
?>
">帖子分類</a></li>
<li role="presentation" <?php
if ($ts == "cate") {
?>
class="active"<?php
}
?>
><a href="<?php
echo tsurl('group', 'edit', array('groupid' => $strGroup['groupid'], 'ts' => 'cate'));
?>
">文化分類</a></li>
<?php
if ($strGroup['joinway'] == 2) {
?>
<li role="presentation" <?php
if ($ts == "useraudit") {
?>
class="active"<?php
}
?>
><a href="<?php
echo tsurl('group', 'edit', array('groupid' => $strGroup['groupid'], 'ts' => 'useraudit'));
?>
">成員審核</a></li>
<?php
}
?>
</ul>
<div style="height:20px;"></div>
示例8: tsurl
<div class="col-md-4"></div>
<div class="col-md-4">
<form role="form" method="POST" action="<?php
echo tsurl('photo', 'create', array('ts' => 'do'));
?>
">
<div class="form-group">
<input type="text" name="albumname" class="form-control" placeholder="圖名" >
</div>
<div class="form-group">
<textarea class="form-control" rows="3" name="albumdesc" placeholder="圖介紹"></textarea>
</div>
<input type="hidden" name="token" value="<?php
echo $_SESSION['token'];
?>
" />
<button class="btn btn-success" type="submit">創建圖</button> <a href="<?php
echo tsurl('photo', 'album', array(ts => user, userid => $userid));
?>
">返回我的圖</a>
</form>
<p>
</p>
</div>
<div class="col-md-4"></div>
</div>
</div>
</div>
</div>
<?php
include template('footer');
示例9: tsurl
<li role="presentation" <?php
if ($ac == 'my') {
?>
class="active"<?php
}
?>
><a href="<?php
echo tsurl('message', 'my');
?>
">最新消息</a></li>
<li role="presentation" <?php
if ($ac == 'system') {
?>
class="active"<?php
}
?>
><a href="<?php
echo tsurl('message', 'system');
?>
">係統消息</a></li>
<li role="presentation" <?php
if ($ac == 'friend' || $ac == 'user') {
?>
class="active"<?php
}
?>
><a href="<?php
echo tsurl('message', 'friend');
?>
">好友消息</a></li>
</ul>
示例10: tsurl
<div class="form-group">
<input type="hidden" name="jump" value="<?php
echo $jump;
?>
" />
<input type="hidden" name="token" value="<?php
echo $_SESSION['token'];
?>
" />
<button id="comm-submit" type="submit" class="btn btn-fat btn-success iw">登錄</button>
</div>
<div><a href="<?php
echo tsurl('user', 'register');
?>
">還沒有注冊?</a> | <a href="<?php
echo tsurl('user', 'forgetpwd');
?>
">忘記密碼?</a></div>
<div class="form-group">
<div class="checkbox">
<label>
<input type="checkbox" name="cktime" value="31536000"> 記住我
</label>
</div>
</div>
</form>
<div>
<?php
doAction('user_login_footer');
?>
</div>
示例11: template
<div class="bc">
<?php
include template('menu');
?>
<div class="albumlist">
<ul>
<?php
foreach ((array) $arrAlbum as $key => $item) {
?>
<li>
<div>
<h2><a href="<?php
echo tsurl('attach', 'album', array('id' => $item['albumid']));
?>
"><?php
echo $item['title'];
?>
</a></h2>
<p>作者:<?php
echo $item['user']['username'];
?>
</p>
<p>時間:<?php
echo date('Y-m-d', strtotime($item['addtime']));
?>
</p>
<p>資料:<?php
echo $item['count_attach'];
示例12: tsurl
<?php
if ($strUser['face'] == '' && intval($TS_SITE['isface']) == 1) {
?>
<div class="alert alert-info">提示:你必須上傳頭像才可以正常使用本社區</div>
<?php
}
if ($strUser['path']) {
?>
<div class="alert alert-success">
您已經上傳頭像!現在可以隨便點點看看我們的社區!
</div>
<?php
} else {
?>
<form method="post" action="<?php
echo tsurl('user', 'verify', array('ts' => 'facedo'));
?>
" enctype="multipart/form-data">
<div class="form-group">
<label>上傳頭像:</label>
<p><img alt="<?php
echo $strUser['username'];
?>
" src="<?php
echo $strUser['face'];
?>
?v=<?php
echo rand();
?>
" width="120" /></p>
</div>
示例13: foreach
</div>
<div class="page"><?php
echo $pageUrl;
?>
</div>
</div>
<div class="cright">
<div class="bbox">
<div class="btitle">熱門標簽</div>
<div class="bc">
<div class="tags">
<?php
foreach ((array) $arrTag as $key => $item) {
?>
<a href="<?php
echo tsurl('article', 'tag', array('id' => urlencode($item['tagname'])));
?>
"><?php
echo $item['tagname'];
?>
</a>
<?php
}
?>
</div>
</div>
</div>
</div>
</div>
</div>
<?php
示例14: tsurl
<input type="radio" name="iscommentshow" value="1" <?php
if ($strTopic['iscommentshow'] == '1') {
?>
checked="select"<?php
}
?>
/>需要
</div>
<input type="hidden" name="topicid" value="<?php
echo $strTopic['topicid'];
?>
" />
<input type="hidden" name="token" value="<?php
echo $_SESSION['token'];
?>
" />
<button class="btn btn-success" type="submit">修改</button>
<a href="<?php
echo tsurl('group', 'topic', array('id' => $strTopic['topicid']));
?>
">返回</a>
<p></p>
</form>
</div>
<div class="col-md-2"></div>
</div>
</div>
</div>
</div>
<?php
include template('footer');
示例15: tsurl
echo $item['user']['face'];
?>
" width="16" align="absmiddle" /> <?php
echo $item['user']['username'];
?>
:<?php
echo $item['content'];
?>
<a href="<?php
echo tsurl('message', 'user', array('touserid' => $item['userid']));
?>
">[回複]</a><?php
} else {
?>
係統消息:<a href="<?php
echo tsurl('message', 'system');
?>
">[查看]</a><?php
}
?>
</li>
<?php
}
?>
</ul>
</div>
</div>
</div>
</div>
</div>
</div>