本文整理汇总了PHP中vmCommonHTML::ParseContentByPlugins方法的典型用法代码示例。如果您正苦于以下问题:PHP vmCommonHTML::ParseContentByPlugins方法的具体用法?PHP vmCommonHTML::ParseContentByPlugins怎么用?PHP vmCommonHTML::ParseContentByPlugins使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类vmCommonHTML
的用法示例。
在下文中一共展示了vmCommonHTML::ParseContentByPlugins方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: shopMakeHtmlSafe
if ($db->num_rows() > 0) {
$tpl->set('ps_product', $ps_product);
$tpl->set('products', $db);
$related_products = $tpl->fetch('/common/relatedProducts.tpl.php');
}
// GET THE PRODUCT NAME
$product_name = shopMakeHtmlSafe($db_product->f("product_name"));
if ($db_product->f("product_publish") == "N") {
$product_name .= " (" . $VM_LANG->_('CMN_UNPUBLISHED') . ")";
}
$product_description = $db_product->f("product_desc");
if (str_replace("<br />", "", $product_description) == '' && $product_parent_id != 0) {
$product_description = $dbp->f("product_desc");
// Use product_desc from Parent Product
}
$product_description = vmCommonHTML::ParseContentByPlugins($product_description);
// Get the CATEGORY NAVIGATION
$navigation_pathway = "";
$navigation_childlist = "";
$pathway_appended = false;
$flypage = vmGet($_REQUEST, "flypage");
// Each Product is assigned to one or more Categories, if category_id was omitted, we must fetch it here
if (empty($category_id) || empty($flypage)) {
$q = "SELECT cx.category_id, category_flypage FROM #__{vm}_category c, #__{vm}_product_category_xref cx WHERE product_id = '{$product_id}' AND c.category_id=cx.category_id LIMIT 0,1";
$db->query($q);
$db->next_record();
if (!$db->f("category_id")) {
// The Product Has no category entry and must be a Child Product
// So let's get the Parent Product
$q = "SELECT product_id FROM #__{vm}_product WHERE product_id = '" . $db_product->f("product_parent_id") . "' LIMIT 0,1";
$db->query($q);
示例2: str_replace
$db_browse->query($count);
$num_rows = $db_browse->f("num_rows");
if ($limitstart > 0 && $limit >= $num_rows) {
$list = str_replace('LIMIT ' . $limitstart, 'LIMIT 0', $list);
}
if ($category_id) {
/**
* CATEGORY DESCRIPTION
*/
$db->query("SELECT category_id, category_name FROM #__{vm}_category WHERE category_id='{$category_id}'");
$db->next_record();
$category_name = shopMakeHtmlSafe($db->f('category_name'));
/* Set Dynamic Page Title */
$mainframe->setPageTitle($db->f("category_name"));
$desc = $ps_product_category->get_description($category_id);
$desc = vmCommonHTML::ParseContentByPlugins($desc);
/* Prepend Product Short Description Meta Tag "description" when applicable */
$mainframe->prependMetaTag("description", substr(strip_tags($desc), 0, 255));
}
// when nothing has been found we tell this here and say goodbye
if ($num_rows == 0 && (!empty($keyword) || !empty($keyword1))) {
echo $VM_LANG->_('PHPSHOP_NO_SEARCH_RESULT');
} elseif ($num_rows == 0 && empty($product_type_id) && !empty($child_list)) {
echo $VM_LANG->_('EMPTY_CATEGORY');
} elseif ($num_rows == 1 && (!empty($keyword) || !empty($keyword1))) {
// If just one product has been found, we directly show the details page of it
$db_browse->query($list);
$db_browse->next_record();
$flypage = $db_browse->sf("category_flypage") ? $db_browse->sf("category_flypage") : FLYPAGE;
$url_parameters = "page=shop.product_details&flypage={$flypage}&product_id=" . $db_browse->f("product_id") . "&category_id=" . $db_browse->f("category_id");
vmRedirect($sess->url($url_parameters, true, false));
示例3: die
<?php
if (!defined('_VALID_MOS') && !defined('_JEXEC')) {
die('Direct Access to ' . basename(__FILE__) . ' is not allowed.');
}
?>
<?php
defined('vmToolTipCalled') or define('vmToolTipCalled', 1);
echo $vendor_store_desc = vmCommonHTML::ParseContentByPlugins($vendor_store_desc) . "<br />";
echo "<br /><h4>" . $VM_LANG->_('PHPSHOP_CATEGORIES') . "</h4>";
echo $categories;
?>
<div class="vmRecent">
<?php
echo $recent_products;
?>
</div>
<?php
// Show Featured Products
if ($this->get_cfg('showFeatured', 1)) {
/* featuredproducts(random, no_of_products,category_based) no_of_products 0 = all else numeric amount
edit featuredproduct.tpl.php to edit layout */
echo $ps_product->featuredProducts(true, 10, false);
}
// Show Latest Products
if ($this->get_cfg('showlatest', 1)) {
/* latestproducts(random, no_of_products,month_based,category_based) no_of_products 0 = all else numeric amount
edit latestproduct.tpl.php to edit layout */
ps_product::latestProducts(true, 10, false, false);
}