WebsiteBaker Support (2.8.x) > Bakery Shop
Lightbox not working
Het Artiek:
....
yppds:
Hello,
I seem to have a more complicated problem than imakeart, before.
I have downloaded bakery 1.6 and install it in on a clean installation of WB 283sp1. I am using the round template which as far as I see, contains already the
register_frontend_m odfiles('css');
register_frontend_m odfiles('js');
I have not modified any other file, just add a new product with 3 images. The issue is that I cannot see the other images. LIghtbox opens up, and shows only the main image. There are no prev-next links, only the main image.
I have reproduced the problem on 3-4 different setups. I have just seen from firebug that there might be the case prototype.js is not updated. Even though I have updated, the problem still persists.
Do you have any idea what is happening?
Thanks for your help.
jacobi22:
please check the bakery page settings
Overview (Product-Loop) ->
THUMB is (only) the main image
THUMBS = all images
Item Detail (Footer):
IMAGE = only main image
IMAGES = all images
yppds:
Jacobi22,
Thank you soooo much. You saved me a lot of time and effort.
Can I ask one more thing perhaps you have deal with this. I have replaced [IMAGE] with [THUMB]. This suites me better to have smaller images and when clicked to see the normal image under lightbox.
Is it possible, instead of showing many thumbnails(or images), to show only one and the other images to be visible only when lightbox is played?
What do you think?
Thanks
jacobi22:
its "very simple" ;-)
count the pics in the THUMBS-Array, give only the first THUMB the standard css-class and the otherones a new CSS-Class and set this pictures to display: none;
thats all :-D
BUT the Problem...
the customer doesnt know, that you have more than one picture.....
maybe it helps, if you put a little tip in the template (page settings -> details (footer)
like this
--- Code: ---[THUMBS]
(click here for more pics)
<table border="0" ................>
--- End code ---
the solution:
your frontend.css (for bakery)
build a new class like this
--- Code: ---.mod_bakery_item_thumb_fff {
border: none;
display:none;
}
--- End code ---
view_item.php
1. search this code-lines (original in line 137)
--- Code: ---// Check if the thumb and image directories exist
if (is_dir($thumb_dir) && is_dir($img_dir)) {
--- End code ---
behind this line define your counter with this line
--- Code: ---$ix = 0;
--- End code ---
behind this lines (original in line 173)
--- Code: ---// Make array
$thumb_arr[] = $prepend.$thumb_url.$thumb_file.$thumb_append;
$image_arr[] = $prepend.$img_url.$image_file.$img_append;
--- End code ---
write this:
--- Code: ---$ix++;
--- End code ---
these lines here build the pictures links, if you use lightbox
--- Code: ---if ($setting_lightbox2 == "detail" || $setting_lightbox2 == "all") {
$prepend = "<a href='".$img_url.$image_file."' rel='lightbox[image_".ITEM_ID."]' title='".$img_title."'><img src='";
$thumb_append = "' alt='".$img_title."' title='".$img_title."' class='mod_bakery_item_thumb_f' /></a>";
$img_append = "' alt='".$img_title."' title='".$img_title."' class='mod_bakery_item_img_f' /></a>";
// ...else add thumb/image only
}
--- End code ---
change this lines to
--- Code: ---if ($setting_lightbox2 == "detail" || $setting_lightbox2 == "all") {
if ($ix == 0){
$prepend = "<a href='".$img_url.$image_file."' rel='lightbox[image_".ITEM_ID."]' title='".$img_title."'><img src='";
$thumb_append = "' alt='".$img_title."' title='".$img_title."' class='mod_bakery_item_thumb_f' /></a>";
$img_append = "' alt='".$img_title."' title='".$img_title."' class='mod_bakery_item_img_f' /></a>";}
else{
$prepend = "<a href='".$img_url.$image_file."' rel='lightbox[image_".ITEM_ID."]' title='".$img_title."'><img src='";
$thumb_append = "' alt='".$img_title."' title='".$img_title."' class='mod_bakery_item_thumb_fff' /></a>";
$img_append = "' alt='".$img_title."' title='".$img_title."' class='mod_bakery_item_img_f' /></a>";
}
// ...else add thumb/image only
--- End code ---
the first picture in the thumbs-array has the (original-)class mod_bakery_item_thumb_f
the next pics has the class mod_bakery_item_thumb_fff
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version