本文整理汇总了PHP中OSC\OM\HTML::image方法的典型用法代码示例。如果您正苦于以下问题:PHP HTML::image方法的具体用法?PHP HTML::image怎么用?PHP HTML::image使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类OSC\OM\HTML
的用法示例。
在下文中一共展示了HTML::image方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: quote
function quote($method = '')
{
global $order, $shipping_weight, $shipping_num_boxes;
if (MODULE_SHIPPING_TABLE_MODE == 'price') {
$order_total = $this->getShippableTotal();
} else {
$order_total = $shipping_weight;
}
$table_cost = preg_split("/[:,]/", MODULE_SHIPPING_TABLE_COST);
$size = sizeof($table_cost);
for ($i = 0, $n = $size; $i < $n; $i += 2) {
if ($order_total <= $table_cost[$i]) {
$shipping = $table_cost[$i + 1];
break;
}
}
if (MODULE_SHIPPING_TABLE_MODE == 'weight') {
$shipping = $shipping * $shipping_num_boxes;
}
$this->quotes = array('id' => $this->code, 'module' => OSCOM::getDef('module_shipping_table_text_title'), 'methods' => array(array('id' => $this->code, 'title' => OSCOM::getDef('module_shipping_table_text_way'), 'cost' => $shipping + MODULE_SHIPPING_TABLE_HANDLING)));
if ($this->tax_class > 0) {
$this->quotes['tax'] = tep_get_tax_rate($this->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']);
}
if (tep_not_null($this->icon)) {
$this->quotes['icon'] = HTML::image($this->icon, $this->title);
}
return $this->quotes;
}
示例2: execute
function execute()
{
global $oscTemplate;
$OSCOM_Db = Registry::get('Db');
$OSCOM_Language = Registry::get('Language');
if (isset($_GET['products_id'])) {
$Qmanufacturer = $OSCOM_Db->prepare('select m.manufacturers_id, m.manufacturers_name, m.manufacturers_image, mi.manufacturers_url from :table_manufacturers m left join :table_manufacturers_info mi on (m.manufacturers_id = mi.manufacturers_id and mi.languages_id = :languages_id), :table_products p where p.products_id = :products_id and p.manufacturers_id = m.manufacturers_id');
$Qmanufacturer->bindInt(':languages_id', $OSCOM_Language->getId());
$Qmanufacturer->bindInt(':products_id', $_GET['products_id']);
$Qmanufacturer->execute();
if ($Qmanufacturer->fetch() !== false) {
$manufacturer_info_string = null;
if (!empty($Qmanufacturer->value('manufacturers_image'))) {
$manufacturer_info_string .= '<div>' . HTML::image(OSCOM::linkImage($Qmanufacturer->value('manufacturers_image')), $Qmanufacturer->value('manufacturers_name')) . '</div>';
}
if (!empty($Qmanufacturer->value('manufacturers_url'))) {
$manufacturer_info_string .= '<div class="text-center"><a href="' . OSCOM::link('redirect.php', 'action=manufacturer&manufacturers_id=' . $Qmanufacturer->valueInt('manufacturers_id')) . '" target="_blank">' . OSCOM::getDef('module_boxes_manufacturer_info_box_homepage', ['manufacturers_name' => $Qmanufacturer->value('manufacturers_name')]) . '</a></div>';
}
ob_start();
include 'includes/modules/boxes/templates/manufacturer_info.php';
$data = ob_get_clean();
$oscTemplate->addBlock($data, $this->group);
}
}
}
示例3: getImage
public function getImage($language_code, $width = null, $height = null)
{
if (!isset($width) || !is_int($width)) {
$width = 16;
}
if (!isset($height) || !is_int($height)) {
$height = 12;
}
return HTML::image(OSCOM::link('Shop/public/third_party/flag-icon-css/flags/4x3/' . $this->get('image', $language_code) . '.svg', null, false), $this->get('name', $language_code), $width, $height);
}
示例4: quote
function quote($method = '')
{
global $order;
$this->quotes = array('id' => $this->code, 'module' => OSCOM::getDef('module_shipping_flat_text_title'), 'methods' => array(array('id' => $this->code, 'title' => OSCOM::getDef('module_shipping_flat_text_way'), 'cost' => MODULE_SHIPPING_FLAT_COST)));
if ($this->tax_class > 0) {
$this->quotes['tax'] = tep_get_tax_rate($this->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']);
}
if (tep_not_null($this->icon)) {
$this->quotes['icon'] = HTML::image($this->icon, $this->title);
}
return $this->quotes;
}
示例5: quote
function quote($method = '')
{
global $order;
$number_of_items = $this->getNumberOfItems();
$this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_ITEM_TEXT_TITLE, 'methods' => array(array('id' => $this->code, 'title' => MODULE_SHIPPING_ITEM_TEXT_WAY, 'cost' => MODULE_SHIPPING_ITEM_COST * $number_of_items + MODULE_SHIPPING_ITEM_HANDLING)));
if ($this->tax_class > 0) {
$this->quotes['tax'] = tep_get_tax_rate($this->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']);
}
if (tep_not_null($this->icon)) {
$this->quotes['icon'] = HTML::image($this->icon, $this->title);
}
return $this->quotes;
}
示例6: execute
function execute()
{
global $PHP_SELF, $oscTemplate;
if (substr(basename($PHP_SELF), 0, 8) != 'checkout' && tep_not_null(MODULE_BOXES_CARD_ACCEPTANCE_LOGOS)) {
$output = NULL;
foreach (explode(';', MODULE_BOXES_CARD_ACCEPTANCE_LOGOS) as $logo) {
$output .= HTML::image(OSCOM::linkImage('Shop/card_acceptance/' . basename($logo)), null, null, null, null, false);
}
ob_start();
include 'includes/modules/boxes/templates/card_acceptance.php';
$data = ob_get_clean();
$oscTemplate->addBlock($data, $this->group);
}
}
示例7: execute
function execute()
{
global $PHP_SELF, $lng, $request_type, $oscTemplate;
if (substr(basename($PHP_SELF), 0, 8) != 'checkout') {
if (!isset($lng) || isset($lng) && !is_object($lng)) {
$lng = new language();
}
if (count($lng->catalog_languages) > 1) {
$languages_string = '';
foreach ($lng->catalog_languages as $key => $value) {
$languages_string .= ' <a href="' . OSCOM::link($PHP_SELF, tep_get_all_get_params(array('language', 'currency')) . 'language=' . $key, $request_type) . '">' . HTML::image(DIR_WS_LANGUAGES . $value['directory'] . '/images/' . $value['image'], $value['name'], NULL, NULL, NULL, false) . '</a> ';
}
ob_start();
include 'includes/modules/boxes/templates/languages.php';
$data = ob_get_clean();
$oscTemplate->addBlock($data, $this->group);
}
}
}
示例8: execute
function execute()
{
global $currencies, $oscTemplate;
$OSCOM_Db = Registry::get('Db');
$OSCOM_Language = Registry::get('Language');
$reviews_box_contents = '';
$sql_query = 'select r.reviews_id from :table_reviews r, :table_reviews_description rd, :table_products p, :table_products_description pd where r.reviews_status = 1 and r.products_id = p.products_id and p.products_status = 1 and r.reviews_id = rd.reviews_id and rd.languages_id = :languages_id and p.products_id = pd.products_id and pd.language_id = rd.languages_id';
if (isset($_GET['products_id'])) {
$sql_query .= ' and p.products_id = :products_id';
}
$sql_query .= ' order by r.reviews_id desc limit ' . (int) MAX_RANDOM_SELECT_REVIEWS;
$Qcheck = $OSCOM_Db->prepare($sql_query);
$Qcheck->bindInt(':languages_id', $OSCOM_Language->getId());
if (isset($_GET['products_id'])) {
$Qcheck->bindInt(':products_id', $_GET['products_id']);
}
$Qcheck->execute();
$result = $Qcheck->fetchAll();
if (count($result) > 0) {
$result = $result[mt_rand(0, count($result) - 1)];
$Qreview = $OSCOM_Db->prepare('select r.reviews_id, r.reviews_rating, substring(rd.reviews_text, 1, 60) as reviews_text, p.products_id, p.products_image, pd.products_name from :table_reviews r, :table_reviews_description rd, :table_products p, :table_products_description pd where r.reviews_id = :reviews_id and r.reviews_id = rd.reviews_id and rd.languages_id = :languages_id and r.products_id = p.products_id and p.products_id = pd.products_id and pd.language_id = rd.languages_id');
$Qreview->bindInt(':reviews_id', $result['reviews_id']);
$Qreview->bindInt(':languages_id', $OSCOM_Language->getId());
$Qreview->execute();
if ($Qreview->fetch() !== false) {
// display random review box
$rand_review_text = tep_break_string($Qreview->valueProtected('reviews_text'), 15, '-<br />');
$reviews_box_contents = '<div class="text-center"><a href="' . OSCOM::link('product_reviews.php', 'products_id=' . $Qreview->valueInt('products_id')) . '">' . HTML::image(OSCOM::linkImage($Qreview->value('products_image')), $Qreview->value('products_name'), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a></div><div><a href="' . OSCOM::link('product_reviews.php', 'products_id=' . $Qreview->valueInt('products_id')) . '">' . $rand_review_text . '</a>...</div><div class="text-center" title="' . OSCOM::getDef('module_boxes_reviews_box_text_of_5_stars', ['reviews_rating' => $Qreview->valueInt('reviews_rating')]) . '">' . HTML::stars($Qreview->valueInt('reviews_rating')) . '</div>';
}
} elseif (isset($_GET['products_id'])) {
// display 'write a review' box
$reviews_box_contents = '<span class="fa fa-thumbs-up"></span> <a href="' . OSCOM::link('product_reviews_write.php', 'products_id=' . (int) $_GET['products_id']) . '">' . OSCOM::getDef('module_boxes_reviews_box_write_review') . '</a>';
} else {
// display 'no reviews' box
$reviews_box_contents = '<p>' . OSCOM::getDef('module_boxes_reviews_box_no_reviews') . '</p>';
}
ob_start();
include 'includes/modules/boxes/templates/reviews.php';
$data = ob_get_clean();
$oscTemplate->addBlock($data, $this->group);
}
示例9: getOutput
function getOutput()
{
$current_version = OSCOM::getVersion();
$new_version = false;
$VersionCache = new Cache('core_version_check');
if ($VersionCache->exists()) {
$date_last_checked = DateTime::toShort(date('Y-m-d H:i:s', $VersionCache->getTime()), true);
$releases = $VersionCache->get();
foreach ($releases as $version) {
$version_array = explode('|', $version);
if (version_compare($current_version, $version_array[0], '<')) {
$new_version = true;
break;
}
}
} else {
$date_last_checked = OSCOM::getDef('module_admin_dashboard_version_check_never');
}
$output = '<table class="table table-hover">
<thead>
<tr class="info">
<th>' . OSCOM::getDef('module_admin_dashboard_version_check_title') . '</th>
<th class="text-right">' . OSCOM::getDef('module_admin_dashboard_version_check_date') . '</th>
</tr>
</thead>
<tbody>';
if ($new_version == true) {
$output .= ' <tr class="success">
<td colspan="2">' . HTML::image(OSCOM::linkImage('icons/warning.gif'), OSCOM::getDef('icon_warning')) . ' <strong>' . OSCOM::getDef('module_admin_dashboard_version_check_update_available') . '</strong></td>
</tr>';
}
$output .= ' <tr>
<td><a href="' . OSCOM::link('online_update.php') . '">' . OSCOM::getDef('module_admin_dashboard_version_check_check_now') . '</a></td>
<td class="text-right">' . $date_last_checked . '</td>
</tr>
</tbody>
</table>';
return $output;
}
示例10: tep_display_banner
function tep_display_banner($action, $identifier)
{
$OSCOM_Db = Registry::get('Db');
$banner = null;
if ($action == 'dynamic') {
$Qcheck = $OSCOM_Db->prepare('select banners_id from :table_banners where banners_group = :banners_group and status = 1 limit 1');
$Qcheck->bindValue(':banners_group', $identifier);
$Qcheck->execute();
if ($Qcheck->fetch() !== false) {
$Qbanner = $OSCOM_Db->prepare('select banners_id, banners_title, banners_image, banners_html_text from :table_banners where banners_group = :banners_group and status = 1 order by rand() limit 1');
$Qbanner->bindValue(':banners_group', $identifier);
$Qbanner->execute();
$banner = $Qbanner->fetch();
}
} elseif ($action == 'static') {
if (is_array($identifier)) {
$banner = $identifier;
} else {
$Qbanner = $OSCOM_Db->prepare('select banners_id, banners_title, banners_image, banners_html_text from :table_banners where banners_id = :banners_id and status = 1');
$Qbanner->bindInt(':banners_id', $identifier);
$Qbanner->execute();
if ($Qbanner->fetch() !== false) {
$banner = $Qbanner->toArray();
}
}
}
$output = '';
if (isset($banner)) {
if (!empty($banner['banners_html_text'])) {
$output = $banner['banners_html_text'];
} else {
$output = '<a href="' . OSCOM::link('redirect.php', 'action=banner&goto=' . $banner['banners_id']) . '" target="_blank">' . HTML::image(DIR_WS_IMAGES . $banner['banners_image'], $banner['banners_title']) . '</a>';
}
tep_update_banner_display_count($banner['banners_id']);
}
return $output;
}
示例11: execute
function execute()
{
global $oscTemplate;
$OSCOM_Db = Registry::get('Db');
if (isset($_GET['products_id'])) {
$Qmanufacturer = $OSCOM_Db->prepare('select m.manufacturers_id, m.manufacturers_name, m.manufacturers_image, mi.manufacturers_url from :table_manufacturers m left join :table_manufacturers_info mi on (m.manufacturers_id = mi.manufacturers_id and mi.languages_id = :languages_id), :table_products p where p.products_id = :products_id and p.manufacturers_id = m.manufacturers_id');
$Qmanufacturer->bindInt(':languages_id', $_SESSION['languages_id']);
$Qmanufacturer->bindInt(':products_id', $_GET['products_id']);
$Qmanufacturer->execute();
if ($Qmanufacturer->fetch() !== false) {
$manufacturer_info_string = null;
if (!empty($Qmanufacturer->value('manufacturers_image'))) {
$manufacturer_info_string .= '<div class="center-block">' . HTML::image(DIR_WS_IMAGES . $Qmanufacturer->value('manufacturers_image'), $Qmanufacturer->value('manufacturers_name')) . '</div>';
}
if (!empty($Qmanufacturer->value('manufacturers_url'))) {
$manufacturer_info_string .= '<div class="text-center"><a href="' . OSCOM::link('redirect.php', 'action=manufacturer&manufacturers_id=' . $Qmanufacturer->valueInt('manufacturers_id')) . '" target="_blank">' . sprintf(MODULE_BOXES_MANUFACTURER_INFO_BOX_HOMEPAGE, $Qmanufacturer->value('manufacturers_name')) . '</a></div>';
}
ob_start();
include 'includes/modules/boxes/templates/manufacturer_info.php';
$data = ob_get_clean();
$oscTemplate->addBlock($data, $this->group);
}
}
}
示例12:
}
?>
<?php
echo HTML::form('product_reviews_write', OSCOM::link('product_reviews_write.php', 'action=process&products_id=' . $Qcheck->valueInt('products_id')), 'post', 'class="form-horizontal" role="form"', ['tokenize' => true]);
?>
<div class="contentContainer">
<?php
if (!empty($Qcheck->value('products_image'))) {
?>
<div class="col-sm-4 text-center pull-right">
<?php
echo '<a href="' . OSCOM::link('product_info.php', 'products_id=' . $Qcheck->valueInt('products_id')) . '">' . HTML::image(DIR_WS_IMAGES . $Qcheck->value('products_image'), $Qcheck->value('products_name'), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"') . '</a>';
?>
<p><?php
echo HTML::button(IMAGE_BUTTON_IN_CART, 'glyphicon glyphicon-shopping-cart', OSCOM::link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=buy_now'), null, null, 'btn-success btn-block');
?>
</p>
</div>
<div class="clearfix"></div>
<hr>
<div class="clearfix"></div>
<?php
示例13: quote
function quote($method = '')
{
global $order, $shipping_weight, $shipping_num_boxes;
$dest_country = $order->delivery['country']['iso_code_2'];
$dest_zone = 0;
$error = false;
for ($i = 1; $i <= $this->num_zones; $i++) {
$countries_table = constant('MODULE_SHIPPING_ZONES_COUNTRIES_' . $i);
$country_zones = preg_split("/[,]/", $countries_table);
if (in_array($dest_country, $country_zones)) {
$dest_zone = $i;
break;
}
}
if ($dest_zone == 0) {
$error = true;
} else {
$shipping = -1;
$zones_cost = constant('MODULE_SHIPPING_ZONES_COST_' . $dest_zone);
$zones_table = preg_split("/[:,]/", $zones_cost);
$size = sizeof($zones_table);
for ($i = 0; $i < $size; $i += 2) {
if ($shipping_weight <= $zones_table[$i]) {
$shipping = $zones_table[$i + 1];
$shipping_method = MODULE_SHIPPING_ZONES_TEXT_WAY . ' ' . $dest_country . ' : ' . $shipping_weight . ' ' . MODULE_SHIPPING_ZONES_TEXT_UNITS;
break;
}
}
if ($shipping == -1) {
$shipping_cost = 0;
$shipping_method = MODULE_SHIPPING_ZONES_UNDEFINED_RATE;
} else {
$shipping_cost = $shipping * $shipping_num_boxes + constant('MODULE_SHIPPING_ZONES_HANDLING_' . $dest_zone);
}
}
$this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_ZONES_TEXT_TITLE, 'methods' => array(array('id' => $this->code, 'title' => $shipping_method, 'cost' => $shipping_cost)));
if ($this->tax_class > 0) {
$this->quotes['tax'] = tep_get_tax_rate($this->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']);
}
if (tep_not_null($this->icon)) {
$this->quotes['icon'] = HTML::image($this->icon, $this->title);
}
if ($error == true) {
$this->quotes['error'] = MODULE_SHIPPING_ZONES_INVALID_ZONE;
}
return $this->quotes;
}
示例14: date
echo date('H:i:s', $Qonline->value('time_last_click'));
?>
</td>
<td class="dataTableContent"><?php
if (preg_match('/^(.*)osCsid=[A-Z0-9,-]+[&]*(.*)/i', $Qonline->value('last_page_url'), $array)) {
echo $array[1] . $array[2];
} else {
echo $Qonline->value('last_page_url');
}
?>
</td>
<td class="dataTableContent" align="right"><?php
if (isset($info) && is_object($info) && $Qonline->value('session_id') == $info->session_id) {
echo HTML::image(OSCOM::linkImage('icon_arrow_right.gif'), '');
} else {
echo '<a href="' . OSCOM::link(FILENAME_WHOS_ONLINE, 'page=' . $_GET['page'] . '&info=' . $Qonline->value('session_id')) . '">' . HTML::image(OSCOM::linkImage('icon_info.gif'), OSCOM::getDef('image_icon_info')) . '</a>';
}
?>
</td>
</tr>
<?php
}
?>
<tr>
<td colspan="9"><table border="0" width="100%" cellspacing="0" cellpadding="2">
<tr>
<td class="smallText" valign="top"><?php
echo $Qonline->getPageSetLabel(OSCOM::getDef('text_display_number_of_customers'));
?>
</td>
<td class="smallText" align="right"><?php
示例15: implode
echo HTML::image(OSCOM::linkImage($image['image']), '', '', '', 'id="piGalImg_' . $pi_counter . '"') . "\n";
}
?>
</div>
<?php
if (!empty($pi_html)) {
echo ' <div style="display: none;">' . implode('', $pi_html) . '</div>';
}
} else {
?>
<div class="piGal pull-right">
<?php
echo HTML::image(OSCOM::linkImage($Qproduct->value('products_image')), $Qproduct->value('products_name'));
?>
</div>
<?php
}
}
?>
<div itemprop="description">
<?php
echo $Qproduct->value('products_description');
?>
</div>
<?php