Skip to content
A simple Ruby client library for Panoramio.com
Ruby
Find file
Latest commit 17735b7 @christianhellsten Fixed issues.
Failed to load latest commit information.
lib Fixed issues.
test Fixed issues.
.document first commit
.gitignore Fixed issues.
Gemfile Fixed issues.
Gemfile.lock Fixed issues.
LICENSE first commit
README first commit
README.textile Updated instructions
Rakefile Fixed issues.
VERSION first commit
panoramio.gemspec Fixed issues.

README.textile

Ruby Panoramio

Introduction

The Ruby Panoramio gem is a small library that makes it easy to add photos from Panoramio.com to your site.

With the Ruby Panoramio you can do the following:

  • Generate valid Panoramio API URLs easily
  • Retrieve Panoramio photos in one call

Remember to read the Panoramio API – Terms of Use before using their API.

Installation

Via gemcutter.com:

  
  $ sudo gem install panoramio
  

Usage

  
  require 'rubygems'
  require 'panoramio'
  

Generate a Panoramio API URL

  
  url = Panoramio.url(:minx => 60, 
                      :maxx => 70, 
                      :miny => 10, 
                      :maxy => 20)

  => "http://www.panoramio.com/map/get_panoramas.php?order=popularity&maxx=70&miny=10&set=public&maxy=20&from=0&size=thumbnail&to=20&minx=60"  
  

Retrieve Panoramio photos

  
  photos = Panoramio.photos(:minx => 60, 
                            :maxx => 70, 
                            :miny => 10, 
                            :maxy => 20)

  photo = photos.first

  photo.photo_title
  photo.latitude
  photo.longitude
  

Todo

  • Rename min and max parameters to xyz
  • Validate parameters
  • Rename url method to photos_url?
  • JavaScript widget?

Author

Christian Hellsten (Aktagon Ltd.)

Something went wrong with that request. Please try again.