This repository is private.
All pages are served over SSL and all pushing and pulling is done over SSH.
No one may fork, clone, or view it unless they are added as a member.
Every repository with this icon (
) is private.
Every repository with this icon (
This repository is public.
Anyone may fork, clone, or view it.
Every repository with this icon (
) is public.
Every repository with this icon (
Generate
require 'rubygems'
require 'nokogiri'
@builder = Nokogiri::HTML::Builder.new do |doc|
doc.html {
doc.head {
doc.script {
doc.text "alert('hello world');"
}
doc.style {
doc.text "div#thing { background: red; }"
}
doc.title "Awesome Page"
}
doc.body {
doc.div.rad.thing! {
doc.h1 "This is an h1"
doc.text "This is a div with class 'rad' and id 'thing'"
doc.div( :some_attribute => 'foo' ) {
doc.p "This is an awesome paragraph!"
}
}
}
}
end
puts @builder.to_html






