views:

1535

answers:

3

Hello,

I'm hoping I can get this question answered here...

I have a client who wants to add a PayPal "Add to Cart" button inside a Lightbox window. I was able to achieve this by placing the PayPal code inside the image title tag.

Not sure if this was the best way, but it worked.

However, here is my problem...

Now when you mouse over the image thumbnail the image title tooltip popup displays the PayPal code. Not good...

Is there a way to disable this feature? Can I tell browsers to not display this popup?

Here is the link (I only applied the code to the first two photos):

http://lancemissionart.com/index.php?Page=gallery&title=fof&gallery=msd

Thanks!

A: 

You should change from using Lightbox to Thickbox (looks like you might be experimenting with it in your code). Lightbox is for images only (even though you've made it work its pretty ugly putting all that in the title tag and pretty wrong), Thickbox will let you include your form.

http://jquery.com/demo/thickbox/

A: 

I would modify lightbox to use a different attribute instead of title, like paypalForm. Modification on line 398 of lightbox.js.

398: imageArray.push(new Array(anchor.getAttribute('href'), anchor.getAttribute('paypalForm')));

The other option would be to only set the title attribute onMouseDown and setting it back to empty string when the lightbox is closed.

Jason Harwig
Awesome! Thanks Jason!!Changing the 'title' attribute to 'paypalForm' worked perfectly.Thanks again!
ChrisD
Hi Jason,I am having another problem with this issue. Can you please read my new question and offer any suggestions?http://stackoverflow.com/questions/960749/problem-with-integrating-paypal-into-lightbox
ChrisD
Never mind Jason. Problem SOLVED!!
ChrisD
A: 

Thickbox it is not maintained any longer!

Guido Lemmens 2