本文整理汇总了PHP中producthelper::getProductMinDeliveryTime方法的典型用法代码示例。如果您正苦于以下问题:PHP producthelper::getProductMinDeliveryTime方法的具体用法?PHP producthelper::getProductMinDeliveryTime怎么用?PHP producthelper::getProductMinDeliveryTime使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类producthelper
的用法示例。
在下文中一共展示了producthelper::getProductMinDeliveryTime方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: onRSProductSearch
//.........这里部分代码省略.........
$thum_image = "";
$pname = $Redconfiguration->maxchar($this->search[$i]->product_name, CATEGORY_PRODUCT_TITLE_MAX_CHARS, CATEGORY_PRODUCT_TITLE_END_SUFFIX);
if ($search_type == 'product_number') {
$product_number = str_ireplace($keyword, "<b class='search_hightlight'>" . $keyword . "</b>", $this->search[$i]->product_number);
$pro_s_desc = $this->search[$i]->product_s_desc;
$pro_desc = $this->search[$i]->product_desc;
} else {
$product_number = $this->search[$i]->product_number;
$pro_s_desc = $this->search[$i]->product_s_desc;
$pro_desc = $this->search[$i]->product_desc;
if (!in_array($keyword, $tagarray)) {
$pname = str_ireplace($keyword, "<b class='search_hightlight'>" . $keyword . "</b>", $pname);
$pro_s_desc = str_ireplace($keyword, "<b class='search_hightlight'>" . $keyword . "</b>", $pro_s_desc);
$pro_desc = str_ireplace($keyword, "<b class='search_hightlight'>" . $keyword . "</b>", $pro_desc);
}
}
$pro_s_desc = $Redconfiguration->maxchar($pro_s_desc, CATEGORY_PRODUCT_DESC_MAX_CHARS, CATEGORY_PRODUCT_DESC_END_SUFFIX);
$link = JRoute::_('index.php?option=com_redshop&view=product&pid=' . $this->search[$i]->product_id . '&Itemid=' . $Itemid);
if (strstr($template_desc, '{product_name}')) {
$pname = "<a href='" . $link . "'>" . $pname . "</a>";
$data_add = str_replace("{product_name}", $pname, $template_desc);
}
if (strstr($template_desc, '{product_name_nolink}')) {
$data_add = str_replace("{product_name_nolink}", $pname, $template_desc);
}
$readmore = "<a href='" . $link . "'>" . JText::_('COM_REDSHOP_READ_MORE') . "</a>";
$data_add = str_replace("{read_more}", $readmore, $data_add);
$data_add = str_replace("{read_more_link}", $link, $data_add);
// RedSHOP Product Plugin
JPluginHelper::importPlugin('redshop_product');
$results = $dispatcher->trigger('onPrepareProduct', array(&$data_add, &$params, $this->search[$i]));
// End
if (strstr($data_add, "{product_delivery_time}")) {
$product_delivery_time = $producthelper->getProductMinDeliveryTime($this->search[$i]->product_id);
if ($product_delivery_time != "") {
$data_add = str_replace("{delivery_time_lbl}", JText::_('DELIVERY_TIME'), $data_add);
$data_add = str_replace("{product_delivery_time}", $product_delivery_time, $data_add);
} else {
$data_add = str_replace("{delivery_time_lbl}", "", $data_add);
$data_add = str_replace("{product_delivery_time}", "", $data_add);
}
}
// Product Review/Rating
// Fetching reviews
$final_avgreview_data = $producthelper->getProductRating($this->search[$i]->product_id);
// Attribute ajax chage
$data_add = str_replace("{product_rating_summary}", $final_avgreview_data, $data_add);
$data_add = $producthelper->getJcommentEditor($this->search[$i], $data_add);
$data_add = $producthelper->getExtraSectionTag($extraFieldName, $this->search[$i]->product_id, "1", $data_add, 1);
$data_add = str_replace("{product_s_desc}", $pro_s_desc, $data_add);
$data_add = str_replace("{product_desc}", $pro_desc, $data_add);
$data_add = str_replace("{product_id_lbl}", JText::_('COM_REDSHOP_PRODUCT_ID_LBL'), $data_add);
$data_add = str_replace("{product_id}", $this->search[$i]->product_id, $data_add);
$data_add = str_replace("{product_number_lbl}", JText::_('COM_REDSHOP_PRODUCT_NUMBER_LBL'), $data_add);
$data_add = str_replace("{product_number}", $product_number, $data_add);
/**
* related Product List in Lightbox
* Tag Format = {related_product_lightbox:<related_product_name>[:width][:height]}
*/
if (strstr($data_add, '{related_product_lightbox:')) {
$related_product = $producthelper->getRelatedProduct($this->search[$i]->product_id);
$rtlnone = explode("{related_product_lightbox:", $data_add);
$rtlntwo = explode("}", $rtlnone[1]);
$rtlnthree = explode(":", $rtlntwo[0]);
$rtln = $rtlnthree[0];
$rtlnfwidth = isset($rtlnthree[1]) ? $rtlnthree[1] : "900";
示例2: count
}
$count_no_user_field = 0;
// Counting accessory
$accessorylist = $producthelper->getProductAccessory(0, $product->product_id);
$totacc = count($accessorylist);
$data_add = $template_product;
// ProductFinderDatepicker Extra Field Start
$data_add = $producthelper->getProductFinderDatepickerValue($template_product, $product->product_id, $fieldArray);
// ProductFinderDatepicker Extra Field End
/*
* Process the prepare Product plugins
*/
$params = array();
$results = $this->dispatcher->trigger('onPrepareProduct', array(&$data_add, &$params, $product));
if (strstr($data_add, "{product_delivery_time}")) {
$product_delivery_time = $producthelper->getProductMinDeliveryTime($product->product_id);
if ($product_delivery_time != "") {
$data_add = str_replace("{delivery_time_lbl}", JText::_('COM_REDSHOP_DELIVERY_TIME'), $data_add);
$data_add = str_replace("{product_delivery_time}", $product_delivery_time, $data_add);
} else {
$data_add = str_replace("{delivery_time_lbl}", "", $data_add);
$data_add = str_replace("{product_delivery_time}", "", $data_add);
}
}
// More documents
if (strstr($data_add, "{more_documents}")) {
$media_documents = $producthelper->getAdditionMediaImage($product->product_id, "product", "document");
$more_doc = '';
for ($m = 0; $m < count($media_documents); $m++) {
$alttext = $producthelper->getAltText("product", $media_documents[$m]->section_id, "", $media_documents[$m]->media_id, "document");
if (!$alttext) {
示例3:
}
if (strstr($template, "{products_in_stock}") || strstr($template, "{product_stock_amount_image}")) {
$product_stock = $stockroomhelper->getStockAmountwithReserve($compare[$i]["product_id"]);
$template = str_replace('{products_in_stock}', $exp_div . $product_stock . $div_end . $td_end . $td_start . "{products_in_stock}", $template);
$stockamountList = $stockroomhelper->getStockAmountImage($compare[$i]["product_id"], "product", $product_stock);
$stockamountImage = "";
if (count($stockamountList) > 0) {
$stockamountImage = '<a class="imgtooltip"><span>';
$stockamountImage .= '<div class="spnheader">' . JText::_('COM_REDSHOP_STOCK_AMOUNT') . '</div>';
$stockamountImage .= '<div class="spnalttext" id="stockImageTooltip' . $compare[$i]["product_id"] . '">' . $stockamountList[0]->stock_amount_image_tooltip . '</div></span>';
$stockamountImage .= '<img src="' . REDSHOP_FRONT_IMAGES_ABSPATH . 'stockroom/' . $stockamountList[0]->stock_amount_image . '" width="150px" height="90px" alt="' . $stockamountList[0]->stock_amount_image_tooltip . '" id="stockImage' . $compare[$i]["product_id"] . '" /></a>';
}
$template = str_replace('{product_stock_amount_image}', $exp_div . $stockamountImage . $div_end . $td_end . $td_start . "{product_stock_amount_image}", $template);
}
if (strstr($template, "{product_delivery_time}")) {
$product_delivery_time = $producthelper->getProductMinDeliveryTime($compare[$i]["product_id"]);
$template = str_replace('{product_delivery_time}', $exp_div . $product_delivery_time . $div_end . $td_end . $td_start . "{product_delivery_time}", $template);
}
if (strstr($template, "{product_availability_date}")) {
$available_date = "";
if ($product->product_availability_date != "") {
$available_date = $config->convertDateFormat($product->product_availability_date);
}
$template = str_replace('{product_availability_date}', $exp_div . $available_date . $div_end . $td_end . $td_start . "{product_availability_date}", $template);
}
if (strstr($template, "{product_category}")) {
$category = $producthelper->getSection('category', $compare[$i]["category_id"]);
$template = str_replace('{product_category}', $exp_div . $category->category_name . $div_end . $td_end . $td_start . "{product_category}", $template);
}
$template = str_replace('{remove}', $exp_div . $remove . $div_end . $td_end . $td_start . "{remove}", $template);
if (strstr($template, "{add_to_cart}")) {
示例4: urlencode
* Conditional tag
* if product on discount : Yes
* {if product_special} This is a special product {product_special end if} // OUTPUT : This is a special product
* NO : // OUTPUT : Display blank
*/
$template_desc = $producthelper->getSpecialProductComment($this->data, $template_desc);
$manuUrl = JRoute::_('index.php?option=com_redshop&view=manufacturers&layout=detail&mid=' . $this->data->manufacturer_id . '&Itemid=' . $this->itemId);
$manufacturerLink = "<a href='" . $manuUrl . "'>" . JText::_("COM_REDSHOP_VIEW_MANUFACTURER") . "</a>";
$manuUrl = JRoute::_('index.php?option=com_redshop&view=manufacturers&layout=products&mid=' . $this->data->manufacturer_id . '&Itemid=' . $this->itemId);
$manufacturerPLink = "<a href='" . $manuUrl . "'>" . JText::_("COM_REDSHOP_VIEW_ALL_MANUFACTURER_PRODUCTS") . " " . $this->data->manufacturer_name . "</a>";
$template_desc = str_replace("{manufacturer_link}", $manufacturerLink, $template_desc);
$template_desc = str_replace("{manufacturer_product_link}", $manufacturerPLink, $template_desc);
$template_desc = str_replace("{manufacturer_name}", $this->data->manufacturer_name, $template_desc);
$template_desc = str_replace("{supplier_name}", "", $template_desc);
if (strstr($template_desc, "{product_delivery_time}")) {
$product_delivery_time = $producthelper->getProductMinDeliveryTime($this->data->product_id);
if ($product_delivery_time != "") {
$template_desc = str_replace("{delivery_time_lbl}", JText::_('COM_REDSHOP_DELIVERY_TIME'), $template_desc);
$template_desc = str_replace("{product_delivery_time}", $product_delivery_time, $template_desc);
} else {
$template_desc = str_replace("{delivery_time_lbl}", "", $template_desc);
$template_desc = str_replace("{product_delivery_time}", "", $template_desc);
}
}
// Facebook I like Button
if (strstr($template_desc, "{facebook_like_button}")) {
$uri = JFactory::getURI();
$facebook_link = urlencode($uri->toString());
$facebook_like = '<iframe src="' . $Scheme . '://www.facebook.com/plugins/like.php?href=' . $facebook_link . '&layout=standard&show_faces=true&width=450&action=like&font&colorscheme=light&height=80" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:80px;" allowTransparency="true"></iframe>';
$template_desc = str_replace("{facebook_like_button}", $facebook_like, $template_desc);
$jconfig = JFactory::getConfig();