Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Product listing


FWR Media

Recommended Posts

Hello Hope get some help: Since I upgraded to osc 2.3.4 my add. pictures in the product list are to big, means I don't know where to change them. In the product_info.php is the error but I don't know where to change.


Have a look here then you understand better (my english si not so well) http://apromo.com.br.../75/language/en


 


I have installed the Kissit image Thumbnailer 


 


Thank you


Edited by cramli
Link to comment
Share on other sites

 

Hello Hope get some help: Since I upgraded to osc 2.3.4 my add. pictures in the product list are to big, means I don't know where to change them. In the product_info.php is the error but I don't know where to change.

Have a look here then you understand better (my english si not so well) http://apromo.com.br.../75/language/en

 

I have installed the Kissit image Thumbnailer 

 

Thank you

 

Found that you fixed it already, supose the colorbox or photoset grid didnt load correct?

Link to comment
Share on other sites

Hello Rainer

I just cancelled the files I have installed. I will give a try again to see and maybe then you will see what is wrong. OK?

 

When I made the upgrade to 2.3.4 after the first steps ( File Changes jQuery UI (2+ files) and jQuery (2+ files) )

allways the small picture (under the Product image) are same size like the Product image. 

But I will do the installation again and then let's see.

 

Thank you in advance

Edited by cramli
Link to comment
Share on other sites

Dear Raiwa

 

I installed again the begin of the update to 2.3.4 (from 2.3.3.4) and again the same problem. Have a look on my site: http://apromo.com.br/product_info.php/cPath/45/products_id/75

 

Thank you in advance for helping

Hello Marc,

 

Nothing to do with kiss image thumbnailer. It's an update problem to colorbox and photoset-grid.

Please post your relevant part of product_info.php

Check if the colorbox and photoset-grid script folders are copied to catalog/ext/

 

regards

Rainer

Edited by raiwa
Link to comment
Share on other sites

Dear Rainer

Thank you

 

The colorbox and photoset-grid script are in the ext folder.

 

Here my product_info.php:

 

