Giter Club home page Giter Club logo

wee_lightbox's Introduction

WeeLightbox
===========

This is a packaged version of lightbox for viewing images on the screen in the popular lightbox design pattern.

Please refer to the lightbox docs for more info. Included are some rails helpers for easy integration into your site. The lightbox javascript is slightly tweaked to configure the location of images and increase the speed of resize.

You can edit lightbox.js to further tweak these if you wish.

Install
=======

If you install from github with rails 2.1+ it will install the files into your public directory. If you install with another method, you may need to issue a recursive copy command manually. 

Also this install script is untested on windows.

Example
=======

In your layout add the following in the head section.

<%= javascript_include_tag :defaults %> 
<%= yield :page_includes %>

In your template:

<%= load_lightbox %>

For each image that you would like to make a lightbox to

<%= lightbox_to('/images/small.gif', '/images/large.gif', "Tasty image caption")

If you want to have more than one lightbox on a page and have the lightbox operate with a slideshow between images..

<%= lightbox_to('/images/small.gif', '/images/large.gif', "Tasty image caption", "group_name")

Where group name needs to be the same for all images in the slideshow.

Copyright (c) 2008 Alastair Brunton, released under the MIT license

wee_lightbox's People

Stargazers

Angus H. avatar Cameron Priest avatar Niels Nuyttens avatar Jej avatar  avatar Clovis avatar  avatar Luis E. Guardiola avatar Will Drew avatar Ravi Duvvuri avatar Alberto Molpeceres avatar Nikolay Kolev avatar Michael Kovacs avatar Theo Mills avatar  avatar Alastair Brunton avatar

Watchers

Alastair Brunton avatar James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.