[ Index ]

PHP Cross Reference of osCMax 2.0.4

title

Body

[close]

/templates/fallback/content/ -> affiliate_banners_product.tpl.php (source)

   1  <!-- body_text //-->
   2      <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0">
   3        <tr>
   4          <td width="100%"><table border="0" width="100%" cellspacing="0" cellpadding="0">
   5            <tr>
   6              <td class="pageHeading"><?php echo HEADING_TITLE; ?></td>
   7              <td align="right"><?php echo tep_image(DIR_WS_IMAGES . 'affiliate_links.gif', HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td>
   8            </tr>
   9        <tr>
  10              <td colspan=2 class="main"><?php echo TEXT_INFORMATION; ?></td>
  11            </tr>
  12          </table>
  13      </td>
  14        </tr>
  15        <tr>
  16          <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>
  17        </tr>
  18        <tr>
  19          <td><table width="100%" align="center" border="0" cellpadding="0" cellspacing="0"><td>
  20  <?php
  21    if (tep_db_num_rows($affiliate_banners_values)) {
  22  
  23      while ($affiliate_banners = tep_db_fetch_array($affiliate_banners_values)) {
  24        $affiliate_products_query = tep_db_query("select products_name from " . TABLE_PRODUCTS_DESCRIPTION . " where products_id = '" . $affiliate_banners['affiliate_products_id'] . "' and language_id = '" . $languages_id . "'");
  25        $affiliate_products = tep_db_fetch_array($affiliate_products_query);
  26        $prod_id = $affiliate_banners['affiliate_products_id'];
  27        $ban_id = $affiliate_banners['affiliate_banners_id'];
  28        switch (AFFILIATE_KIND_OF_BANNERS) {
  29          case 1: // Link to Products
  30            if ($prod_id > 0) {
  31              $link = '<a href="' . HTTPS_SERVER . DIR_WS_CATALOG . FILENAME_PRODUCT_INFO . '?ref=' . $affiliate_id . '&products_id=' . $prod_id . '&affiliate_banner_id=' . $ban_id . '" target="_blank"><img src="' . HTTPS_SERVER . DIR_WS_CATALOG . DIR_WS_IMAGES . $affiliate_banners['affiliate_banners_image'] . '" border="0" alt="' . $affiliate_products['products_name'] . '"></a>';
  32              $link1 = '<a href="' . HTTP_SERVER . DIR_WS_CATALOG . FILENAME_PRODUCT_INFO . '?ref=' . $affiliate_id . '&products_id=' . $prod_id . '&affiliate_banner_id=' . $ban_id . '" target="_blank"><img src="' . HTTP_SERVER . DIR_WS_CATALOG . DIR_WS_IMAGES . $affiliate_banners['affiliate_banners_image'] . '" border="0" alt="' . $affiliate_products['products_name'] . '"></a>';
  33              $link2 = '<a href="' . HTTP_SERVER . DIR_WS_CATALOG . FILENAME_PRODUCT_INFO . '?ref=' . $affiliate_id . '&products_id=' . $prod_id . '&affiliate_banner_id=' . $ban_id . '" target="_blank">' . $affiliate_products['products_name'] . '</a>';
  34              }
  35            break;
  36          case 2: // Link to Products
  37            if ($prod_id > 0) {
  38              $link = '<a href="' . HTTPS_SERVER . DIR_WS_CATALOG . FILENAME_PRODUCT_INFO . '?ref=' . $affiliate_id . '&products_id=' . $prod_id . '&affiliate_banner_id=' . $ban_id . '" target="_blank"><img src="' . HTTPS_SERVER . DIR_WS_CATALOG . FILENAME_AFFILIATE_SHOW_BANNER . '?ref=' . $affiliate_id . '&affiliate_banner_id=' . $ban_id . '" border="0" alt="' . $affiliate_products['products_name'] . '"></a>';
  39              $link1 = '<a href="' . HTTP_SERVER . DIR_WS_CATALOG . FILENAME_PRODUCT_INFO . '?ref=' . $affiliate_id . '&products_id=' . $prod_id . '&affiliate_banner_id=' . $ban_id . '" target="_blank"><img src="' . HTTP_SERVER . DIR_WS_CATALOG . FILENAME_AFFILIATE_SHOW_BANNER . '?ref=' . $affiliate_id . '&affiliate_banner_id=' . $ban_id . '" border="0" alt="' . $affiliate_products['products_name'] . '"></a>';
  40              $link2 = '<a href="' . HTTP_SERVER . DIR_WS_CATALOG . FILENAME_PRODUCT_INFO . '?ref=' . $affiliate_id . '&products_id=' . $prod_id . '&affiliate_banner_id=' . $ban_id . '" target="_blank">' . $affiliate_products['products_name'] . '</a>';
  41              }
  42            break;
  43        }
  44  
  45            if ($prod_id > 0) {
  46  ?>
  47          <table width="95%" align="center" border="0" cellpadding="4" cellspacing="0" class="infoBoxContents">
  48            <tr>
  49              <td class="infoBoxHeading" align="center"><?php echo TEXT_AFFILIATE_NAME; ?>&nbsp;<?php echo $affiliate_banners['affiliate_banners_title']; ?></td>
  50            </tr>
  51            <tr> 
  52              <td class="smallText" align="center"><?php echo $link; ?></td> 
  53            </tr> 
  54            <tr> 
  55              <td class="smallText" align="center"><?php echo TEXT_AFFILIATE_INFO; ?></td> 
  56            </tr> 
  57            <tr> 
  58              <td class="smallText" align="center"> 
  59               <textarea cols="60" rows="4" class="boxText"><?php echo $link1; ?></textarea> 
  60     </td> 
  61            </tr> 
  62            <tr> 
  63              <td>&nbsp;<td> 
  64            </tr> 
  65            <tr> 
  66              <td class="smallText" align="center"><b>Text Version:</b> <?php echo $link2; ?></td> 
  67            </tr> 
  68            <tr> 
  69              <td class="smallText" align="center"><?php echo TEXT_AFFILIATE_INFO; ?></td> 
  70            </tr> 
  71            <tr> 
  72              <td class="smallText" align="center"> 
  73               <textarea cols="60" rows="3" class="boxText"><?php echo $link2; ?></textarea> 
  74     </td> 
  75            </tr>
  76            </table>
  77  <?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?>
  78  
  79  <?php }
  80  }
  81  }
  82  ?>
  83            </table>
  84       </td>
  85        </tr>
  86       </table></td>
  87  <!-- body_text_eof //-->


Generated: Fri Jan 1 13:43:16 2010 Cross-referenced by PHPXref 0.7