Call-back icon  Sales: Call 877.832.5289 (N America)|310.295.4144 (International)

Magento

eCommerce Software for Online Growth

Magento Forum

   
Page 3 of 3
new lightbox tutorial in wiki
 
lisali
Guru
 
Avatar
Total Posts:  459
Joined:  2008-04-28
London, UK
 

Ok - this works.

However - a couple of very important tips:

1. Image paths - use absolute image paths first, to see if it works, then go to relative.
2. The code that needs to be added in step 4 of the tutorial into app/design/frontend/default/default/layout/page.xml MUST go under the FIRST
<block type="page/html_head" name="head" as="head">

as there are two of them. The first one is around line 30.

3. The code above MUST go AFTER
<action method="addJs"><script>prototype/prototype.js</script></action>

otherwise it will not work.

Finally got it - after hours of...well, you don’t want to know!
Thanks!
Lisa
smile

 Signature 

ExtraCall.com - UK Telecommunications & VOIP

 
Magento Community Magento Community
Magento Community
Magento Community
 
pixelpusher
Member
 
Avatar
Total Posts:  62
Joined:  2008-04-23
SoCal
 

I got this working and its great!

However, there seems to be some conflicting javascript. When I use lightbox, my “checkout” form button doesn’t function from the sidebar (sidebar.phtml) also my “add to cart” buttons don’t function from the category view. Can anyone else confirm this?

I downloaded lightbox from the wiki link (lightbox2.03.3.zip) and im running 1.0.19870

EDIT: tried it on another installation and it worked out great. I recommend replacing page.xml and media.phtml with the originals and try again to anyone having the same issues.

 
Magento Community Magento Community
Magento Community
Magento Community
 
nafnaf1000
Sr. Member
 
Total Posts:  119
Joined:  2008-02-21
 

Thanks all for working on this,

Any one how to put Magentos “images zoom (slidding bar)” in to rhe lightbox????

 
Magento Community Magento Community
Magento Community
Magento Community
 
gdoteof
Jr. Member
 
Total Posts:  22
Joined:  2008-05-21
 

that’s a great tip, butting the lightbox.js after prototype.  that should definitely be added to the wiki.

also, i had to reset my cache in order to get this to work.  but now it works great:

http://www.amalgamated-store.com/band-instruments/cello.html

 
Magento Community Magento Community
Magento Community
Magento Community
 
infield
Member
 
Total Posts:  67
Joined:  2007-11-04
San Francisco
 

I would like to have the the “label” text from the individual gallery images appear in the caption as opposed to the product name. We are using the gallery to show color options, it would be nice to have the caption show the color name as defined in the image “label”. 

As far as I can tell, in this code:

<?php foreach ($this->getGalleryImages() as $_image): ?>
   
<li>
     <
a href="<?php echo $this->helper('catalog/image')->init($this->getProduct(), 'image', $_image->getFile()); ?>" rel="lightbox[rotation]" title="<?php echo $_product->getName();?>">
     <
img src="<?php echo $this->helper('catalog/image')->init($this->getProduct(), 'thumbnail', $_image->getFile())->resize(68, 68); ?>" width="68" height="68" alt=""/>
     </
a>
  </
li>
<?php endforeach; ?>

I would like this paramiter

title="<?php echo $_product->getName()

to reference the “label” field from the catalog_product_entity_media_gallery_value table of the associated gallery image.

Can anyone tell me how to replace this value or point me in the right direction?

Thanks

Image Attachments
Picture 9.pngPicture 12.png
 
Magento Community Magento Community
Magento Community
Magento Community
 
Darren E
Member
 
Avatar
Total Posts:  40
Joined:  2008-05-23
The Woodlands, Texas
 

Does this *HAVE* to go into the /default/default folders?
Will this work if I place them to my template files?

Thanks,

Darren

 Signature 

Darren E
Web Design The Woodlands
Pixelbit Studios, LLC.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Flicker
Jr. Member
 
