Skip to content

Instantly share code, notes, and snippets.

@rxbynerd
Created April 20, 2012 14:25
Show Gist options
  • Save rxbynerd/2429046 to your computer and use it in GitHub Desktop.
Save rxbynerd/2429046 to your computer and use it in GitHub Desktop.
Basic demonstration of a dynamic web page

This code is running here until I accidentally Holly

# this is a dynamic route
get "/" do
"The time is " + Time.now.inspect
end
# this is a static route
get "/james" do
"i crashed it"
end
require "sinatra"
require "./app.rb"
run Sinatra::Application
thin:
thin start --port 5075 --address 127.0.0.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment