X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Third Party Add-Ons for X-Cart 4 (https://forum.x-cart.com/forumdisplay.php?f=45)
-   -   Thickbox 2.0 implementation (https://forum.x-cart.com/showthread.php?t=27058)

S Parkinson 01-23-2008 12:33 AM

Re: Thickbox 2.0 implementation
 
Hi,
I've installed this Thickbox on my test site, and used the above code to create thumbnails etc rather than text link - thanks a lot for the help given.

However, in Internet Explorer the image is displayed twice (one above the other) whereas in firefox this problem does not occur.

Does anybody else have problems with Internet explorer?

Here is an example:
http://xcart.bpservers.co.uk/xcart/product.php?productid=16126&cat=243&page=1

Maybe i've screwed something up!

Jay

pauldodman 01-23-2008 12:57 AM

Re: Thickbox 2.0 implementation
 
Unless you are using the code I placed above, I believe the problem may be that the other code above is for Thickbox 3, and you are using Thickbox 2.
I have combined my code with that to wrap multiple thumbnails and it works fine.

Code:


{if $images ne ""}
<div style="white-space:nowrap;color:#D90000;font-weight:bold;padding:2px;margin:10px 0 4px;">Click a thumbnail below to Enlarge image...</div>
<table width="250" cellpadding="5" cellspacing="5">
<tr>
{assign var=loop value=1}
{section name=image loop=$images}
 <td>
 {if $images[image].avail eq "Y"}
 <table cellpadding="0" cellspacing="0" border="0">
 <tr>
 <td align="center">
 <a href="{$images[image].tmbn_url}" title="{$images[image].alt|escape}" class="thickbox" rel="lightbox_detailed"><img src="{$images[image].tmbn_url}" width="135" style="border:0;" alt="{$lng.lbl_click_to_enlarge|escape}" />
 </td>
 </tr>
 <tr>
 <td align="center">
 {$images[image].alt|escape}{if $images[image].alt|escape eq ""} {$lng.lbl_image} {math equation="value+1" value=$smarty.section.image.index}{/if}</a>
 </td>
 </tr>
 </table>
 {/if}
{* change the number below for how many images wide you want *}
{if $loop eq 3} </tr><tr> {assign var=loop value=0}
{/if}
{assign var=loop value=$loop+1}
{/section}</tr>
</table>
{/if}


sk8conz 01-23-2008 01:24 AM

Re: Thickbox 2.0 implementation
 
The code I posted was tested with Thickbox 3.1 and seemed to work fine.

Thickbox 2 was not tried

pauldodman 01-23-2008 01:31 AM

Re: Thickbox 2.0 implementation
 
Ah, thought so - the 2 versions are different - so anyone following this thread needs to be careful as it is titled "Thickbox 2.0 implementation".
If you are using v2, then use my code, if v3, use sk8conz's.

S Parkinson 01-23-2008 01:40 AM

Re: Thickbox 2.0 implementation
 
ok thanks, but i can't seem to work out which version of thickbox i have.
I downloaded it from here:
http://www.7dana.com/106.84.0.0.1.0.phtml

Does anybody know which version this is?

Cheers

pauldodman 01-23-2008 01:55 AM

Re: Thickbox 2.0 implementation
 
If you are getting 2 images in IE, then you need to use my code - I would guess you are using Thickbox 2.

S Parkinson 01-23-2008 02:30 AM

Re: Thickbox 2.0 implementation
 
PAULODMAN - many thanks! that solves it!

sk8conz 01-23-2008 12:51 PM

Re: Thickbox 2.0 implementation
 
Quote:

Originally Posted by S Parkinson
ok thanks, but i can't seem to work out which version of thickbox i have.
I downloaded it from here:
http://www.7dana.com/106.84.0.0.1.0.phtml

Does anybody know which version this is?

Cheers


Version 3

jbvideo 02-15-2008 12:25 PM

Re: Thickbox 2.0 implementation
 
I'm spinning my wheels here and not having any luck.

Using version 4.1.9 basically out of the box. No modifications.

I downloaded 7dana's zip file today . Looking at the js file it's Thickbox 3

So I'm not sure what part of 7dana's instructions I'm supposed to follow and what part of sk8conz instructions I'm supposed to follow with thickbox 3 in 4.1.9

maybe a quick step by step could help others too since the main/product.tpl is different in 4.1.9.

here's mine .. which I dont think is the same from others posted earlier in this thread:

{* $Id: product.tpl,v 1.46.2.2 2007/06/04 11:13:13 max Exp $ *}
{capture name=dialog}
<table width="100%">
<tr>
<td valign="top" align="left" width="30%">
{include file="product_thumbnail.tpl" productid=$product.productid image_x=$product.image_x image_y=$product.image_y product=$product.product}
<p />
{if $smarty.get.mode ne "printable"}
<a href="product.php?productid={$product.productid}&a mp;mode=printable" target="_blank"><img src="{$ImagesDir}/print.gif" width="23" height="22" name="print" alt="{$lng.lbl_printable_version|escape}" /></a>
{/if}
</td>
<td valign="top">
<table width="100%" cellpadding="0" cellspacing="0">
<tr>
<td>{$lng.lbl_sku}</td>
<td>{$product.productcode}</td>
</tr>
{if $product.category_text}
<tr>
<td>{$lng.lbl_category}</td>
<td>{$product.category_text}</td>
</tr>
{/if}
{if $usertype eq "A"}
<tr>
<td>{$lng.lbl_vendor}</td>
<td>{$product.provider}</td>
</tr>
{/if}
<tr>
<td>{$lng.lbl_availability}</td>
<td>{if $product.forsale eq "Y"}{$lng.lbl_avail_for_sale}{elseif $product.forsale eq "B"}{$lng.lbl_pconf_avail_for_sale_bundled}{elseif $product.forsale eq "H"}{$lng.lbl_hidden}{else}{$lng.lbl_disabled} {/if}</td>
</tr>
<tr>
<td colspan="2">
<br />
<br />
<span class="Text">{$product.descr}</span>
<br />
<br />
</td>
</tr>
<tr>
<td colspan="2"><b><font class="ProductDetailsTitle">{$lng.lbl_price_info}< /font></b></td>
</tr>
<tr>
<td class="Line" height="1" colspan="2"><img src="{$ImagesDir}/spacer.gif" class="Spc" alt="" /></td>
</tr>
<tr>
<td colspan="2">&nbsp;</td>
</tr>
<tr>
<td width="50%">{$lng.lbl_price}</td>
<td nowrap="nowrap"><font class="ProductPriceSmall">{include file="currency.tpl" value=$product.price}</font></td>
</tr>
<tr>
<td width="50%">{$lng.lbl_in_stock}</td>
<td nowrap="nowrap">{$lng.lbl_items_available|substitu te:"items":$product.avail}</td>
</tr>
<tr>
<td width="50%">{$lng.lbl_weight}</td>
<td nowrap="nowrap">{$product.weight} {$config.General.weight_symbol}</td>
</tr>
</table>
<br />

<table cellspacing="0" cellpadding="0">
<tr>
<td>{include file="buttons/modify.tpl" href="product_modify.php?productid=`$product.produ ctid`"}</td>
<td>&nbsp;&nbsp;</td>
<td>{include file="buttons/clone.tpl" href="process_product.php?mode=clone&productid=`$p roduct.productid`"}</td>
<td>&nbsp;&nbsp;</td>
<td>{include file="buttons/delete.tpl" href="process_product.php?mode=delete&productid=`$ product.productid`"}</td>
</tr>
</table>

</td>
</tr>
</table>
{/capture}
{if $smarty.get.mode eq "printable"}
{include file="dialog.tpl" title=$product.producttitle content=$smarty.capture.dialog extra="width=440"}
{else}
{include file="dialog.tpl" title=$product.producttitle content=$smarty.capture.dialog extra='width="100%"'}
{/if}

sk8conz 02-15-2008 12:29 PM

Re: Thickbox 2.0 implementation
 
Hi,

My install was on a "fresh" 4.1.9 as well.

Follow 7danas install instructions. They work.

Then once that is running you can make the mods I listed


All times are GMT -8. The time now is 11:10 PM.

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