Skip to content

Commit

Permalink
Use HTML5 elements where appropriate.
Browse files Browse the repository at this point in the history
  • Loading branch information
funkaoshi committed Jan 4, 2010
1 parent 442d339 commit 14c7757
Show file tree
Hide file tree
Showing 9 changed files with 36 additions and 34 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Original file line Diff line number Diff line change
@@ -1 +1,2 @@
old cache
tmp
4 changes: 1 addition & 3 deletions config.ru
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@ Sinatra::Base.set(:env, :production);
use Rack::Cache, use Rack::Cache,
:verbose => true, :verbose => true,
:metastore => "file:cache/meta", :metastore => "file:cache/meta",
:entitystore => "file:cache/body", :entitystore => "file:cache/body"
:allow_reload => false,
:allow_revalidate => false


require 'groupviewer.rb' require 'groupviewer.rb'
run Sinatra::Application run Sinatra::Application
2 changes: 1 addition & 1 deletion groupviewer.rb
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def nav_links
else else
"<a class='prev_page' href='/group/#{@group_id}?pg=#{@page-1}'>Prev</a>" "<a class='prev_page' href='/group/#{@group_id}?pg=#{@page-1}'>Prev</a>"
end end
"<span class='nav'>#{prev_link} | #{@page} of #{@pages} | #{next_link}</span>" "#{prev_link} | #{@page} of #{@pages} | #{next_link}"
end end
end end


Expand Down
Empty file added public/favicon.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file added public/favicon.ico
Empty file.
3 changes: 2 additions & 1 deletion public/site.css
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ body {
padding:0; padding:0;
} }


#footer { footer {
color: #777; color: #777;
margin-top:40px; margin-top:40px;
} }
Expand Down Expand Up @@ -40,6 +40,7 @@ a {
text-decoration: none; text-decoration: none;
font-weight: bold; font-weight: bold;
color: #222; color: #222;
border: 0;
} }