<?php
/*
  $Id$
 
  osCommerce, Open Source E-Commerce Solutions
 
  Copyright © 2010 osCommerce
 
  Released under the GNU General Public License
*/
 
  require('includes/application_top.php');
 
  if (!isset($HTTP_GET_VARS['products_id'])) {
    tep_redirect(tep_href_link(FILENAME_DEFAULT));
  }
 
  require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_PRODUCT_INFO);
 
  $product_check_query = tep_db_query("select count(*) as total from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pd.products_id = p.products_id and pd.language_id = '" . (int)$languages_id . "'");
  $product_check = tep_db_fetch_array($product_check_query);
 
  require(DIR_WS_INCLUDES . 'template_top.php');
 
  if ($product_check['total'] < 1) {
?>
 
<div class="contentContainer">
  <div class="contentText">
    <?php echo TEXT_PRODUCT_NOT_FOUND; ?>
  </div>
 
  <div style="float: right;">
    <?php echo tep_draw_button(IMAGE_BUTTON_CONTINUE, 'triangle-1-e', tep_href_link(FILENAME_DEFAULT)); ?>
  </div>
</div>
 
<?php
  } else {
    $product_info_query = tep_db_query("select p.products_id, pd.products_name, pd.products_description, p.products_model, p.products_quantity, p.products_image, pd.products_url, p.products_price, p.products_tax_class_id, p.products_date_added, p.products_date_available, p.manufacturers_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pd.products_id = p.products_id and pd.language_id = '" . (int)$languages_id . "'");
    $product_info = tep_db_fetch_array($product_info_query);
 
    tep_db_query("update " . TABLE_PRODUCTS_DESCRIPTION . " set products_viewed = products_viewed+1 where products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and language_id = '" . (int)$languages_id . "'");
 
    if ($new_price = tep_get_products_special_price($product_info['products_id'])) {
      $products_price = '<del>' . $currencies->display_price($product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id'])) . '</del> <span class="productSpecialPrice">' . $currencies->display_price($new_price, tep_get_tax_rate($product_info['products_tax_class_id'])) . '</span>';
    } else {
      $products_price = $currencies->display_price($product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id']));
    }
 
    if (tep_not_null($product_info['products_model'])) {
      $products_name = $product_info['products_name'] . '<br /><span class="smallText">[' . $product_info['products_model'] . ']</span>';
    } else {
      $products_name = $product_info['products_name'];
    }
?>
 
<?php echo tep_draw_form('cart_quantity', tep_href_link(FILENAME_PRODUCT_INFO, tep_get_all_get_params(array('action')) . 'action=add_product')); ?>
 
<div>
  <h1 style="float: right;"><?php echo $products_price; ?></h1>
  <h1><?php echo $products_name; ?></h1>
</div>
 
<div class="contentContainer">
  <div class="contentText">
 
<?php
    if (tep_not_null($product_info['products_image'])) {
      $photoset_layout = '1';
 
      $pi_query = tep_db_query("select image, htmlcontent from " . TABLE_PRODUCTS_IMAGES . " where products_id = '" . (int)$product_info['products_id'] . "' order by sort_order");
      $pi_total = tep_db_num_rows($pi_query);
 
      if ($pi_total > 0) {
        $pi_sub = $pi_total-1;
 
        while ($pi_sub > 5) {
          $photoset_layout .= 5;
          $pi_sub = $pi_sub-5;
        }
 
        if ($pi_sub > 0) {
          $photoset_layout .= ($pi_total > 5) ? 5 : $pi_sub;
        }
?>
 
    <div id="piGal">
 
<?php
        $pi_counter = 0;
        $pi_html = array();
 
        while ($pi = tep_db_fetch_array($pi_query)) {
          $pi_counter++;
 
          if (tep_not_null($pi['htmlcontent'])) {
            $pi_html[] = '<div id="piGalDiv_' . $pi_counter . '">' . $pi['htmlcontent'] . '</div>';
          }
 
          echo tep_image(DIR_WS_IMAGES . $pi['image'], '', '', '', 'id="piGalImg_' . $pi_counter . '"');
        }
?>
 
    </div>
 
<?php
        if ( !empty($pi_html) ) {
          echo '    <div style="display: none;">' . implode('', $pi_html) . '</div>';
        }
      } else {
?>
 
    <div id="piGal">
      <?php echo tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name'])); ?>
    </div>
 
<?php
      }
    }
?>
 
<script type="text/javascript">
$(function() {
  $('#piGal').css({
    'visibility': 'visible'
  });
 
  $('#piGal').photosetGrid({
    layout: '<?php echo $photoset_layout; ?>',
    width: '250px',
    highresLinks: true,
    rel: 'pigallery',
    onComplete: function() {
      $('#piGal').css({ 'visibility': 'visible'});
 
      $('#piGal a').colorbox({
        maxHeight: '90%',
        maxWidth: '90%',
        rel: 'pigallery'
      });
 
      $('#piGal img').each(function() {
        var imgid = $(this).attr('id').substring(9);
 
        if ( $('#piGalDiv_' + imgid).length ) {
          $(this).parent().colorbox({ inline: true, href: "#piGalDiv_" + imgid });
        }
      });
    }
  });
});
</script>
<?php echo stripslashes($product_info['products_description']); ?>
 
<?php
    $products_attributes_query = tep_db_query("select count(*) as total from " . TABLE_PRODUCTS_OPTIONS . " popt, " . TABLE_PRODUCTS_ATTRIBUTES . " patrib where patrib.products_id='" . (int)$HTTP_GET_VARS['products_id'] . "' and patrib.options_id = popt.products_options_id and popt.language_id = '" . (int)$languages_id . "'");
    $products_attributes = tep_db_fetch_array($products_attributes_query);
    if ($products_attributes['total'] > 0) {
?>
 
    <p><?php echo TEXT_PRODUCT_OPTIONS; ?></p>
 
    <p>
<?php
      $products_options_name_query = tep_db_query("select distinct popt.products_options_id, popt.products_options_name from " . TABLE_PRODUCTS_OPTIONS . " popt, " . TABLE_PRODUCTS_ATTRIBUTES . " patrib where patrib.products_id='" . (int)$HTTP_GET_VARS['products_id'] . "' and patrib.options_id = popt.products_options_id and popt.language_id = '" . (int)$languages_id . "' order by popt.products_options_name");
      while ($products_options_name = tep_db_fetch_array($products_options_name_query)) {
        $products_options_array = array();
        $products_options_query = tep_db_query("select pov.products_options_values_id, pov.products_options_values_name, pa.options_values_price, pa.price_prefix from " . TABLE_PRODUCTS_ATTRIBUTES . " pa, " . TABLE_PRODUCTS_OPTIONS_VALUES . " pov where pa.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pa.options_id = '" . (int)$products_options_name['products_options_id'] . "' and pa.options_values_id = pov.products_options_values_id and pov.language_id = '" . (int)$languages_id . "'");
        while ($products_options = tep_db_fetch_array($products_options_query)) {
          $products_options_array[] = array('id' => $products_options['products_options_values_id'], 'text' => $products_options['products_options_values_name']);
          if ($products_options['options_values_price'] != '0') {
            $products_options_array[sizeof($products_options_array)-1]['text'] .= ' (' . $products_options['price_prefix'] . $currencies->display_price($products_options['options_values_price'], tep_get_tax_rate($product_info['products_tax_class_id'])) .') ';
          }
        }
 
        if (is_string($HTTP_GET_VARS['products_id']) && isset($cart->contents[$HTTP_GET_VARS['products_id']]['attributes'][$products_options_name['products_options_id']])) {
          $selected_attribute = $cart->contents[$HTTP_GET_VARS['products_id']]['attributes'][$products_options_name['products_options_id']];
        } else {
          $selected_attribute = false;
        }
?>
      <strong><?php echo $products_options_name['products_options_name'] . ':'; ?></strong><br /><?php echo tep_draw_pull_down_menu('id[' . $products_options_name['products_options_id'] . ']', $products_options_array, $selected_attribute); ?><br />
<?php
      }
?>
    </p>
 
<?php
    }
?>
 
    <div style="clear: both;"></div>
 
<?php
    if ($product_info['products_date_available'] > date('Y-m-d H:i:s')) {
?>
 
    <p style="text-align: center;"><?php echo sprintf(TEXT_DATE_AVAILABLE, tep_date_long($product_info['products_date_available'])); ?></p>
 
<?php
    }
?>
 
  </div>
 
<?php
    $reviews_query = tep_db_query("select count(*) as count from " . TABLE_REVIEWS . " r, " . TABLE_REVIEWS_DESCRIPTION . " rd where r.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and r.reviews_id = rd.reviews_id and rd.languages_id = '" . (int)$languages_id . "' and reviews_status = 1");
    $reviews = tep_db_fetch_array($reviews_query);
?>
 
  <div class="buttonSet">
 
<?php
// BOF: MOD - EASY CALL FOR PRICE 2.3.1v1.0
/*
 
    <span class="buttonAction"><?php echo tep_draw_hidden_field('products_id', $product_info['products_id']) . tep_draw_button(IMAGE_BUTTON_IN_CART, 'cart', null, 'primary'); ?></span>
*/
    if ($product_info['products_price'] == CALL_FOR_PRICE_VALUE){
?>
    <span class="buttonAction">
    <a href="javascript:history.go(-1)"><?php echo tep_draw_button(IMAGE_BUTTON_BACK,'Back',null,'primary'); ?></a></span>
<?php
} else {
?>
    <span class="buttonAction"><?php echo tep_draw_hidden_field('products_id', $product_info['products_id']) . tep_draw_button(IMAGE_BUTTON_IN_CART, 'cart', null, 'primary'); ?></span>
<?php
}
// EOF: MOD - EASY CALL FOR PRICE 2.3.1v1.0
?>
 
<?php echo tep_draw_button(IMAGE_BUTTON_REVIEWS . (($reviews['count'] > 0) ? ' (' . $reviews['count'] . ')' : ''), 'comment', tep_href_link(FILENAME_PRODUCT_REVIEWS, tep_get_all_get_params())); ?>
  </div>
 
<?php
    if ((USE_CACHE == 'true') && empty($SID)) {
      echo tep_cache_also_purchased(3600);
    } else {
      include(DIR_WS_MODULES . FILENAME_ALSO_PURCHASED_PRODUCTS);
    }
?>
 
</div>
 
</form>
 
<?php
  }
 
  require(DIR_WS_INCLUDES . 'template_bottom.php');
  require(DIR_WS_INCLUDES . 'application_bottom.php');
?>
Link to comment
Share on other sites

@@cramli,

 

Your product_info.php seems to be ok. It works on my 2.3.4 test-store.

Please compare your header:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns="http://www.w3.org/1999/xhtml" dir="ltr" lang="en">



<head>
<script type="text/javascript">var switchTo5x=true;</script>
<script type="text/javascript" src="http://w.sharethis.com/button/buttons.js"></script>
<script type="text/javascript" src="http://s.sharethis.com/loader.js"></script>

<meta name="msvalidate.01" content="BFF41CBE49291D5FCC46DC59A4A5442E" />
<script type="text/javascript" src="https://apis.google.com/js/plusone.js"></script>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="robots" content="index,follow" />
<title></title>
<base href="http://apromo.com.br/" />
<link rel="stylesheet" type="text/css" href="ext/jquery/ui/redmond/jquery-ui-1.10.4.min.css" />
<script type="text/javascript" src="ext/jquery/jquery-1.11.1.min.js"></script>>
<script type="text/javascript" src="ext/jquery/ui/jquery-ui-1.10.4.min.js"></script>
<script type="text/javascript" src="ext/photoset-grid/jquery.photoset-grid.min.js"></script>

<link rel="stylesheet" type="text/css" href="ext/colorbox/colorbox.css" />
<script type="text/javascript" src="ext/colorbox/jquery.colorbox-min.js"></script>
<link rel="stylesheet" type="text/css" href="ext/960gs/960_24_col.css" />
<link rel="stylesheet" type="text/css" href="stylesheet.css" />

with the standard 2.3.4 header:

<!DOCTYPE html>
<html dir="ltr" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Samsung Galaxy Tab, Gadgets, OsC 2.3.4</title>
<base href="http://localhost/oscommerce-2.3.4/catalog/" />
<link rel="stylesheet" type="text/css" href="ext/jquery/ui/redmond/jquery-ui-1.10.4.min.css" />
<script type="text/javascript" src="ext/jquery/jquery-1.11.1.min.js"></script>
<script type="text/javascript" src="ext/jquery/ui/jquery-ui-1.10.4.min.js"></script>


<script type="text/javascript" src="ext/photoset-grid/jquery.photoset-grid.min.js"></script>

<link rel="stylesheet" type="text/css" href="ext/colorbox/colorbox.css" />
<script type="text/javascript" src="ext/colorbox/jquery.colorbox-min.js"></script>

<link rel="stylesheet" type="text/css" href="ext/960gs/960_24_col.css" />
<link rel="stylesheet" type="text/css" href="stylesheet.css" />

1. move the additional scripts:

<script type="text/javascript">var switchTo5x=true;</script>
<script type="text/javascript" src="http://w.sharethis.com/button/buttons.js"></script>
<script type="text/javascript" src="http://s.sharethis.com/loader.js"></script>

<meta name="msvalidate.01" content="BFF41CBE49291D5FCC46DC59A4A5442E" />
<script type="text/javascript" src="https://apis.google.com/js/plusone.js"></script>

below the standard scripts

 

2. try to change the html declaration line 1-2

Link to comment
Share on other sites

@@Rainer

Thank you.

 

Can you tell me from where do you have this standard header? Mine is different ( original osc 2.3.4)

And do you mean the template_top.php or header.php??

I mean the header in the sense of html output, what you see when you open the source code window in your browser.

 

The php source code is in template_top.php.

 

My standard header is from a unmodified standard 2.3.4 store.

The php source of the template_top.php is this:

<?php
/*
  $Id$

  osCommerce, Open Source E-Commerce Solutions
  http://www.oscommerce.com

  Copyright (c) 2014 osCommerce

  Released under the GNU General Public License
*/

  $oscTemplate->buildBlocks();

  if (!$oscTemplate->hasBlocks('boxes_column_left')) {
    $oscTemplate->setGridContentWidth($oscTemplate->getGridContentWidth() + $oscTemplate->getGridColumnWidth());
  }

  if (!$oscTemplate->hasBlocks('boxes_column_right')) {
    $oscTemplate->setGridContentWidth($oscTemplate->getGridContentWidth() + $oscTemplate->getGridColumnWidth());
  }
?>
<!DOCTYPE html>
<html <?php echo HTML_PARAMS; ?>>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>" />
<title><?php echo tep_output_string_protected($oscTemplate->getTitle()); ?></title>
<base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>" />
<link rel="stylesheet" type="text/css" href="ext/jquery/ui/redmond/jquery-ui-1.10.4.min.css" />
<script type="text/javascript" src="ext/jquery/jquery-1.11.1.min.js"></script>
<script type="text/javascript" src="ext/jquery/ui/jquery-ui-1.10.4.min.js"></script>

<?php
  if (tep_not_null(JQUERY_DATEPICKER_I18N_CODE)) {
?>
<script type="text/javascript" src="ext/jquery/ui/i18n/jquery.ui.datepicker-<?php echo JQUERY_DATEPICKER_I18N_CODE; ?>.js"></script>
<script type="text/javascript">
$.datepicker.setDefaults($.datepicker.regional['<?php echo JQUERY_DATEPICKER_I18N_CODE; ?>']);
</script>
<?php
  }
?>

<script type="text/javascript" src="ext/photoset-grid/jquery.photoset-grid.min.js"></script>

<link rel="stylesheet" type="text/css" href="ext/colorbox/colorbox.css" />
<script type="text/javascript" src="ext/colorbox/jquery.colorbox-min.js"></script>

<link rel="stylesheet" type="text/css" href="ext/960gs/<?php echo ((stripos(HTML_PARAMS, 'dir="rtl"') !== false) ? 'rtl_' : ''); ?>960_24_col.css" />
<link rel="stylesheet" type="text/css" href="stylesheet.css" />
<?php echo $oscTemplate->getBlocks('header_tags'); ?>
</head>

You can try to remove temporary your additional scripts to check if they brake the standard scripts:

<script type="text/javascript">var switchTo5x=true;</script>
<script type="text/javascript" src="http://w.sharethis.com/button/buttons.js"></script>
<script type="text/javascript" src="http://s.sharethis.com/loader.js"></script>

<meta name="msvalidate.01" content="BFF41CBE49291D5FCC46DC59A4A5442E" />
<script type="text/javascript" src="https://apis.google.com/js/plusone.js"></script>
Link to comment
Share on other sites

@@cramli,

found it, you have these lines repeated twice, remove the second copy:

<script type="text/javascript" src="ext/jquery/jquery-1.11.1.min.js"></script>
<script type="text/javascript" src="ext/jquery/ui/jquery-ui-1.10.4.min.js"></script>
<link rel="stylesheet" type="text/css" href="ext/jquery/ui/redmond/jquery-ui-1.10.4.min.css" />
Edited by raiwa
Link to comment
Share on other sites

@@Rainer

 

Thank you again. When I check in the template_top.php I can only find the lines you mentioned, once and not twice. Do I look wrong into it? Or you mean in a other file? :(

@@cramli,

 

Maybe you added these lines in template_top.php AND header.php. They should only be in template_top.php.

However I found them yesterday repeated in the header (html source code), but as you reverted now I can't show you.

 

Please, can you post your updated template_top.php AND header.php.

Edited by raiwa
Link to comment
Share on other sites

@@Rainer

 

Here again the two files.

 

template_top.php:

 

<?php
/*
  $Id$
 
  osCommerce, Open Source E-Commerce Solutions
 
 
  <div id="headerShortcuts">
<?php
  echo tep_draw_button(HEADER_TITLE_CART_CONTENTS . ($cart->count_contents() > 0 ? ' (' . $cart->count_contents() . ')' : ''), 'cart', tep_href_link(FILENAME_SHOPPING_CART)) .
       tep_draw_button(HEADER_TITLE_CHECKOUT, 'triangle-1-e', tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL')) .
       tep_draw_button(HEADER_TITLE_MY_ACCOUNT, 'person', tep_href_link(FILENAME_ACCOUNT, '', 'SSL'));
 
  if (tep_session_is_registered('customer_id')) {
    echo tep_draw_button(HEADER_TITLE_LOGOFF, null, tep_href_link(FILENAME_LOGOFF, '', 'SSL'));
  }
?>
  </div>
 
<script type="text/javascript">
  $("#headerShortcuts").buttonset();
</script>
</div>
 
<div class="grid_24 ui-widget infoBoxContainer">
  <div class="ui-widget-header infoBoxHeading"><?php echo '  ' . $breadcrumb->trail(' » '); ?></div>
</div>
 
<?php
  if (isset($HTTP_GET_VARS['error_message']) && tep_not_null($HTTP_GET_VARS['error_message'])) {
?>
<table border="0" width="100%" cellspacing="0" cellpadding="2">
  <tr class="headerError">
    <td class="headerError"><?php echo htmlspecialchars(stripslashes(urldecode($HTTP_GET_VARS['error_message']))); ?></td>
  </tr>
</table>
<?php
  }
 
  if (isset($HTTP_GET_VARS['info_message']) && tep_not_null($HTTP_GET_VARS['info_message'])) {
?>
<table border="0" width="100%" cellspacing="0" cellpadding="2">
  <tr class="headerInfo">
    <td class="headerInfo"><?php echo htmlspecialchars(stripslashes(urldecode($HTTP_GET_VARS['info_message']))); ?></td>
  </tr>
</table>
<?php
  }
?>
 
 
Thank you again for helping
Link to comment
Share on other sites

When I made today the new installation again, I also installed the theme switcher. After the installation without changing the theme, my site was working right. After changing the theme, the pictures went again big sized. Maybe there is a problem?

 

Now the site is working with the normal redmond theme, but still wrong pictures (size)

Edited by cramli
Link to comment
Share on other sites

@@cramli,

 

I copied your 3 files, template_top.php, header.php and product_info.php in my teststore and it works and shows correct.

 

But when I open your actual html source code, I find the lines I mentioned duplicated:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR...nsitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns="http://www.w3.org/1999/xhtml" dir="ltr" lang="en">



<head>
<script type="text/javascript">var switchTo5x=true;</script>
<script type="text/javascript" src="http://w.sharethis.c...s.js"></script>
<script type="text/javascript" src="http://s.sharethis.c...r.js"></script>

<meta name="msvalidate.01" content="BFF41CBE49291D5FCC46DC59A4A5442E" />
<script type="text/javascript" src="https://apis.google....e.js"></script>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="robots" content="index,follow" />
<title></title>
<base href="http://apromo.com.br/" />
<link rel="stylesheet" type="text/css" href="ext/jquery/ui/redmond/jquery-ui-1.10.4.min.css" />
****************here first copy****<script type="text/javascript" src="ext/jquery/jquery-1.11.1.min.js"></script>
****************here first copy****<script type="text/javascript" src="ext/jquery/ui/jquery-ui-1.10.4.min.js"></script>
****************here first copy****<script type="text/javascript" src="ext/photoset-grid/jquery.photoset-grid.min.js"></script>

<link rel="stylesheet" type="text/css" href="ext/colorbox/colorbox.css" />
<script type="text/javascript" src="ext/colorbox/jquery.colorbox-min.js"></script>
<link rel="stylesheet" type="text/css" href="ext/960gs/960_24_col.css" />
<link rel="stylesheet" type="text/css" href="stylesheet.css" />
<link rel="canonical" href="http://apromo.com.br/product_info.php/products_id/75" />

<script type="text/javascript">
  var _gaq = _gaq || [];
  _gaq.push(['_setAccount', 'UA-37183444-1']);
  _gaq.push(['_trackPageview']);
  (function() {
    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
  })();
</script>

<link rel="search" type="application/opensearchdescription+xml" href="http://apromo.com.br/opensearch.php" title="Onlineshop - Apromo -" />
***************here duplicate****<script type="text/javascript" src="ext/jquery/jquery-1.11.1.min.js"></script>
***************here duplicate****<script type="text/javascript" src="ext/jquery/ui/jquery-ui-1.10.4.min.js"></script>
***************here duplicate****<link rel="stylesheet" type="text/css" href="ext/jquery/ui/redmond/jquery-ui-1.10.4.min.css" />

<meta name="twitter:card" content="product" />
<meta name="twitter:title" content="3D CUBE PRINTER" />
<meta name="twitter:description" content="The Cube 3 is the newest entry level model of the 3D Systems printers. The device is not very different from its previous version, just improving the print speed and letting the exchange of materia .." />
<meta name="twitter:image:src" content="http://apromo.com.br/images/bkgcubecolorsb.jpg" />
<meta name="twitter:data1" content="$0.00" />
<meta name="twitter:label1" content="USD" />
<meta name="twitter:data2" content="Out of Stock" />
<meta name="twitter:label2" content="CONTACT US" />
<meta name="google-site-verification" content="0UN5spS_j0zVNBI4Y3cKo3TAVB6V-cgs4Uu91bslGac" />
</head>
 <script type="text/javascript">stLight.options({publisher: "b3059cbe-5f0b-4623-9d0d-7590d24ea12a", doNotHash: false, doNotCopy: false, hashAddressBar: false});</script>
<script>
var options={ "publisher": "b3059cbe-5f0b-4623-9d0d-7590d24ea12a", "position": "left", "ad": { "visible": false, "openDelay": 5, "closeDelay": 0}, "chicklets": { "items": ["facebook", "twitter", "linkedin", "pinterest", "email", "sharethis"]}};
var st_hover_widget = new sharethis.widgets.hoverbuttons(options);
</script>
<body>

Please check yourself in your browser open "Source code".

 

The only explication, (supposed you posted the correct file versions) is that you have these lines included in a header_tag module:

<script type="text/javascript" src="ext/jquery/jquery-1.11.1.min.js"></script>
<script type="text/javascript" src="ext/jquery/ui/jquery-ui-1.10.4.min.js"></script>
<link rel="stylesheet" type="text/css" href="ext/jquery/ui/redmond/jquery-ui-1.10.4.min.css" />

Try to remove step by step your header tag modules in Admin to find out which one adds these duplicated lines.

 

Best regards

Rainer

Edited by raiwa
Link to comment
Share on other sites

When I made today the new installation again, I also installed the theme switcher. After the installation without changing the theme, my site was working right. After changing the theme, the pictures went again big sized. Maybe there is a problem?

 

Now the site is working with the normal redmond theme, but still wrong pictures (size)

Then check if the theme switcher adds these lines again and remove them there

Link to comment
Share on other sites

@@Rainer

 

I will do so. But one thing I have to ask you; I was looking in the files from a virgin OSC 2.3.4 and there in the admin/includes/modules/ I can not find the module- heater_tag.php. Is that right so?

Edited by cramli
Link to comment
Share on other sites

@@Rainer

 

I will do so. But one thing I have to ask you; I was looking in the files from a virgin OSC 2.3.4 and there in the admin/includes/modules/ I can not find the module- heater_tag.php. Is that right so?

there is a folder "header_tags" inside includes/modules, there are several header_tags modules inside all beginning with "ht_......".

Link to comment
Share on other sites

I found the problem: includes/modules/header_tags/ht_theme_switcher.php. I turned off, now the pictures are resized. But still if I will use the theme switcher, what is the problem ?

And also can you indicate me, where I can resize the small images? 

Link to comment
Share on other sites

This is the th_theme_switcher.php:

 

 

<?php
/*
 $Id: ht_theme_switcher.php 1.4.3 20140513 Kymation $
 
 osCommerce, Open Source E-Commerce Solutions
 
 Copyright © 2014 osCommerce
 
 Released under the GNU General Public License
 */
 
 
        class ht_theme_switcher {
                public $code;
                public $group;
                public $title;
                public $description;
                public $sort_order;
                public $enabled = false;
                public $version = '1.4.3';
 
                ////
                // Class constructor to set values at instantiation
                function ht_theme_switcher() {
      $this->code = get_class( $this );
      $this->group = basename( dirname( __FILE__ ) );
 
                  $this->title = MODULE_HEADER_TAGS_THEME_SWITCHER_TITLE;
                        $this->description = MODULE_HEADER_TAGS_THEME_SWITCHER_DESCRIPTION;
 
                        if ( defined('MODULE_HEADER_TAGS_THEME_SWITCHER_STATUS') ) {
                                $this->sort_order = MODULE_HEADER_TAGS_THEME_SWITCHER_SORT_ORDER;
                                $this->enabled = (MODULE_HEADER_TAGS_THEME_SWITCHER_STATUS == 'True');
                        }
                }
 
                ////
                // Produce the module output: A set of header tags
                public function execute() {
                        global $oscTemplate;
 
                        $jquery_version = '1.11.1';
                        if( MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_VERSION != '' ) {
                                $jquery_version = MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_VERSION;
                        }
 
                        $jquery_ui_version = '1.10.4';
                        if( MODULE_HEADER_TAGS_THEME_SWITCHER_THEME != '' ) {
                                $jquery_ui_version = MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_UI_VERSION;
                        }
 
                        $theme_name = 'redmond';
                        if( MODULE_HEADER_TAGS_THEME_SWITCHER_THEME != '' ) {
                                $theme_name = MODULE_HEADER_TAGS_THEME_SWITCHER_THEME;
                        }
 
                        $theme_text = '<script type="text/javascript" src="ext/jquery/jquery-' . $jquery_version . '.min.js"></script>' . PHP_EOL;
                        $theme_text .= '<script type="text/javascript" src="ext/jquery/ui/jquery-ui-' . $jquery_ui_version . '.min.js"></script>' . PHP_EOL;
                        $theme_text .= '<link rel="stylesheet" type="text/css" href="ext/jquery/ui/' . $theme_name . '/jquery-ui-' . $jquery_ui_version . '.min.css" />' . PHP_EOL;
 
                        $oscTemplate->addBlock( $theme_text, $this->group );
                }
 
                ////
                // Check whether the module is enabled
                public function isEnabled() {
                        return $this->enabled;
                }
 
                ////
                // Check the module's status
                public function check() {
                        return defined( 'MODULE_HEADER_TAGS_THEME_SWITCHER_STATUS' );
                }
 
                ////
                // Install the module and check for correct installation of related files/directories
                public function install() {
                        // Fix the module loading order to avoid jQuery conflicts
                        $this->load_header_tags_first();
 
                        // Standard configuration install
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added ) values ( 'Version: " . $this->version . "', 'MODULE_HEADER_TAGS_THEME_SWITCHER_VERSION', '', '', '6', '0', '', 'tep_cfg_do_nothing(', now() ) ");
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Enable Theme Switcher', 'MODULE_HEADER_TAGS_THEME_SWITCHER_STATUS', 'True', 'Do you want to be able to select a theme here?', '6', '1', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())" );
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Sort Order', 'MODULE_HEADER_TAGS_THEME_SWITCHER_SORT_ORDER', '1', 'Sort order of display. Lowest is displayed first.', '6', '2', now())" );
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Jquery Version', 'MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_VERSION', '1.11.1', 'The version number of your Jquery module (e.g. 1.7.2).', '6', '3', now())" );
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Jquery UI Version', 'MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_UI_VERSION', '1.10.4', 'The version number of your Jquery UI module (e.g. 1.8.21).', '6', '4', now())" );
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Theme', 'MODULE_HEADER_TAGS_THEME_SWITCHER_THEME', 'redmond', 'Select the theme that you want to use.', '6', '5', 'tep_cfg_pull_down_themes(', now())" );
 
                        // Special functions to check for missing files and version conflicts
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added ) values ( '', 'MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_TEST',  '',  '', '6', '7', 'tep_jquery_check', 'tep_cfg_do_nothing(', now() ) ");
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added ) values ( '', 'MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_UI_TEST',  '',  '', '6', '8', 'tep_jquery_ui_check', 'tep_cfg_do_nothing(', now() ) ");
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added ) values ( '', 'MODULE_HEADER_TAGS_THEME_SWITCHER_THEME_TEST',  '',  '', '6', '9', 'tep_theme_check', 'tep_cfg_do_nothing(', now() ) ");
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added ) values ( '', 'MODULE_HEADER_TAGS_THEME_SWITCHER_THEME_VERSION_TEST',  '',  '', '6', '10', 'tep_theme_version_check', 'tep_cfg_do_nothing(', now() ) ");
                        tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added ) values ( '', 'MODULE_HEADER_TAGS_THEME_SWITCHER_TEMPLATE_TOP_MODIFIED',  '',  '', '6', '11', 'tep_template_top_check', 'tep_cfg_do_nothing(', now() ) ");
      tep_db_query( "insert into " . TABLE_CONFIGURATION . " ( configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added ) values ( '', 'MODULE_HEADER_TAGS_THEME_SWITCHER_LANGUAGE_FILE_TEST',  '',  '', '6', '12', 'tep_language_file_check', 'tep_cfg_do_nothing(', now() ) ");
                }
 
                ////
                // Uninstall the module
                public function remove() {
                        tep_db_query( "delete from " . TABLE_CONFIGURATION . " where configuration_key in ('" . implode("', '", $this->keys()) . "')");
                }
 
                ////
                // Generate the keys array of constant names
                public function keys() {
                        $keys = array();
 
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_VERSION';
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_STATUS';
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_SORT_ORDER';
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_VERSION';
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_UI_VERSION';
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_THEME';
 
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_TEST';
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_UI_TEST';
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_THEME_TEST';
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_THEME_VERSION_TEST';
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_TEMPLATE_TOP_MODIFIED';
                        $keys[] = 'MODULE_HEADER_TAGS_THEME_SWITCHER_LANGUAGE_FILE_TEST';
 
                        return $keys;
                }
 
                ////
                // Force the header tags to load first, so the jQuery and jQuery UI code is available
                //   to other scripts that load in the head section
                private function load_header_tags_first() {
                        // If header_tags is not the first item on the list
                        if( substr( TEMPLATE_BLOCK_GROUPS, 0, 11 ) != 'header_tags' ) {
                                // Remove header_tags from wherever it is in the list
                                $template_block_groups = str_replace( ';header_tags', '', TEMPLATE_BLOCK_GROUPS );
                                // And add header_tags back onto the front of the list
                                $template_block_groups = 'header_tags;' . $template_block_groups;
                                $sql_data_array = array( 'configuration_value' => $template_block_groups );
                                // Update the database with the fixed string
                                tep_db_perform( TABLE_CONFIGURATION, $sql_data_array, 'update', "configuration_key = 'TEMPLATE_BLOCK_GROUPS'" );
                        } // if( substr
                } // function _load_header_tags_first
 
        } // end class
 
 
 
        /////////////////////////////////////////////////////////////////////////////////////////////////
        //
        //    The following are functions, not class methods
        //
        /////////////////////////////////////////////////////////////////////////////////////////////////
 
        ////
        // Multi-level array sort function (From the PHP manual)
        if (!function_exists('array_msort')) {
                function array_msort( $array, $cols ) {
                        $colarr = array ();
                        foreach ($cols as $col => $order) {
                                $colarr[$col] = array ();
                                foreach ($array as $k => $row) {
          $colarr[$col]['_' . $k] = strtolower($row[$col]);
                                }
                        }
                        $params = array ();
                        foreach ($cols as $col => $order) {
                                $params[] = & $colarr[$col];
                                $order = (array) $order;
                                foreach ($order as $order_element) {
                                        //pass by reference, as required by php 5.3
                                        $params[] = & $order_element;
                                }
                        }
                        call_user_func_array('array_multisort', $params);
                        $ret = array ();
                        $keys = array ();
                        $first = true;
                        foreach ($colarr as $col => $arr) {
                                foreach ($arr as $k => $v) {
                                        if ($first) {
                                                $keys[$k] = substr($k, 1);
                                        }
                                        $k = $keys[$k];
 
                                        if (!isset ($ret[$k])) {
                                                $ret[$k] = $array[$k];
                                        }
 
                                        $ret[$k][$col] = $array[$k][$col];
                                }
                                $first = false;
                        }
                        return $ret;
                } // function array_msort
  } // if (!function_exists
 
 
        ////
        // Get a list of the files or directories in a directory
        if (!function_exists('tep_get_directory_list')) {
                function tep_get_directory_list( $directory, $file = true, $exclude = array() ) {
                        $d = dir( $directory );
                        $list = array ();
                        while ($entry = $d->read()) {
                                if ($file == true) { // We want a list of files, not directories
                                        $parts_array = explode('.', $entry);
                                        // There may be more than one dot, so find the last one
                                        $last = count( $parts_array ) - 1;
                                        $extension = $parts_array[$last];
                                        // Don't add files or directories that we don't want
                                        if( $entry != '.' && $entry != '..' && $entry != '.htaccess' && $extension != 'php') {
                                                if( !is_dir( $directory . "/" . $entry ) ) {
                                                        $list[] = $entry;
                                                }
                                        }
                                } else { // We want the directories and not the files
                                        if (is_dir($directory . "/" . $entry) && $entry != '.' && $entry != '..') { // && $entry != 'i18n'
                                                if (count($exclude) == 0 || !in_array($entry, $exclude)) {
                                                        $list[] = array (
                'id' => $entry,
                'text' => $entry
                                                        );
                                                }
                                        }
                                }
                        } // while ($entry
                        $d->close();
 
                        return $list;
                }
        }
 
        ////
        // Generate a pulldown menu of the available themes
        if (!function_exists('tep_cfg_pull_down_themes')) {
                function tep_cfg_pull_down_themes( $theme_name, $key = '' ) {
                        $themes_array = array ();
                        $theme_directory = DIR_FS_CATALOG . 'ext/jquery/ui';
 
                        if (file_exists( $theme_directory ) && is_dir( $theme_directory ) ) {
                                $name = ( ( $key ) ? 'configuration[' . $key . ']' : 'configuration_value' );
 
                                $exclude = array( 'i18n' );
                                $themes_array = tep_get_directory_list( $theme_directory, false, $exclude );
 
                          $themes_array = array_msort( $themes_array, array( 'id' => SORT_ASC ) );
                          $themes_array = array_values( $themes_array );
                          sort( $themes_array );
                        }
 
                        return tep_draw_pull_down_menu( $name, $themes_array, $theme_name );
                }
        }
 
 
        ////
        // Check whether the selected theme's directory exists
        if( !function_exists( 'tep_theme_check' ) ) {
                function tep_theme_check() {
                        // The theme directory is hard-coded in the rest of osC, so...
                        $theme_directory = DIR_FS_CATALOG . 'ext/jquery/ui';
 
                        if( file_exists( $theme_directory ) && is_dir( $theme_directory ) ) {
                                // Exclude directories that are not themes
                                $exclude = array( 'i18n' );
 
                                // Get an array of all of the theme directories
                                $themes_array = tep_get_directory_list( $theme_directory, false, $exclude );
 
                                // Step through the themes and check for a match with the selected theme
                                foreach( $themes_array as $theme ) {
                                        if( $theme['text'] == MODULE_HEADER_TAGS_THEME_SWITCHER_THEME ) {
                                                //The theme folder exists, so return success and quit
                                                return tep_image( DIR_WS_ICONS . 'tick.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_THEME_FOUND . '</span>';
                                                break;
                                        }
                                }
 
                        } // if( file_exists
 
                        // The theme was not found, so return an error message
                        return tep_image( DIR_WS_ICONS . 'cross.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold; color:red;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_THEME_MISSING . '</span>';
                } // function theme_check
        } // if( !function_exists
 
 
        ////
        // Check whether the selected jQuery file exists
        if( !function_exists( 'tep_jquery_check' ) ) {
                function tep_jquery_check() {
                        // The jQuery directory is hard-coded in the rest of osC, so...
                        $jquery_directory = DIR_FS_CATALOG . 'ext/jquery/';
 
                        if( file_exists( $jquery_directory ) && is_dir( $jquery_directory ) ) {
                          // Get an array of all of the files in the directory
                                $jquery_array = tep_get_directory_list( $jquery_directory );
 
                                // Step through the array and check for a match with the selected jQuery version
                                foreach( $jquery_array as $jquery_file ) {
                                  if( $jquery_file == 'jquery-' . MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_VERSION . '.min.js' ) {
                                                //The jQuery file exists, so return success and quit
                                                return tep_image( DIR_WS_ICONS . 'tick.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_FOUND . '</span>';
                                                break;
                                        }
                                }
 
                        } // if( file_exists
 
                        // The jQuery file was not found, so return an error message
                        return tep_image( DIR_WS_ICONS . 'cross.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold; color:red;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_MISSING . '</span>';
                } // function tep_theme_check
        } // if( !function_exists
 
 
        ////
        // Check whether the selected jQuery UI file exists
        if( !function_exists( 'tep_jquery_ui_check' ) ) {
                function tep_jquery_ui_check() {
                        // The jQuery UI directory is hard-coded in the rest of osC, so...
                        $jquery_ui_directory = DIR_FS_CATALOG . 'ext/jquery/ui/';
 
                        if( file_exists( $jquery_ui_directory ) && is_dir( $jquery_ui_directory ) ) {
                                // Get an array of all of the files in the directory
                                $jquery_ui_array = tep_get_directory_list( $jquery_ui_directory );
 
                                // Step through the array and check for a match with the selected jQuery version
                                foreach( $jquery_ui_array as $jquery_ui_file ) {
                                        if( $jquery_ui_file == 'jquery-ui-' . MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_UI_VERSION . '.min.js' ) {
                                                //The jQuery file exists, so return success and quit
                                                return tep_image( DIR_WS_ICONS . 'tick.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_UI_FOUND . '</span>';
                                                break;
                                        }
                                }
 
                        } // if( file_exists
 
                        // The jQuery file was not found, so return an error message
                        return tep_image( DIR_WS_ICONS . 'cross.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold; color:red;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_UI_MISSING . '</span>' . $jquery_directory;
                } // function theme_check
        } // if( !function_exists
 
 
        ////
        // Check whether the selected theme CSS file exists
        if( !function_exists( 'tep_theme_version_check' ) ) {
                function tep_theme_version_check() {
                        // The jQuery UI directory is hard-coded in the rest of osC, so...
                        $theme_directory = DIR_FS_CATALOG . 'ext/jquery/ui/' . MODULE_HEADER_TAGS_THEME_SWITCHER_THEME;
 
                        if( file_exists( $theme_directory ) && is_dir( $theme_directory ) ) {
                                // Get an array of all of the files in the theme directory
                                $themes_array = tep_get_directory_list( $theme_directory );
 
                                // Step through the files and check for a match with the selected version of the CSS file
                                foreach( $themes_array as $theme_css ) {
                                        if( $theme_css == 'jquery-ui-' . MODULE_HEADER_TAGS_THEME_SWITCHER_JQUERY_UI_VERSION . '.min.css' ) {
                                                //The correct version exists, so return success and quit
                                                return tep_image( DIR_WS_ICONS . 'tick.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_THEME_VERSION_FOUND . '</span>';
                                                break;
                                        }
                                }
 
                        } // if( file_exists
 
                        // The jQuery file was not found, so return an error message
                        return tep_image( DIR_WS_ICONS . 'cross.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold; color:red;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_THEME_VERSION_MISSING . '</span>' . $jquery_directory;
                } // function theme_check
        } // if( !function_exists
 
 
        ////
        // Check whether includes/template_top.php has been modified/replaced
        if( !function_exists( 'tep_template_top_check' ) ) {
                function tep_template_top_check() {
                        $filename = DIR_FS_CATALOG . DIR_WS_INCLUDES . 'template_top.php';
                        if( file_exists( $filename ) ) {
                                // Read the file into an array, one line per element
                                $file_array = file( $filename );
 
                                // Step through the files and check for a match with the selected version of the CSS file
                                foreach ($file_array as $line) {
                                        // Check if the line matches one of the lines that should be removed
                                        if( trim( $line ) == '<link rel="stylesheet" type="text/css" href="ext/jquery/ui/redmond/jquery-ui-1.8.6.css" />' ||
                                        trim( $line ) == '<script type="text/javascript" src="ext/jquery/jquery-1.4.2.min.js"></script>' ||
                                        trim( $line ) == '<script type="text/javascript" src="ext/jquery/ui/jquery-ui-1.8.6.min.js"></script>' ) {
                                                // One or more lines exist, so return error and quit
                                                return tep_image( DIR_WS_ICONS . 'cross.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold; color:red;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_TEMPLATE_TOP_NOT_MODIFIED . '</span>' . $jquery_directory;
                                                break;
                                        }
                                }
 
                        } else {
                                // The file was not found, so return an error
                                return tep_image( DIR_WS_ICONS . 'cross.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold; color:red;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_TEMPLATE_TOP_NOT_MODIFIED . '</span>' . $jquery_directory;
 
                        } // if( file_exists
 
                        // The lines were not found in the file, so return a success message
                        return tep_image( DIR_WS_ICONS . 'tick.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_TEMPLATE_TOP . '</span>';
                } // function theme_check
        } // if( !function_exists  MODULE_HEADER_TAGS_THEME_SWITCHER_TEMPLATE_TOP_MODIFIED
 
 
  ////
  // Check whether the language file for this module exists
  // We should only need to check the Admin language, so that is hardwired as $language
  if( !function_exists( 'tep_language_file_check' ) ) {
    function tep_language_file_check() {
            global $language;
 
      $language_file = DIR_FS_CATALOG . DIR_WS_LANGUAGES . $language . '/modules/header_tags/ht_theme_switcher.php';
 
      if( file_exists( $language_file ) && is_file( $language_file ) ) {
        return tep_image( DIR_WS_ICONS . 'tick.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_LANGUAGE_FILE_FOUND . '</span>';
        break;
      } // if( file_exists
 
      // The language file was not found, so return an error message
      return tep_image( DIR_WS_ICONS . 'cross.gif', '', '16', '16', 'style="vertical-align:middle;"' ) . ' <span style="vertical-align:middle; font-weight:bold; color:red;">' . MODULE_HEADER_TAGS_THEME_SWITCHER_LANGUAGE_FILE_MISSING . '</span>' . $jquery_directory;
    } // function tep_language_file_check
  } // if( !function_exists
 
 
        ////
        // Function to prevent boxes showing for the output-only test functions
  if( !function_exists( 'tep_cfg_do_nothing' ) ) {
    function tep_cfg_do_nothing() {
                  return '';
          }
  }
 
 
        ////
        // This should already exist in admin/includes/functions/general.php, but seems to be missing in some copies
        if( !function_exists( 'tep_get_languages' ) ) {
                function tep_get_languages() {
                        $languages_query = tep_db_query("select languages_id, name, code, image, directory from " . TABLE_LANGUAGES . " order by sort_order");
                        while ($languages = tep_db_fetch_array($languages_query)) {
                                $languages_array[] = array('id' => $languages['languages_id'],
                                   'name' => $languages['name'],
                                   'code' => $languages['code'],
                                   'image' => $languages['image'],
                                   'directory' => $languages['directory']);
                        }
 
                        return $languages_array;
                }
        }
 
?>
Link to comment
Share on other sites

@@cramli,

 

Remove these 3 lines:

                        $theme_text = '<script type="text/javascript" src="ext/jquery/jquery-' . $jquery_version . '.min.js"></script>' . PHP_EOL;
                        $theme_text .= '<script type="text/javascript" src="ext/jquery/ui/jquery-ui-' . $jquery_ui_version . '.min.js"></script>' . PHP_EOL;
                        $theme_text .= '<link rel="stylesheet" type="text/css" href="ext/jquery/ui/' . $theme_name . '/jquery-ui-' . $jquery_ui_version . '.min.css" />' . PHP_EOL;

I have no idea how to resize the small images. It seems this is hardcoded in the photoset grid script. You should post this in the adequate forum.

Remember this is the kiss thumbnail forum.

Link to comment
Share on other sites

Done, it's ok. But now when I change the theme, nothing happen.

@@cramli,

 

Download here the newest version of theme switcher for OsC 2.3.4:

http://addons.oscommerce.com/info/7663

Link to comment
Share on other sites

Thank you, this is the version I allready have and also installed. Maybe I will go back with all the steps (upgrading 2.3.3.4 to 2.3.4) and do a new installation, inclusiv the files and with the comment you told me. What you mean?

Link to comment
Share on other sites

Thank you, this is the version I allready have and also installed. Maybe I will go back with all the steps (upgrading 2.3.3.4 to 2.3.4) and do a new installation, inclusiv the files and with the comment you told me. What you mean?

You should post the problem in the correct forum for theme switcher. I never used this add-on.

http://www.oscommerce.com/forums/topic/367934-addon-theme-switcher/

Edited by raiwa
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...