O'Reilly logo

Wicked Cool Ruby Scripts by Steve Pugh

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating a Photo Gallery

Creating a Photo Gallery

createGallery.rb

Electronic photo galleries provide a perfect forum for sharing pictures with friends and family. Stacks of full-size photos aren't very inviting, nor do they stand up by themselves. A nice gallery is needed to present them in the proper way. This is a quick photo gallery script with a clean, simple style. The gallery can be modified and personalized as much as you like. You can get fancy, but for this example, I'll keep it as simple as possible. Familiarity with HTML is helpful but not necessary.

The Code

 require 'RMagick'
 require 'ftools'
 include Magick

 photos_row = 4 table_border ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required