4 %html{:xmlns => "http://www.w3.org/1999/xhtml", "xml:lang" => "en", :lang => "en"}
\r
10 %script{:type => "text/javascript",
\r
11 :src => "javascripts/script_#{2 + 7}"}
\r
17 <div id="blah">Blah!</div>
\r
22 %html(xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en")
\r
24 %a(title=@title href=href) Stuff
\r
25 %a{:title => @title, :href => href} Stuff
\r
27 %script(type="text/javascript"
\r
28 src="javascripts/script_#{2 + 7}")
\r
30 %html{html_attrs('fr-fr')}
\r
32 %input{:selected => true}
\r
34 %input(selected=true)
\r
37 %span#rice Chicken Fried
\r
38 %p.beans{ :food => 'true' } The magical fruit
\r
39 %h1.class.otherclass#id La La La
\r
42 .article.title Doogie Howser Comes Out
\r
43 .article.date 2006-11-05
\r
45 Neil Patrick Harris would like to dispel any rumors that he is straight
\r
48 %meta{'http-equiv' => 'Content-Type', :content => 'text/html'}/
\r
51 %meta{'http-equiv' => 'Content-Type', :content => 'text/html'}
\r
68 / This is the peanutbutterjelly element
\r
72 %p This doesn't render...
\r
74 %h1 Because it's commented out!
\r
77 %a{ :href => 'http://www.mozilla.com/en-US/firefox/' }
\r
81 -# This is a comment
\r
89 - (42...47).each do |i|
\r
91 %p See, I can count!
\r
102 %p This is #{h quality} cake!
\r
103 %p= "This is the #{h quality} cake!"
\r
106 Look at \\#{h word} lack of backslash: \#{foo}
\r
107 And yon presence thereof: \{foo}
\r
110 $(document).ready(function() {
\r
111 alert(#{@message.to_json});
\r
114 &= "I like cheese & crackers"
\r
116 = "I feel <strong>!"
\r
117 != "I feel <strong>!"
\r
119 I feel <strong>!
\r
129 - flavor = "raspberry"
\r
132 I *really* prefer _#{h flavor}_ jam.
\r