a:hover { a:hover {
Expand Down
29 changes: 15 additions & 14 deletions views/group.haml
Original file line number Original file line Diff line number Diff line change
@@ -1,29 +1,30 @@
!!! 5 !!! 5
%html %html
%head %head
%meta(http-equiv='Content-Type' content='text/html; charset=utf-8') %meta(charset='utf-8')
%meta(name='viewport' content='width=600') %meta(name='viewport' content='width=600')
%title GROUP VIEWQVZ :: #{@name} %title GROUP VIEWQVZ :: #{@name}
%link(rel='stylesheet' href='/site.css' type='text/css' media='screen' title='default style sheet') %link(rel='stylesheet' href='/site.css' type='text/css' media='screen' title='default style sheet')
%script(type='text/javascript' src='http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js') %script(type='text/javascript' src='http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js')
%script(type='text/javascript' src='/paging_keys.js') %script(type='text/javascript' src='/paging_keys.js')
%body %body
#content #content
#header %header
%h1 Viewing #{@name} %h1 Viewing #{@name}
%p %form(action='/group' method='post')
%form(action='/group' method='post') %p
%label(for='url') View another group? %label(for='searchbox') View another group?
%input#searchbox(type='text' name='url' value='http://flickr.com/groups/onthestreet') %input#searchbox(type='text' name='url' value='http://flickr.com/groups/onthestreet')
%input#ok(type='submit' value='OK') %input#ok(type='submit' value='OK')
#images #images
%p= nav_links %nav
%p j/k keys will move between photos (and pages) %p= nav_links
%table %p j/k keys will move between photos (and pages)
- @sequence.each do |img| - @sequence.each do |img|
.photo.hentry{:id => img.id} .photo.hentry{:id => img.id}
%a{:href => img.flickr_url}> %a{:href => img.flickr_url}>
%img{:src => img.img_url}> %img{:src => img.img_url}>
%p= nav_links %nav
#footer %p= nav_links
%footer
%p Site designed and built by <a href="http://funkaoshi.com">Ramanan Sivaranjan</a>. %p Site designed and built by <a href="http://funkaoshi.com">Ramanan Sivaranjan</a>.
17 changes: 9 additions & 8 deletions views/index.haml
Original file line number Original file line Diff line number Diff line change
@@ -1,31 +1,32 @@
!!! 5 !!! 5
%html %html
%head %head
%meta(http-equiv='Content-Type' content='text/html; charset=utf-8') %meta(charset='utf-8')
%title GROUP VIEWQVZ %title GROUP VIEWQVZ
%link(rel='stylesheet' href='/site.css' type='text/css' media='screen' title='default style sheet') %link(rel='stylesheet' href='/site.css' type='text/css' media='screen' title='default style sheet')
%body %body
#content #content
#header %header
%h1 Flickr Group Viewer %h1 Flickr Group Viewer
#index #index
%p %p
Use Flickr Group Viewer to quickly browse through the photographs in a Use Flickr Group Viewer to quickly browse through the photographs in a
flickr group. Drop the group URL into the form below. You can browse flickr group. Drop the group URL into the form below. You can browse
between photographs (and pages) using the j/k keys on your keyboard. between photographs (and pages) using the j/k keys on your keyboard.
%p %form(action='/group' method='post')
%form(action='/group' method='post') %p
%label(for='url') Flickr Group URL: %label(for='searchbox') Flickr Group URL:
%input#searchbox(type='text' name='url' value='http://flickr.com/groups/onthestreet') %input#searchbox(type='text' name='url' value='http://flickr.com/groups/onthestreet')
%input#ok(type='submit' value='OK') %input#ok(type='submit' value='OK')
%p -#
:markdown %p
:markdown
Example galleries: [Photographs on the Brain][1], [HCSP][2], [La Pura Vida][3], [Your Photo Isn't that Great][4], Contract Killers[5]. Example galleries: [Photographs on the Brain][1], [HCSP][2], [La Pura Vida][3], [Your Photo Isn't that Great][4], Contract Killers[5].
[1]: /group/photographsonthebrain [1]: /group/photographsonthebrain
[2]: /group/onthestreet [2]: /group/onthestreet
[3]: /group/lapuravida [3]: /group/lapuravida
[4]: /group/yousuck [4]: /group/yousuck
[5]: /group/the-hit [5]: /group/the-hit
#footer %footer
%p Site designed and built by <a href="http://funkaoshi.com">Ramanan Sivaranjan</a>. %p Site designed and built by <a href="http://funkaoshi.com">Ramanan Sivaranjan</a>.
12 changes: 6 additions & 6 deletions views/wtf.haml
Original file line number Original file line Diff line number Diff line change
@@ -1,19 +1,19 @@
!!! 5 !!! 5
%html %html
%head %head
%meta(http-equiv='Content-Type' content='text/html; charset=utf-8') %meta(charset='utf-8')
%title GROUP VIEWQVZ :: WTF?! %title GROUP VIEWQVZ :: WTF?!
%link(rel='stylesheet' href='/site.css' type='text/css' media='screen' title='default style sheet') %link(rel='stylesheet' href='/site.css' type='text/css' media='screen' title='default style sheet')
%body %body
#content #content
#header %header
%h1 WTF?! %h1 WTF?!
#index #index
%p Yeah, so something went wrong. Who knows what? Let's not play the blame game. %p Yeah, so something went wrong. Who knows what? Let's not play the blame game.
%p %form(action='/group' method='post')
%form(action='/group' method='post') %p
%label(for='url') View another group? %label(for='searchbox') View another group?
%input#searchbox(type='text' name='url' value='http://flickr.com/groups/onthestreet') %input#searchbox(type='text' name='url' value='http://flickr.com/groups/onthestreet')
%input#ok(type='submit' value='OK') %input#ok(type='submit' value='OK')
#footer %footer
%p Site designed and built by <a href="http://funkaoshi.com">Ramanan Sivaranjan</a>. %p Site designed and built by <a href="http://funkaoshi.com">Ramanan Sivaranjan</a>.

0 comments on commit 14c7757

Please sign in to comment.