Sha256: 7e738e9886240b709d3b6fa84dce3214935c73fed9b7d66adbe5441c7e07611b

Contents?: true

Size: 360 Bytes

Versions: 24

Compression:

Stored size: 360 Bytes

Contents

require 'rubygems'
require 'ramaze'

class MainController < Ramaze::Controller
  layout :page
  provide :html => :nagoro

  def index
    @title = "Test"
    "<p>Hello, World!</p>"
  end

  def page
    %q{
<html>
  <head>
    <title>examples/layout</title>
  </head>
  <body>
    <h1>#@title</h1>
    #@content
  </body>
</html>
    }
  end
end

Ramaze.start

Version data entries

24 entries across 24 versions & 4 rubygems

Version Path
Pistos-ramaze-2009.04.08 examples/basic/layout.rb
Pistos-ramaze-2009.06.12 examples/basic/layout.rb
manveru-ramaze-2009.04.01 examples/basic/layout.rb
manveru-ramaze-2009.04.08 examples/basic/layout.rb
manveru-ramaze-2009.04.18 examples/basic/layout.rb
manveru-ramaze-2009.04.22 examples/basic/layout.rb
manveru-ramaze-2009.04 examples/basic/layout.rb
manveru-ramaze-2009.05.08 examples/basic/layout.rb
manveru-ramaze-2009.05 examples/basic/layout.rb
manveru-ramaze-2009.06.04 examples/basic/layout.rb
manveru-ramaze-2009.06.12 examples/basic/layout.rb
manveru-ramaze-2009.06 examples/basic/layout.rb
manveru-ramaze-2009.07 examples/basic/layout.rb
rjspotter-ramaze-2009.06.29 examples/basic/layout.rb
rjspotter-ramaze-2009.06.31 examples/basic/layout.rb
ramaze-2010.03 examples/basic/layout.rb
ramaze-2010.01 examples/basic/layout.rb
ramaze-2009.10 examples/basic/layout.rb
ramaze-2009.07 examples/basic/layout.rb
ramaze-2009.05 examples/basic/layout.rb