本文整理汇总了PHP中getTags函数的典型用法代码示例。如果您正苦于以下问题:PHP getTags函数的具体用法?PHP getTags怎么用?PHP getTags使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了getTags函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getMediaItem
function getMediaItem($item)
{
$content = '<li class="list-group-item">';
$content .= getRating($item['rating']);
$content .= $item['title'] . '<br>';
$content .= '<small>' . $item['description'] . '</small><br>';
$content .= getTags($item['tags']);
// Buttonrow
$content .= '<div class="text-right">';
// Edit Button
$content .= '<a href="index.php?media_item_id=' . $item['id'] . '">';
$content .= '<button type="button" class="btn btn-xs" aria-label="Editieren">';
$content .= '<span class="glyphicon glyphicon-pencil" aria-hidden="true"></span>';
$content .= '</button>';
$content .= '</a>';
// Delete Button
$content .= '<a href="submit.php?delete_id=' . $item['id'] . '">';
$content .= '<button type="button" class="btn btn-xs" aria-label="Editieren">';
$content .= '<span class="glyphicon glyphicon-trash" aria-hidden="true"></span>';
$content .= '</button>';
$content .= '</a>';
$content .= '</div>';
// END buttonrow
$content .= '</li>';
return $content;
}
示例2: formTagCloud
function formTagCloud()
{
$allTags = getTags();
while ($row = mysql_fetch_assoc($allTags)) {
echo '<span class="tag' . rand(1, 4) . '">
<a href="' . HTTP_SERVER . 'tag/' . $row['tag_name'] . '" title="' . $row['tag_name'] . '">' . $row['tag_name'] . '</a>' . '</span>';
}
}
示例3: formTagCloud
function formTagCloud()
{
$allTags = getTags();
foreach ($allTags as $row) {
echo '<span class="tag' . rand(1, 4) . '">
<a href="' . HTTP_SERVER . 'tag/' . $row['tag_name'] . '/" title="' . $row['tag_name'] . '" rel="tag">' . $row['tag_name'] . '</a>' . '</span>';
}
}
示例4: createMapping
function createMapping($field)
{
$arr['title'] = $field['vendor'] . ' ' . $field['name'];
$arr['body_html'] = $field['description'];
$arr['vendor'] = $field['vendor'];
$arr['product_type'] = $field['type'];
$arr['tags'] = getTags($field['tags']);
$arr['images'] = array(getImageUrl(IMAGE_BASE_URL, $field['image']));
$arr['metafields_global_title_tag'] = 'Paramount BP ' . $arr['title'];
$arr['metafields_global_description_tag'] = $field['meta_description'];
$arr['variants'] = array(getbasicVariants($field));
return $arr;
}
示例5: textNameOut
function textNameOut($name, $id, $type)
{
global $db;
// setting header
header("Content-Type: text/html; charset=UTF-8");
$output = "<meta http-equiv=\"content-type\" content=\"text/html; charset=UTF-8\">\n";
if ($name != "") {
return $output . "<strong class=\"clusterName\">" . $name . "</strong><br />\n";
} else {
$tags = getTags($db, $id, $type);
foreach ($tags as $key => $value) {
$tag = $key . "=" . $value;
if (dgettext("tags", $tag) != "") {
$name[0] = dgettext("tags", $tag);
}
if ($name[0] != $tag) {
break;
}
}
return $output . "<strong class=\"clusterName\">" . $name[0] . "</strong><br />\n";
}
}
示例6: printEntry
function printEntry($rowFromDb)
{
$url = $rowFromDb["url"];
$domain = parse_url($url)["host"];
$title = htmlspecialchars($rowFromDb["title"]);
$timestamp = $rowFromDb["timestamp"];
$Date = new DateTime($timestamp);
$Date->setTimezone(new DateTimeZone('Europe/Stockholm'));
$timestamp = $Date->format('d/m/Y H:i');
$linkID = $rowFromDb["linkID"];
$userID = $_SESSION['UserID'];
echo "<div class='entry'>";
echo "<div class='edit-links'>";
echo "<span class='glyphicon glyphicon-edit' data-toggle='tooltip' title='edit' id={$linkID}></span>";
echo "<span class='glyphicon glyphicon-remove' data-toggle='tooltip' title='delete' id={$linkID}></span>";
echo "</div>";
echo "<div class='title-bar'>";
echo "<div class='title'>";
echo "<a href='{$url}'>{$title}</a>";
echo "</div>";
echo "</div>";
echo "<div class='middle-row'>";
echo "<p>{$domain}</p>";
echo "</div>";
$tags = getTags($linkID, $userID);
echo "<div class='tagrow'>";
if (count($tags) > 0) {
echo "<div class='tags'>";
foreach ($tags as $row) {
$tag = $row["tag"];
echo "<span class='tag'>{$tag}</span>";
}
echo "</div>";
}
echo "<span class='timestamp text-muted'>{$timestamp}</span>";
echo "</div>";
echo "</div>";
}
示例7: doAction
function doAction($action)
{
$forwardpage = "";
$forward = true;
$loggedin = isUserLoggedIn();
if (!$loggedin && strcmp($action, "login") != 0 && strcmp($action, "register") != 0 && strcmp($action, "getTags") != 0) {
addError("fatal", "user.unathorized");
outputJSON("error");
} else {
if (strcmp($action, "login") == 0) {
login();
} else {
if (strcmp($action, "logout") == 0) {
logout();
} else {
if (strcmp($action, "isLoggedIn") == 0) {
isLoggedIn();
} else {
if (strcmp($action, "register") == 0) {
register();
} else {
if (strcmp($action, "addquestion") == 0) {
addQuestion();
} else {
if (strcmp($action, "getTags") == 0) {
getTags();
} else {
if (strcmp($action, "getquestions") == 0) {
getQuestions();
}
}
}
}
}
}
}
}
}
示例8: admin_list
function admin_list()
{
$this->_check_cms();
if (!empty($_GET['fid'])) {
$gets['fid'] = (int) $_GET['fid'];
}
if (!empty($_GET['cid'])) {
$gets['cid'] = (int) $_GET['cid'];
}
$gets['page'] = empty($_GET['page']) ? 1 : $_GET['page'];
$gets['pagesize'] = 10;
$pager = null;
$model = createModel($this->app);
$list = $model->gets($gets, $pager);
$cates = getCategorys($this->app);
$tags = getTags($this->app);
$this->swoole->tpl->assign('cates', $cates);
$this->swoole->tpl->assign('tags', $tags);
$pager = array('total' => $pager->total, 'render' => $pager->render());
$this->swoole->tpl->assign('pager', $pager);
$this->swoole->tpl->assign('list', $list);
$this->swoole->tpl->display('admin_' . strtolower($this->app) . '_list.html');
}
示例9: getTags
?>
<item>
<?php
// Shared Output:
?>
<link><?php
echo $post->attributes()->url;
?>
</link>
<pubDate><?php
echo $post->attributes()->date;
?>
+0000</pubDate>
<dc:creator><![CDATA[post_author]]></dc:creator>
<?php
getTags($post);
?>
<guid isPermaLink="false"><?php
echo $post->attributes()->url;
?>
</guid>
<wp:post_id><?php
echo $post->attributes()->id;
?>
</wp:post_id>
<wp:post_date><?php
echo date('Y-m-d G:i:s', (double) $post->attributes()->{'unix-timestamp'});
?>
</wp:post_date>
<wp:post_date_gmt><?php
echo str_replace(" GMT", "", $post->attributes()->{'date-gmt'});
示例10: getTags
<input name="chkPostCats[]" type="checkbox" value="<?php
echo $row['cat_id'];
?>
" /><?php
echo $row['cat_name'];
?>
</div>
<?php
}
?>
</div>
<div class="clear"></div>
<label>All tags on site<span class="small">Select to add</span> </label>
<div class="selectchk">
<?php
$all_tags = getTags();
while ($rowTags = mysql_fetch_assoc($all_tags)) {
?>
<div class="chk">
<input name="chkPostTags[]" type="checkbox" value="<?php
echo $rowTags['tag_id'];
?>
" /><?php
echo $rowTags['tag_name'];
?>
</div>
<?php
}
?>
</div>
<input class="btn" type="submit" name="btnPostAdd" value="Add" />
示例11: ikutkan
?>
<style>
<?php
ikutkan("css/bootstrap-tokenfield.min.css");
ikutkan("css/tokenfield-typeahead.min.css");
?>
</style>
<label>Label / Tag / Tanda:</label><br>
<input class="form-control input-sm" id="label" type="text" style="width:100%" name="label" value="<?php
echo $row['label_warga'];
?>
">
<script src="?file&apa=js/bootstrap-tokenfield.min.js"></script>
<?php
$tags = getTags();
$warna = array('warning', 'primary', 'success', 'info', 'danger');
$tgs = "";
for ($n = 0; $n < count($tags); $n++) {
if (!empty($tags[$n])) {
$tgs .= "'" . trim($tags[$n]) . "',";
?>
<a class="btn btn-<?php
echo $warna[rand(0, 4)];
?>
btn-xs" href="javascript:addTag('<?php
echo $tags[$n];
?>
')"><?php
echo $tags[$n];
?>
示例12: getStatusTags
/**
* Convenience function to get just the status tags from a page revision.
*
* @param string $page_id The page ID
* @param string $revision_id The revision ID, or "" if current revision
*
* @return array An array containing the status tags found (the array may be empty
* but will not be null)
*/
function getStatusTags($page_id, $revision_id)
{
return getStatusFromTags(getTags($page_id, $revision_id));
}
示例13: getTags
Tag
</div>
<div class="filterRight">
Not
<?php
if (isset($_SESSION['filter']['Not_tag']) and $_SESSION['filter']['Not_tag'] == 1) {
print "<input type=\"checkbox\" name=\"Not_tag\" value=\"1\" class=\"text ui-widget-content ui-corner-all\" checked>";
} else {
print "<input type=\"checkbox\" name=\"Not_tag\" value=\"1\" class=\"text ui-widget-content ui-corner-all\">";
}
?>
<select name="tag" size="1" style="width: 165px" class="text ui-widget-content ui-corner-all ">
<option value="all">All Tags </option>
<?php
$tagsList = getTags();
foreach ($tagsList as $tag) {
if (isset($_SESSION['filter']['tag']) and $_SESSION['filter']['tag'] == $tag['tag_id']) {
print "<option selected value=\"" . $tag['tag_id'] . "\">" . $tag['tag_name'] . " </option>";
} else {
print "<option value=\"" . $tag['tag_id'] . "\">" . $tag['tag_name'] . " </option>";
}
}
?>
</select>
</div>
</label>
<div class="filterClear"></div>
</div>
<div class="filterRow">
示例14: printImageDate
</h2>
<div class="sidebar-section"><?php
printImageDate('', '', null, true);
?>
</div>
<?php
if (getImageDesc() || zp_loggedin()) {
?>
<div class="sidebar-section"><?php
printImageDesc(true);
?>
</div><?php
}
?>
<?php
if (getTags() || zp_loggedin()) {
?>
<div class="sidebar-section"><?php
printTags('links', gettext('<strong>Tags:</strong>') . ' ', 'taglist', '');
?>
</div><?php
}
?>
<?php
if (!$zpmin_disablemeta) {
?>
<?php
if (getImageMetaData() || zp_loggedin()) {
?>
<div class="sidebar-section"><?php
printImageMetadata('', false, null, 'full-image-meta', true);
示例15: getMetaKeywords
/**
* Helper function to list tags/categories as keywords separated by comma.
*
* @param array $array the array of the tags or categories to list
*/
private static function getMetaKeywords()
{
global $_zp_gallery, $_zp_current_album, $_zp_current_image, $_zp_current_zenpage_news, $_zp_current_zenpage_page, $_zp_current_category, $_zp_gallery_page, $_zp_zenpage;
$words = '';
if (is_object($_zp_current_album) or is_object($_zp_current_image)) {
$tags = getTags();
$words .= htmlmetatags::getMetaAlbumAndImageTags($tags, "gallery");
} else {
if ($_zp_gallery_page === "index.php") {
$tags = array_keys(getAllTagsCount(true));
// get all if no specific item is set
$words .= htmlmetatags::getMetaAlbumAndImageTags($tags, "gallery");
}
}
if (extensionEnabled('zenpage')) {
if (is_NewsArticle()) {
$tags = getNewsCategories(getNewsID());
$words .= htmlmetatags::getMetaAlbumAndImageTags($tags, "zenpage");
$tags = getTags();
$words = $words . "," . htmlmetatags::getMetaAlbumAndImageTags($tags, "gallery");
} else {
if (is_Pages()) {
$tags = getTags();
$words = htmlmetatags::getMetaAlbumAndImageTags($tags, "gallery");
} else {
if (is_News()) {
$tags = $_zp_zenpage->getAllCategories();
$words .= htmlmetatags::getMetaAlbumAndImageTags($tags, "zenpage");
} else {
if (is_NewsCategory()) {
$words .= $_zp_current_category->getTitle();
}
}
}
}
}
return $words;
}