X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (https://forum.x-cart.com/forumdisplay.php?f=20)
-   -   Lightbox JS v2.0 implementation (https://forum.x-cart.com/showthread.php?t=23858)

MrBungle 07-05-2008 06:24 PM

Re: Lightbox JS v2.0 implementation
 
I really wanted lightbox on my clients site but couldn't sort through all the x-cart specific stuff so I just hand coded it in.

http://www.rotopax.com/photos-rotopax-fuel-pack-atv-fuel-gas-container-gas-can-fuel-pg-14.html

The only pain is adding images (which I need to do) is all done by hand...

So after 22 pages of lightbox stuff, is there a complete, working mod for this?

mike@eternitywebdev.com 07-22-2008 06:36 AM

Re: Lightbox JS v2.0 implementation
 
Quote:
Originally Posted by OpheliaPayne

3. Instead of text links for the detailed images, I want 150x150 images below the product page that you can click on and see the full version in the popup window.


To do this, use this code in your thickbox_productpage.tpl:
{if $images ne ""}
<div style="white-space:nowrap;color:#D90000;font-weight:bold;padding:2px;margin:10px 0 4px;">{$lng.lbl_detailed_images} &not;</div>
<table width="250"><tr>
{section name=image loop=$images}
<td>
{if $images[image].avail eq "Y"}
{if $images[image].tmbn_url}
<div style="white-space: nowrap;padding:0 0 1px 3px;"><a href="{$images[image].tmbn_url}" title=" {$images[image].alt|escape}" class="thickbox" rel="lightbox_detailed"><img src="{$images[image].tmbn_url}" width="150" style="border:0;" alt="{$lng.lbl_click_to_enlarge|escape}" /> {$images[image].alt|escape}{if $images[image].alt|escape eq ""} {$lng.lbl_image} {math equation="value+1" value=$smarty.section.image.index}{/if}</a></div>
{else}
<div style="white-space: nowrap;padding:0 0 1px 3px;"><a href="{$xcart_web_dir}/image.php?id={$images[image].imageid}&amp;type=D" title=" {$images[image].alt|escape}" class="thickbox" rel="lightbox_detailed"><img src="{$SkinDir}/thickbox/files/zoom.gif" style="border:0;" alt="{$lng.lbl_click_to_enlarge|escape}" /> {$images[image].alt|escape}{if $images[image].alt|escape eq ""} {$lng.lbl_image} {math equation="value+1" value=$smarty.section.image.index}{/if}</a></div>
{/if}
{/if}
</td>
{/section}</tr>
</table>
<script type="text/javascript" src="{$SkinDir}/thickbox/files/jquery-compressed.js"></script>
<script type="text/javascript" src="{$SkinDir}/thickbox/files/thickbox.js"></script>
<style type="text/css" media="all">@import "{$SkinDir}/thickbox/files/thickbox.css";</style>
{/if}

End Quote.

When I use this code I do get thumbnails rather than text links for my detailed images. Unfortunately I seem to lose the gif loading image and when you go from image to image it's a little jumpy without the loader.

Does anyone have a solid fix for adding thumbnails for the detailed images rather than links? I've searched this thread extensively and this was the best fix I found but it still has some issues. Let me know, thanks!


AG9V 07-28-2008 10:02 AM

Re: Lightbox JS v2.0 implementation
 
I just downloaded this mod, but can't seem to get it working with 4.1.10

The installation instructions are very vague with respect to which product.tpl file to modify

Quote:

INSTALLATION
------------
1. Copy thickbox folder to skin1 directory.

2. The same file(product.tpl), add following code right after product_thumbnail line(after {/if}):
{include file="thickbox/thickbox_productpage.tpl" }

3. The same file(product.tpl), comment this out with a {* *}:

{if $active_modules.Detailed_Product_Images ne "" && ($config.Detailed_Product_Images.det_image_popup ne 'Y' || $js_enabled ne 'Y')}
<p />
{include file="modules/Detailed_Product_Images/product_images.tpl" }
{/if}

From reading this thread, it appears that the first instance of product.tpl to edit is /skin1/main/product.tpl, and the second instance is /skin1/customer/main.tpl.

Also from reading this thread, it appears that the "Detailed Product Images" module must be checked and its two configuration options:

" Display detailed images in a popup window" and "Switch detailed images in a popup window without page reloading (using the dynamic image loading)" must be unchecked.

Lastly, the desired images must be stored in the file system, not the database.

Are the above conclusions correct?

AG9V 07-29-2008 09:07 AM

Re: Lightbox JS v2.0 implementation
 
Figured it out. The first instance if product.tpl is /skin1/main/product.tpl

Works great in 4.1.10!

mm99 08-26-2008 02:08 PM

Re: Lightbox JS v2.0 implementation
 
I just nstalled this mod with 4.1.10.but i dont have detailed image .how can i make that works ,just clicking thumbnail.
thanks

Mudjocky 11-01-2008 08:54 PM

Re: Lightbox JS v2.0 implementation
 
I've installed this and it's working fine...however the page is now aligned 'left' on the pages that have the lightbox installed on the with the detailed images. How can I fix this..also...how can I keep the additional text under the thumbnail? I'm new at all this so thanks for your help.

Link to example of page AtoZ Fabrication

rvcapital 11-15-2008 06:22 AM

Re: Lightbox JS v2.0 implementation
 
You say that this works with 4.0.x? I would love to use this addon on my 4.0.18 installation. Do you have the files?

bedstar 11-17-2008 07:57 AM

Re: Lightbox JS v2.0 implementation
 
Hi

Great Mod. I have got it installed and its working fine, anyone know how i can remove the looping image thumbnails? All i want is for someone to click on the main image not to have smaller thumbnails for users to click on

Any help would be great

John
xcart 4.0x

ianfranklin 11-28-2008 01:08 PM

Re: Lightbox JS v2.0 implementation
 
Bedstar,

I wanted to complement you on your site. It looks great. I was looking at you detailed image pop-up mod and I think its great. I like how you modded it to make the box load up without all the box auto-resizing and I like the previous/next links. Is there anyway I could get you share that mod? Thats what I've been looking for.

xtech 03-08-2011 02:22 AM

Re: Lightbox JS v2.0 implementation
 
Hi,

Is it possible to Creation of a 'registration box' with lightbox effect after the home page loads with email address and mobile ph number fields in 4.3.1??


All times are GMT -8. The time now is 07:31 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.