Total Posts:  9
Joined:  2008-02-12
 

I have it setup on my custom template i.e not /skin/frontend/default/default but /skin /frontend/default/custom
And it works great

Gudmundur

 
Magento Community Magento Community
Magento Community
Magento Community
 
pilch
Jr. Member
 
Total Posts:  23
Joined:  2008-02-14
Westcountry, UK
 

Hello.

- I don’t see the Close or loading images which in turn means that to close lightbox I need to click away from the image currently loaded into view.
- I also seem to have all of my additional images loading in the same dimensions rather than rescaling nicely.

Visit the test site

Regards,

Rich.

 
Magento Community Magento Community
Magento Community
Magento Community
 
lisali
Guru
 
Avatar
Total Posts:  459
Joined:  2008-04-28
London, UK
 

Rich,

Your image paths are incorrect. For example, your “close” button tries to fetch the image from:

http://www.theofficials.co.uk/magento/skin/frontend/default/Modern/images/lightbox/closelabel.gif

Do you have that file there?

 Signature 

ExtraCall.com - UK Telecommunications & VOIP

 
Magento Community Magento Community
Magento Community
Magento Community
 
pilch
Jr. Member
 
Total Posts:  23
Joined:  2008-02-14
Westcountry, UK
 
lisali - 29 August 2008 06:00 AM

Rich,

Your image paths are incorrect. For example, your “close” button tries to fetch the image from:

http://www.theofficials.co.uk/magento/skin/frontend/default/Modern/images/lightbox/closelabel.gif

Do you have that file there?

Hi LisaLi.

No I don’t have the images there, I have them in default.

I have the Modern theme installed but as far as I was aware I was running on th edefault theme.

Regards,

Rich.

 
Magento Community Magento Community
Magento Community
Magento Community
 
MachineRebel
Jr. Member
 
Total Posts:  4
Joined:  2007-12-28
 

Thank you so much for the tutorial.

Quick question: Could you tell me how to enable lightbox for the main product image.  Right now it just works for the smaller “More Views” images.  Currently, I can double-click the main product image and it expands to fill the browser window.  I’d like to disable that functionality and replace it with lightbox.

Thanks!
-Mike

 
Magento Community Magento Community
Magento Community
Magento Community
 
daveman123
Jr. Member
 
Total Posts:  5
Joined:  2008-10-31
 

What version of the LIghtbox is this for? I Dl’ed 2.04 and got stuck at the CSS editing because lightbox.css cannot find anything that I need to replace.  Can anyone just make it simpler and upload the lightbox.css file?

 
Magento Community Magento Community
Magento Community
Magento Community
 
jemoon
Member
 
Avatar
Total Posts:  46
Joined:  2008-09-30
Gdansk, Poland
 

Hi,
does anybody know what should I do to get base images displayed in lightbox I know that I should change this code:

<class="product-image-zoom"><img src="<?php echo $this->helper('catalog/image')->init($_product, 'image')?>" alt="<?php echo $this->htmlEscape($_product->getName()) ?>" /></p>
but the simplest way of doing it:
<class="product-image-zoom"><a href="<?php echo $this->helper('catalog/image')->init($_product, 'image') ?>" rel="lightbox[rotation]"><img src="<?php echo $this->helper('catalog/image')->init($_product, 'image')?>" alt="<?php echo $this->htmlEscape($_product->getName()) ?>" /></a></p>
doesn’t work :/

 Signature 

Wszystkich zainteresowanych zapraszam na Nieoficjalne, Polskie Forum Magento

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top
Page 3 of 3
 
Sales: Call 877.832.5289 (North America) 310.295.4144 (International)
© Copyright 2008 Varien. Magento, eCommerce software, is a trademark of Irubin Consulting Inc. DBA Varien
Privacy Policy|Terms of Service
Magento Community Count
53184 users|730 users currently online|107214 forum posts