Opencart Türkiye Destek   Sitesi ,E-Ticaret Yazılımı  Destek Paylaşım Forumu
Ürün Detayda lightbox Görüntüleme Sorunum - Yazdırılabilir Sürüm

+- Opencart Türkiye Destek Sitesi ,E-Ticaret Yazılımı Destek Paylaşım Forumu (http://www.tr-opencart.com)
+-- Forum: Genel Konular (/forum-genel-konular)
+--- Forum: Genel Destek Konuları (/forum-genel-destek-konulari)
+--- Konu: Ürün Detayda lightbox Görüntüleme Sorunum (/Konu-urun-detayda-lightbox-goruntuleme-sorunum%20)



Ürün Detayda lightbox Görüntüleme Sorunum - e-ticaretdersleri - 08-03-2012 03:54 PM

herkese hayırlı günler ve işler dilerim benim sorunum siteye lightbox ekledim güzel çalışıyor jquerycarousel ile birleştir sorun çıkmadı ama ürün detaya gelip resme tıkayıp sonra carouseldeki resmin üzerine gelince açılan resimdeki yolu görüp ürün detaydaki resimde gösteriyor

hata yeri


jjcarousel.inc içerisindeki kod

PHP Kod:
<?php if ($this->request->get['product_id']) { ?>
<!--
//-----------------------------------------
// Product: jCarousel (Product) OpenCart-tr.com 
// Yapimci: mirac
// Web Sitesi: http://www.analizburo.com
//-----------------------------------------
-->
<link rel="stylesheet" type="text/css" href="catalog/view/javascript/jquery/jcarousel/lib/jquery.jcarousel.css" />
<link rel="stylesheet" type="text/css" href="catalog/view/javascript/jquery/jcarousel/skins/tango/skin.css" />
<script type="text/javascript" src="catalog/view/javascript/jquery/jcarousel/lib/jquery.jcarousel.pack.js"></script>
<script type="text/javascript">
// Get main product image dimensions from db
var imageWidth = '<?php echo $this->config->get("config_image_thumb_width"); ?>';
var imageHeight = '<?php echo $this->config->get("config_image_thumb_height"); ?>';

$(document).ready(function(){
    
    // Start jCarousel
    $('#mycarousel').jcarousel();
    
    $("#mycarousel li img").each(function(){
        $(this).hover(function () {
        
            var imgSrc = $(this).attr('src'); // get img src
            var imgPath = imgSrc.substring(0, imgSrc.lastIndexOf('/') + 1); // get img path without filename
            var imgName = imgSrc.substring(imgSrc.lastIndexOf('/') + 1, imgSrc.lastIndexOf('-')); // get img file name without extension (eg: image_1)
            var imgExt = imgSrc.substring(imgSrc.lastIndexOf('.'), imgSrc.length); // get img file extension (eg: .jpg)
             var newSrc = imgPath + imgName + '-' + imageWidth + 'x' + imageHeight + imgExt;
              var newhref = $(this).parent().attr('href');
              
            $('#image').attr({
                        src: newSrc,
                        title: $(this).attr('title'),
                        alt: $(this).attr('alt')
            });
            
            $('#image').parent().attr('href', newhref);
        });
    });
    
    // Remove the images tab
    $("#tab_image").remove();
    $('div.tabs a').each(function(){
        if ($(this).attr('tab') == '#tab_image') {
            $(this).remove();
        }
    });

});
</script>

<?php 
// Pre-load needed image sizes for all additional images
$this->load->model('catalog/product');
$this->load->model('tool/image');
$product_info $this->model_catalog_product->getProduct($this->request->get['product_id']); 
if (
$product_info['image']) {
    
$image $product_info['image'];
} else {
    
$image 'no_image.jpg';
}    
//$thumb1 = $this->model_tool_image->resize($image, $this->config->get('config_image_additional_width'), $this->config->get('config_image_additional_height'));
$thumb1 = (class_exists('HelperImage')) ? HelperImage::resize($image$this->config->get('config_image_additional_width'), $this->config->get('config_image_additional_height')) : $this->model_tool_image->resize($image$this->config->get('config_image_additional_width'), $this->config->get('config_image_additional_height'));
$results $this->model_catalog_product->getProductImages($this->request->get['product_id']);
foreach (
$results as $result) {
    (
class_exists('HelperImage')) ? HelperImage::resize($result['image'], $this->config->get('config_image_thumb_width'), $this->config->get('config_image_thumb_width')) : $this->model_tool_image->resize($result['image'], $this->config->get('config_image_thumb_width'), $this->config->get('config_image_thumb_width'));
}
?>
<?php 
if ($images) { ?>
<div id="wrap">
  <ul id="mycarousel" class="jcarousel-skin-tango">
    <li><a href="<?php echo $popup?>"  rel="prettyPhoto[pp_gal]" title="<?php echo $heading_title?>"><img src="<?php echo $thumb1?>"  alt="<?php echo $heading_title?>" /></a></li>
    <?php foreach ($images as $image) { ?>
    <li><a  href="<?php echo $image['popup']; ?>"rel="prettyPhoto[pp_gal]" title="<?php echo $heading_title?>"><img src="<?php echo $image['thumb']; ?>"  alt="<?php echo $heading_title?>" /></a></li>
    <?php ?>
  </ul>
</div>
<?php ?>

<?php ?>



Cvp: Ürün Detayda lightbox Görüntüleme Sorunum - nokta - 08-03-2012 04:22 PM

Düzgün görünüyor bende, bir sıkıntı görmedim sayfada.

Yanlız siten epeyce yavaşlamış bir db bakımı yapman lazım gibi sayfa yüklemesi çok uzun sürüyor.

Kolay gelsin.