Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

lightbox no image just text?

I am currently using light box provided by ... http://leandrovieira.com/projects/jquery/lightbox/

How do I have it so that if I click on a work it brings up the light box and shows text instead of an image? what I want is the terms and conditions shown up in a lightbox.

HTML

<span id="terms"> <a href="">Terms & Conditions</a></span>

jQuery

$(function () {
   $('#terms a').lightBox();
});
like image 897
Beginner Avatar asked Mar 08 '12 13:03

Beginner


3 Answers

It seems like this lightbox plugin only works with images. You should choose another plugin like colorbox: http://jacklmoore.com/colorbox/ It's simple to use and supports iframes and also div elements inside the lightbox.

like image 87
Kres Avatar answered Nov 17 '22 02:11

Kres


I don't think that you can use the plugin as you desire,because that plugin works with images, in any case specify the text you want to appear in the title of the <a>

 <a title="this plugin takes text from here" href="">Terms & Conditions</a>

But i think you will have to find another plugin

like image 21
Nicola Peluchetti Avatar answered Nov 17 '22 00:11

Nicola Peluchetti


I like to use Fancybox to show content in a lightbox. Create a simple HTML page for your terms and conditions then the page will load within the lightbox. If Javascript is disabled they will be taken to the page via the link

http://fancybox.net/

like image 2
MattP Avatar answered Nov 17 '22 00:11

MattP