From 10ad15861f5eb48c2634c94a62f51eb83e559f66 Mon Sep 17 00:00:00 2001 From: Santiago Pastorino Date: Sat, 3 Apr 2010 18:22:17 -0300 Subject: [PATCH 01/17] :action => "update" used in a non RESTful way confuses --- .../lib/action_view/helpers/form_helper.rb | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/actionpack/lib/action_view/helpers/form_helper.rb b/actionpack/lib/action_view/helpers/form_helper.rb index 6a14f0be9c..6aaaac57a6 100644 --- a/actionpack/lib/action_view/helpers/form_helper.rb +++ b/actionpack/lib/action_view/helpers/form_helper.rb @@ -121,7 +121,7 @@ module ActionView # The generic way to call +form_for+ yields a form builder around a # model: # - # <%= form_for :person, :url => { :action => "update" } do |f| %> + # <%= form_for :person do |f| %> # <%= f.error_messages %> # First name: <%= f.text_field :first_name %>
# Last name : <%= f.text_field :last_name %>
@@ -145,7 +145,7 @@ module ActionView # If the instance variable is not @person you can pass the actual # record as the second argument: # - # <%= form_for :person, person, :url => { :action => "update" } do |f| %> + # <%= form_for :person, person do |f| %> # ... # <% end %> # @@ -177,7 +177,7 @@ module ActionView # possible to use both the stand-alone FormHelper methods and methods # from FormTagHelper. For example: # - # <%= form_for :person, @person, :url => { :action => "update" } do |f| %> + # <%= form_for :person, @person do |f| %> # First name: <%= f.text_field :first_name %> # Last name : <%= f.text_field :last_name %> # Biography : <%= text_area :person, :biography %> @@ -265,7 +265,7 @@ module ActionView # custom builder. For example, let's say you made a helper to # automatically add labels to form inputs. # - # <%= form_for :person, @person, :url => { :action => "update" }, :builder => LabellingFormBuilder do |f| %> + # <%= form_for :person, @person, :builder => LabellingFormBuilder do |f| %> # <%= f.text_field :first_name %> # <%= f.text_field :last_name %> # <%= text_area :person, :biography %> @@ -342,7 +342,7 @@ module ActionView # # === Generic Examples # - # <%= form_for @person, :url => { :action => "update" } do |person_form| %> + # <%= form_for @person do |person_form| %> # First name: <%= person_form.text_field :first_name %> # Last name : <%= person_form.text_field :last_name %> # @@ -404,7 +404,7 @@ module ActionView # # This model can now be used with a nested fields_for, like so: # - # <%= form_for @person, :url => { :action => "update" } do |person_form| %> + # <%= form_for @person do |person_form| %> # ... # <%= person_form.fields_for :address do |address_fields| %> # Street : <%= address_fields.text_field :street %> @@ -433,7 +433,7 @@ module ActionView # with a value that evaluates to +true+, you will destroy the associated # model (eg. 1, '1', true, or 'true'): # - # <%= form_for @person, :url => { :action => "update" } do |person_form| %> + # <%= form_for @person do |person_form| %> # ... # <%= person_form.fields_for :address do |address_fields| %> # ... @@ -461,7 +461,7 @@ module ActionView # the nested fields_for call will be repeated for each instance in the # collection: # - # <%= form_for @person, :url => { :action => "update" } do |person_form| %> + # <%= form_for @person do |person_form| %> # ... # <%= person_form.fields_for :projects do |project_fields| %> # <% if project_fields.object.active? %> @@ -472,7 +472,7 @@ module ActionView # # It's also possible to specify the instance to be used: # - # <%= form_for @person, :url => { :action => "update" } do |person_form| %> + # <%= form_for @person do |person_form| %> # ... # <% @person.projects.each do |project| %> # <% if project.active? %> @@ -485,7 +485,7 @@ module ActionView # # Or a collection to be used: # - # <%= form_for @person, :url => { :action => "update" } do |person_form| %> + # <%= form_for @person do |person_form| %> # ... # <%= person_form.fields_for :projects, @active_projects do |project_fields| %> # Name: <%= project_fields.text_field :name %> @@ -514,7 +514,7 @@ module ActionView # parameter with a value that evaluates to +true+ # (eg. 1, '1', true, or 'true'): # - # <%= form_for @person, :url => { :action => "update" } do |person_form| %> + # <%= form_for @person do |person_form| %> # ... # <%= person_form.fields_for :projects do |project_fields| %> # Delete: <%= project_fields.check_box :_destroy %> From 8f9becb42632d68ae84639b19022ff7d64666a30 Mon Sep 17 00:00:00 2001 From: Santiago Pastorino Date: Sat, 3 Apr 2010 18:34:28 -0300 Subject: [PATCH 02/17] :action => "create" added to form_for with name only to show appropiate behavior --- actionpack/lib/action_view/helpers/form_helper.rb | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/actionpack/lib/action_view/helpers/form_helper.rb b/actionpack/lib/action_view/helpers/form_helper.rb index 6aaaac57a6..9467a0912a 100644 --- a/actionpack/lib/action_view/helpers/form_helper.rb +++ b/actionpack/lib/action_view/helpers/form_helper.rb @@ -121,7 +121,7 @@ module ActionView # The generic way to call +form_for+ yields a form builder around a # model: # - # <%= form_for :person do |f| %> + # <%= form_for :person, :url => { :action => "create" } do |f| %> # <%= f.error_messages %> # First name: <%= f.text_field :first_name %>
# Last name : <%= f.text_field :last_name %>
@@ -145,7 +145,7 @@ module ActionView # If the instance variable is not @person you can pass the actual # record as the second argument: # - # <%= form_for :person, person do |f| %> + # <%= form_for :person, person, :url => { :action => "create" } do |f| %> # ... # <% end %> # @@ -177,7 +177,7 @@ module ActionView # possible to use both the stand-alone FormHelper methods and methods # from FormTagHelper. For example: # - # <%= form_for :person, @person do |f| %> + # <%= form_for :person, @person, :url => { :action => "create" } do |f| %> # First name: <%= f.text_field :first_name %> # Last name : <%= f.text_field :last_name %> # Biography : <%= text_area :person, :biography %> @@ -265,7 +265,7 @@ module ActionView # custom builder. For example, let's say you made a helper to # automatically add labels to form inputs. # - # <%= form_for :person, @person, :builder => LabellingFormBuilder do |f| %> + # <%= form_for :person, @person, :url => { :action => "create" }, :builder => LabellingFormBuilder do |f| %> # <%= f.text_field :first_name %> # <%= f.text_field :last_name %> # <%= text_area :person, :biography %> @@ -354,13 +354,13 @@ module ActionView # ...or if you have an object that needs to be represented as a different # parameter, like a Client that acts as a Person: # - # <%= fields_for :person, @client do |permission_fields| %> + # <%= fields_for :person, @client, :url => { :action => "create" } do |permission_fields| %> # Admin?: <%= permission_fields.check_box :admin %> # <% end %> # # ...or if you don't have an object, just a name of the parameter: # - # <%= fields_for :person do |permission_fields| %> + # <%= fields_for :person, :url => { :action => "create" } do |permission_fields| %> # Admin?: <%= permission_fields.check_box :admin %> # <% end %> # From 8fa3183436cedd7248b47b4aa1fda86e77396c9a Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Sun, 4 Apr 2010 11:06:16 +0200 Subject: [PATCH 03/17] Fixed layouts_and_rendering guide so that it validates XHTML 1.0 Strict --- railties/guides/source/layouts_and_rendering.textile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/railties/guides/source/layouts_and_rendering.textile b/railties/guides/source/layouts_and_rendering.textile index 2cb98e9ee6..1ddba807e0 100644 --- a/railties/guides/source/layouts_and_rendering.textile +++ b/railties/guides/source/layouts_and_rendering.textile @@ -510,7 +510,7 @@ def show end -Make sure you use +and return+ and not +&& return+ because while the former will work, the latter will not due to operator precedence in the Ruby Language. +Make sure you use +and return+ and not +&& return+ because while the former will work, the latter will not due to operator precedence in the Ruby Language. Note that the implicit render done by ActionController detects if +render+ has been called, and thus avoids this error. Therefore, the following will work without errors: @@ -747,7 +747,7 @@ You can even use dynamic paths such as +cache/#{current_site}/main/display+. h5. Linking to CSS Files with +stylesheet_link_tag+ -The +stylesheet_link_tag+ helper returns an HTML ++ tag for each source provided. Rails looks in +public/stylesheets+ for these files by default, but you can specify a full path relative to the document root, or a URL, if you prefer. For example, to include +public/stylesheets/main.cs+: +The +stylesheet_link_tag+ helper returns an HTML +<link>+ tag for each source provided. Rails looks in +public/stylesheets+ for these files by default, but you can specify a full path relative to the document root, or a URL, if you prefer. For example, to include +public/stylesheets/main.cs+: <%= stylesheet_link_tag "main" %> From c52bec77f53a1dc4e3f61fbd45460b99f8f46fb1 Mon Sep 17 00:00:00 2001 From: Xavier Noria Date: Sun, 4 Apr 2010 01:36:12 -0700 Subject: [PATCH 04/17] sanity check arguments in guides generation collapsed into a single WARNINGS flag, EDGE_GUIDES renamed to EDGE to be coherent with the rest, preamble revised --- railties/guides/rails_guides/generator.rb | 47 +++++++++++------------ 1 file changed, 23 insertions(+), 24 deletions(-) diff --git a/railties/guides/rails_guides/generator.rb b/railties/guides/rails_guides/generator.rb index 3d48d6b708..1454aed6e4 100644 --- a/railties/guides/rails_guides/generator.rb +++ b/railties/guides/rails_guides/generator.rb @@ -9,27 +9,23 @@ # # Some arguments may be passed via environment variables: # -# WARN_BROKEN_LINKS -# Internal references (anchors) are checked. If a reference is broken -# levenshtein distance is used to suggest an existing one. This is useful -# since IDs are generated by Textile from titles and thus rewordings alter -# them. +# WARNINGS +# If you are writing a guide, please work always with WARNINGS=1. Users can +# generate the guides, and thus this flag is off by default. # -# WARN_DUPLICATE_HEADERS -# Warns about duplicate IDs in headers. Please do resolve them, if any, -# so guides are valid XHTML. +# Internal links (anchors) are checked. If a reference is broken levenshtein +# distance is used to suggest an existing one. This is useful since IDs are +# generated by Textile from headers and thus edits alter them. # -# This check only happens if WARN_BROKEN_LINKS is also active. -# -# EDGE_GUIDES -# Set to "1" to indicate edge guides are generated. +# Also detects duplicated IDs. They happen if there are headers with the same +# text. Please do resolve them, if any, so guides are valid XHTML. # # ALL -# Generate all guides. - +# Set to "1" to force the generation of all guides. +# # ONLY -# If you want to generate only one or a set of guides. -# Prefixes are enough: +# Use ONLY if you want to generate only one or a set of guides. Prefixes are +# enough: # # # generates only association_basics.html # ONLY=assoc ruby rails_guides.rb @@ -39,9 +35,12 @@ # # generates only # ONLY=assoc,migrations ruby rails_guides.rb # -# Note that if you are working on a guide, generation will -# by default process only that one, so ONLY is rarely used -# nowadays. +# Note that if you are working on a guide generation will by default process +# only that one, so ONLY is rarely used nowadays. +# +# EDGE +# Set to "1" to indicate generated guides should be marked as edge. This +# inserts a badge and changes the preamble of the home page. # # --------------------------------------------------------------------------- @@ -85,7 +84,7 @@ module RailsGuides end def set_edge - @edge = ENV['EDGE_GUIDES'] == '1' + @edge = ENV['EDGE'] == '1' end def generate_guides @@ -97,11 +96,11 @@ module RailsGuides def guides_to_generate guides = Dir.entries(source_dir).grep(GUIDES_RE) - ENV.key?("ONLY") ? select_only(guides) : guides + ENV.key?('ONLY') ? select_only(guides) : guides end def select_only(guides) - prefixes = ENV["ONLY"].split(",").map(&:strip) + prefixes = ENV['ONLY'].split(",").map(&:strip) guides.select do |guide| prefixes.any? {|p| guide.start_with?(p)} end @@ -138,7 +137,7 @@ module RailsGuides result = view.render(:layout => 'layout', :text => textile(body)) - warn_about_broken_links(result) if ENV.key?("WARN_BROKEN_LINKS") + warn_about_broken_links(result) if ENV['WARNINGS'] == '1' end f.write result @@ -229,7 +228,7 @@ module RailsGuides anchors = Set.new html.scan(/ Date: Sun, 4 Apr 2010 11:28:25 +0200 Subject: [PATCH 05/17] Fixing credits page so that it validates XHTML 1.0 Strict and adding myself to it --- railties/guides/images/jaimeiniesta.jpg | Bin 0 -> 11913 bytes railties/guides/source/credits.html.erb | 28 ++++++++++++++---------- 2 files changed, 16 insertions(+), 12 deletions(-) create mode 100644 railties/guides/images/jaimeiniesta.jpg diff --git a/railties/guides/images/jaimeiniesta.jpg b/railties/guides/images/jaimeiniesta.jpg new file mode 100644 index 0000000000000000000000000000000000000000..445f048d927c73a5d47a2584b5ce8629d81e2c58 GIT binary patch literal 11913 zcmbWbbwE^I_vn9MXlX&|MjC19hM~JlDd|)?rKDqkK@d^tZe{=hB_yRwN=i~eX(Z$x z9`Svj-}iU_xcBaveb#5zUOU#_XYX0(Tz$S;0ti(Ul@$RL6cj)S`~X+W1P2Pf4vzsq zS(zQc0ssIPz(+v^Zh@2oW&)5gKv@cA!W(@x$iyfR00orSnF0m{oQ{A2xBLY39E==it=xCO!9czA?Gd3i;71?YHqM0t2c1%v=OH+Mfz z2Rr+xbYQ6v05AYqVSjwc0tfQyhI2t?i2m>RSZDKvhX>`&f7c21&7V270ZkzPV)Ps420Oc(`(J;7Jj{Q_ z1_A9+Zuok=QS<-UfCxbT#c26|{JICWgMOpG2ijo#%LembjP)p zCie~hT~QtpIvzn$UOrJCf&Z-XzjfDl^YwW7i2z{p+6gdSw?%U!v&sJGH5{DWT!HI} z`@07y!Fqq@@LG)ufa?dAUZ-oi-VZup!)PF5f@}mbI>>k+KLi=$M(+$V<_$jq84Kj= zG5Ldx1J(cq5C&cdZfs&fCIo9->#q|L*uyo`gPl`=Hmo40fQnF%@j-3^ISl0MetSTU zylHa+%*Z0~X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underloy', 'mgunderloy') do %> -

Mike Gunderloy is a consultant with ActionRails. He brings 25 years of experience in a variety of languages to bear on his current work with Rails. His near-daily links and other blogging can be found at A Fresh Cup and he twitters too much.

+ Mike Gunderloy is a consultant with ActionRails. He brings 25 years of experience in a variety of languages to bear on his current work with Rails. His near-daily links and other blogging can be found at A Fresh Cup and he twitters too much. <% end %> <%= author('Pratik Naik', 'lifo') do %> -

Pratik Naik is a Ruby on Rails consultant with ActionRails and also a member of the Rails core team. He maintains a blog at has_many :bugs, :through => :rails and has an active twitter account.

+ Pratik Naik is a Ruby on Rails consultant with ActionRails and also a member of the Rails core team. He maintains a blog at has_many :bugs, :through => :rails and has an active twitter account. <% end %> <%= author('Xavier Noria', 'fxn', 'fxn.png') do %> -

Xavier has been into Rails since 2005, he is currently a Rails consultant. Xavier is Rails committer and enjoys combining his passion for Rails and his past life as a proofreader of math textbooks. Oh, he also tweets and can be found everywhere as "fxn".

+ Xavier has been into Rails since 2005, he is currently a Rails consultant. Xavier is Rails committer and enjoys combining his passion for Rails and his past life as a proofreader of math textbooks. Oh, he also tweets and can be found everywhere as "fxn". <% end %>

Rails Guides Designers

<%= author('Jason Zimdars', 'jz') do %> -

Jason Zimdars is an experienced creative director and web designer who has lead UI and UX design for numerous websites and web applications. You can see more of his design and writing at Thinkcage.com or follow him on Twitter.

+ Jason Zimdars is an experienced creative director and web designer who has lead UI and UX design for numerous websites and web applications. You can see more of his design and writing at Thinkcage.com or follow him on Twitter. <% end %>

Rails Guides Authors

<%= author('Frederick Cheung', 'fcheung') do %> -

Frederick Cheung is Chief Wizard at Texperts where he has been using Rails since 2006. He is based in Cambridge (UK) and when not consuming fine ales he blogs at spacevatican.org.

+ Frederick Cheung is Chief Wizard at Texperts where he has been using Rails since 2006. He is based in Cambridge (UK) and when not consuming fine ales he blogs at spacevatican.org. <% end %> <%= author('Tore Darell', 'toretore') do %> -

Tore Darell is an independent developer based in Menton, France who specialises in cruft-free web applications using Ruby, Rails and unobtrusive JavaScript. His home on the internet is his blog Sneaky Abstractions.

+ Tore Darell is an independent developer based in Menton, France who specialises in cruft-free web applications using Ruby, Rails and unobtrusive JavaScript. His home on the internet is his blog Sneaky Abstractions. <% end %> <%= author('Jeff Dean', 'zilkey') do %> -

Jeff Dean is a software engineer with Pivotal Labs.

+ Jeff Dean is a software engineer with Pivotal Labs. <% end %> <%= author('Cássio Marques', 'cmarques') do %> -

Cássio Marques is a Brazilian software developer working with different programming languages such as Ruby, JavaScript, CPP and Java, as an independent consultant. He blogs at /* CODIFICANDO */, which is mainly written in Portuguese, but will soon get a new section for posts with English translation. + Cássio Marques is a Brazilian software developer working with different programming languages such as Ruby, JavaScript, CPP and Java, as an independent consultant. He blogs at /* CODIFICANDO */, which is mainly written in Portuguese, but will soon get a new section for posts with English translation. <% end %> <%= author('James Miller', 'bensie') do %> -

James Miller is a software developer for JK Tech in San Diego, CA. Find me on GitHub, Gmail, Twitter, and Freenode as "bensie".

+ James Miller is a software developer for JK Tech in San Diego, CA. Find me on GitHub, Gmail, Twitter, and Freenode as "bensie". <% end %> <%= author('Emilio Tagua', 'miloops') do %> -

Emilio Tagua —a.k.a. miloops— is an Argentinian entrepreneur, developer, open source contributor and Rails evangelist. Cofounder of Eventioz. He has been using Rails since 2006 and contributing since early 2008. Can be found at gmail, twitter, freenode, everywhere as "miloops".

+ Emilio Tagua —a.k.a. miloops— is an Argentinian entrepreneur, developer, open source contributor and Rails evangelist. Cofounder of Eventioz. He has been using Rails since 2006 and contributing since early 2008. Can be found at gmail, twitter, freenode, everywhere as "miloops". <% end %> <%= author('Heiko Webers', 'hawe') do %> -

Heiko Webers is the founder of bauland42, a German web application security consulting and development company focused on Ruby on Rails. He blogs at the Ruby on Rails Security Project. After 10 years of desktop application development, Heiko has rarely looked back.

+ Heiko Webers is the founder of bauland42, a German web application security consulting and development company focused on Ruby on Rails. He blogs at the Ruby on Rails Security Project. After 10 years of desktop application development, Heiko has rarely looked back. <% end %> <%= author('Mikel Lindsaar', 'raasdnil') do %> -

Mikel Lindsaar has been working with Rails since 2006 and is the author of the Ruby Mail gem and core contributor (he helped re-write Action Mailer's API). Mikel has a blog and tweets. + Mikel Lindsaar has been working with Rails since 2006 and is the author of the Ruby Mail gem and core contributor (he helped re-write Action Mailer's API). Mikel has a blog and tweets. +<% end %> + +<%= author('Jaime Iniesta', 'jaimeiniesta', 'jaimeiniesta.jpg') do %> + Jaime Iniesta works as a Ruby on Rails freelance developer since 2005. He's a member of ProRuby, co-founder of the Spanish Ruby Users Group, member of Spain.rb, and organizer of Conferencia Rails and EuRuKo 2009. Jaime has a blog and tweets. <% end %> From ac8b71cc2032bd352cbe6c078bdff55b236cab8a Mon Sep 17 00:00:00 2001 From: Xavier Noria Date: Sun, 4 Apr 2010 02:30:31 -0700 Subject: [PATCH 06/17] guides assets are now centralized in the assets directory, with standard subdirs --- .../guides/{ => assets}/images/belongs_to.png | Bin .../guides/{ => assets}/images/book_icon.gif | Bin .../guides/{ => assets}/images/bullet.gif | Bin .../guides/{ => assets}/images/challenge.png | Bin .../{ => assets}/images/chapters_icon.gif | Bin .../{ => assets}/images/check_bullet.gif | Bin .../{ => assets}/images/credits_pic_blank.gif | Bin railties/guides/{ => assets}/images/csrf.png | Bin .../images/customized_error_messages.png | Bin .../guides/{ => assets}/images/edge_badge.png | Bin .../{ => assets}/images/error_messages.png | Bin .../{ => assets}/images/feature_tile.gif | Bin .../{ => assets}/images/footer_tile.gif | Bin railties/guides/{ => assets}/images/fxn.png | Bin .../{ => assets}/images/grey_bullet.gif | Bin railties/guides/{ => assets}/images/habtm.png | Bin .../guides/{ => assets}/images/has_many.png | Bin .../{ => assets}/images/has_many_through.png | Bin .../guides/{ => assets}/images/has_one.png | Bin .../{ => assets}/images/has_one_through.png | Bin .../{ => assets}/images/header_backdrop.png | Bin .../{ => assets}/images/header_tile.gif | Bin .../images/i18n/demo_localized_pirate.png | Bin .../images/i18n/demo_translated_en.png | Bin .../images/i18n/demo_translated_pirate.png | Bin .../images/i18n/demo_translation_missing.png | Bin .../images/i18n/demo_untranslated.png | Bin .../guides/{ => assets}/images/icons/README | 0 .../{ => assets}/images/icons/callouts/1.png | Bin .../{ => assets}/images/icons/callouts/10.png | Bin .../{ => assets}/images/icons/callouts/11.png | Bin .../{ => assets}/images/icons/callouts/12.png | Bin .../{ => assets}/images/icons/callouts/13.png | Bin .../{ => assets}/images/icons/callouts/14.png | Bin .../{ => assets}/images/icons/callouts/15.png | Bin .../{ => assets}/images/icons/callouts/2.png | Bin .../{ => assets}/images/icons/callouts/3.png | Bin .../{ => assets}/images/icons/callouts/4.png | Bin .../{ => assets}/images/icons/callouts/5.png | Bin .../{ => assets}/images/icons/callouts/6.png | Bin .../{ => assets}/images/icons/callouts/7.png | Bin .../{ => assets}/images/icons/callouts/8.png | Bin .../{ => assets}/images/icons/callouts/9.png | Bin .../{ => assets}/images/icons/caution.png | Bin .../{ => assets}/images/icons/example.png | Bin .../guides/{ => assets}/images/icons/home.png | Bin .../{ => assets}/images/icons/important.png | Bin .../guides/{ => assets}/images/icons/next.png | Bin .../guides/{ => assets}/images/icons/note.png | Bin .../guides/{ => assets}/images/icons/prev.png | Bin .../guides/{ => assets}/images/icons/tip.png | Bin .../guides/{ => assets}/images/icons/up.png | Bin .../{ => assets}/images/icons/warning.png | Bin .../guides/{ => assets}/images/nav_arrow.gif | Bin .../{ => assets}/images/polymorphic.png | Bin .../{ => assets}/images/posts_index.png | Bin .../{ => assets}/images/rails_guides_logo.gif | Bin .../{ => assets}/images/rails_logo_remix.gif | Bin .../{ => assets}/images/rails_welcome.png | Bin .../{ => assets}/images/session_fixation.png | Bin .../guides/{ => assets}/images/tab_grey.gif | Bin .../guides/{ => assets}/images/tab_info.gif | Bin .../guides/{ => assets}/images/tab_note.gif | Bin .../guides/{ => assets}/images/tab_red.gif | Bin .../guides/{ => assets}/images/tab_yellow.gif | Bin .../guides/{ => assets}/images/tab_yellow.png | Bin .../images/validation_error_messages.png | Bin .../javascripts/code_highlighter.js | 0 .../{files => assets}/javascripts/guides.js | 0 .../javascripts/highlighters.js | 0 .../{files => assets}/stylesheets/main.css | 28 +++++++++--------- .../{files => assets}/stylesheets/print.css | 0 .../{files => assets}/stylesheets/reset.css | 0 .../{files => assets}/stylesheets/style.css | 0 .../{files => assets}/stylesheets/syntax.css | 0 railties/guides/rails_guides/generator.rb | 3 +- railties/guides/source/contribute.textile | 2 +- railties/guides/source/layout.html.erb | 12 ++++---- 78 files changed, 22 insertions(+), 23 deletions(-) rename railties/guides/{ => assets}/images/belongs_to.png (100%) rename railties/guides/{ => assets}/images/book_icon.gif (100%) rename railties/guides/{ => assets}/images/bullet.gif (100%) rename railties/guides/{ => assets}/images/challenge.png (100%) rename railties/guides/{ => assets}/images/chapters_icon.gif (100%) rename railties/guides/{ => assets}/images/check_bullet.gif (100%) rename railties/guides/{ => assets}/images/credits_pic_blank.gif (100%) rename railties/guides/{ => assets}/images/csrf.png (100%) rename railties/guides/{ => assets}/images/customized_error_messages.png (100%) rename railties/guides/{ => assets}/images/edge_badge.png (100%) rename railties/guides/{ => assets}/images/error_messages.png (100%) rename railties/guides/{ => assets}/images/feature_tile.gif (100%) rename railties/guides/{ => assets}/images/footer_tile.gif (100%) rename railties/guides/{ => assets}/images/fxn.png (100%) rename railties/guides/{ => assets}/images/grey_bullet.gif (100%) rename railties/guides/{ => assets}/images/habtm.png (100%) rename railties/guides/{ => assets}/images/has_many.png (100%) rename railties/guides/{ => assets}/images/has_many_through.png (100%) rename railties/guides/{ => assets}/images/has_one.png (100%) rename railties/guides/{ => assets}/images/has_one_through.png (100%) rename railties/guides/{ => assets}/images/header_backdrop.png (100%) rename railties/guides/{ => assets}/images/header_tile.gif (100%) rename railties/guides/{ => assets}/images/i18n/demo_localized_pirate.png (100%) rename railties/guides/{ => assets}/images/i18n/demo_translated_en.png (100%) rename railties/guides/{ => assets}/images/i18n/demo_translated_pirate.png (100%) rename railties/guides/{ => assets}/images/i18n/demo_translation_missing.png (100%) rename railties/guides/{ => assets}/images/i18n/demo_untranslated.png (100%) rename railties/guides/{ => assets}/images/icons/README (100%) rename railties/guides/{ => assets}/images/icons/callouts/1.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/10.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/11.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/12.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/13.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/14.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/15.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/2.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/3.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/4.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/5.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/6.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/7.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/8.png (100%) rename railties/guides/{ => assets}/images/icons/callouts/9.png (100%) rename railties/guides/{ => assets}/images/icons/caution.png (100%) rename railties/guides/{ => assets}/images/icons/example.png (100%) rename railties/guides/{ => assets}/images/icons/home.png (100%) rename railties/guides/{ => assets}/images/icons/important.png (100%) rename railties/guides/{ => assets}/images/icons/next.png (100%) rename railties/guides/{ => assets}/images/icons/note.png (100%) rename railties/guides/{ => assets}/images/icons/prev.png (100%) rename railties/guides/{ => assets}/images/icons/tip.png (100%) rename railties/guides/{ => assets}/images/icons/up.png (100%) rename railties/guides/{ => assets}/images/icons/warning.png (100%) rename railties/guides/{ => assets}/images/nav_arrow.gif (100%) rename railties/guides/{ => assets}/images/polymorphic.png (100%) rename railties/guides/{ => assets}/images/posts_index.png (100%) rename railties/guides/{ => assets}/images/rails_guides_logo.gif (100%) rename railties/guides/{ => assets}/images/rails_logo_remix.gif (100%) rename railties/guides/{ => assets}/images/rails_welcome.png (100%) rename railties/guides/{ => assets}/images/session_fixation.png (100%) rename railties/guides/{ => assets}/images/tab_grey.gif (100%) rename railties/guides/{ => assets}/images/tab_info.gif (100%) rename railties/guides/{ => assets}/images/tab_note.gif (100%) rename railties/guides/{ => assets}/images/tab_red.gif (100%) rename railties/guides/{ => assets}/images/tab_yellow.gif (100%) rename railties/guides/{ => assets}/images/tab_yellow.png (100%) rename railties/guides/{ => assets}/images/validation_error_messages.png (100%) rename railties/guides/{files => assets}/javascripts/code_highlighter.js (100%) rename railties/guides/{files => assets}/javascripts/guides.js (100%) rename railties/guides/{files => assets}/javascripts/highlighters.js (100%) rename railties/guides/{files => assets}/stylesheets/main.css (89%) rename railties/guides/{files => assets}/stylesheets/print.css (100%) rename railties/guides/{files => assets}/stylesheets/reset.css (100%) rename railties/guides/{files => assets}/stylesheets/style.css (100%) rename railties/guides/{files => assets}/stylesheets/syntax.css (100%) diff --git a/railties/guides/images/belongs_to.png b/railties/guides/assets/images/belongs_to.png similarity index 100% rename from railties/guides/images/belongs_to.png rename to railties/guides/assets/images/belongs_to.png diff --git a/railties/guides/images/book_icon.gif b/railties/guides/assets/images/book_icon.gif similarity index 100% rename from railties/guides/images/book_icon.gif rename to railties/guides/assets/images/book_icon.gif diff --git a/railties/guides/images/bullet.gif b/railties/guides/assets/images/bullet.gif similarity index 100% rename from railties/guides/images/bullet.gif rename to railties/guides/assets/images/bullet.gif diff --git a/railties/guides/images/challenge.png b/railties/guides/assets/images/challenge.png similarity index 100% rename from railties/guides/images/challenge.png rename to railties/guides/assets/images/challenge.png diff --git a/railties/guides/images/chapters_icon.gif b/railties/guides/assets/images/chapters_icon.gif similarity index 100% rename from railties/guides/images/chapters_icon.gif rename to railties/guides/assets/images/chapters_icon.gif diff --git a/railties/guides/images/check_bullet.gif b/railties/guides/assets/images/check_bullet.gif similarity index 100% rename from railties/guides/images/check_bullet.gif rename to railties/guides/assets/images/check_bullet.gif diff --git a/railties/guides/images/credits_pic_blank.gif b/railties/guides/assets/images/credits_pic_blank.gif similarity index 100% rename from railties/guides/images/credits_pic_blank.gif rename to railties/guides/assets/images/credits_pic_blank.gif diff --git a/railties/guides/images/csrf.png b/railties/guides/assets/images/csrf.png similarity index 100% rename from railties/guides/images/csrf.png rename to railties/guides/assets/images/csrf.png diff --git a/railties/guides/images/customized_error_messages.png b/railties/guides/assets/images/customized_error_messages.png similarity index 100% rename from railties/guides/images/customized_error_messages.png rename to railties/guides/assets/images/customized_error_messages.png diff --git a/railties/guides/images/edge_badge.png b/railties/guides/assets/images/edge_badge.png similarity index 100% rename from railties/guides/images/edge_badge.png rename to railties/guides/assets/images/edge_badge.png diff --git a/railties/guides/images/error_messages.png b/railties/guides/assets/images/error_messages.png similarity index 100% rename from railties/guides/images/error_messages.png rename to railties/guides/assets/images/error_messages.png diff --git a/railties/guides/images/feature_tile.gif b/railties/guides/assets/images/feature_tile.gif similarity index 100% rename from railties/guides/images/feature_tile.gif rename to railties/guides/assets/images/feature_tile.gif diff --git a/railties/guides/images/footer_tile.gif b/railties/guides/assets/images/footer_tile.gif similarity index 100% rename from railties/guides/images/footer_tile.gif rename to railties/guides/assets/images/footer_tile.gif diff --git a/railties/guides/images/fxn.png b/railties/guides/assets/images/fxn.png similarity index 100% rename from railties/guides/images/fxn.png rename to railties/guides/assets/images/fxn.png diff --git a/railties/guides/images/grey_bullet.gif b/railties/guides/assets/images/grey_bullet.gif similarity index 100% rename from railties/guides/images/grey_bullet.gif rename to railties/guides/assets/images/grey_bullet.gif diff --git a/railties/guides/images/habtm.png b/railties/guides/assets/images/habtm.png similarity index 100% rename from railties/guides/images/habtm.png rename to railties/guides/assets/images/habtm.png diff --git a/railties/guides/images/has_many.png b/railties/guides/assets/images/has_many.png similarity index 100% rename from railties/guides/images/has_many.png rename to railties/guides/assets/images/has_many.png diff --git a/railties/guides/images/has_many_through.png b/railties/guides/assets/images/has_many_through.png similarity index 100% rename from railties/guides/images/has_many_through.png rename to railties/guides/assets/images/has_many_through.png diff --git a/railties/guides/images/has_one.png b/railties/guides/assets/images/has_one.png similarity index 100% rename from railties/guides/images/has_one.png rename to railties/guides/assets/images/has_one.png diff --git a/railties/guides/images/has_one_through.png b/railties/guides/assets/images/has_one_through.png similarity index 100% rename from railties/guides/images/has_one_through.png rename to railties/guides/assets/images/has_one_through.png diff --git a/railties/guides/images/header_backdrop.png b/railties/guides/assets/images/header_backdrop.png similarity index 100% rename from railties/guides/images/header_backdrop.png rename to railties/guides/assets/images/header_backdrop.png diff --git a/railties/guides/images/header_tile.gif b/railties/guides/assets/images/header_tile.gif similarity index 100% rename from railties/guides/images/header_tile.gif rename to railties/guides/assets/images/header_tile.gif diff --git a/railties/guides/images/i18n/demo_localized_pirate.png b/railties/guides/assets/images/i18n/demo_localized_pirate.png similarity index 100% rename from railties/guides/images/i18n/demo_localized_pirate.png rename to railties/guides/assets/images/i18n/demo_localized_pirate.png diff --git a/railties/guides/images/i18n/demo_translated_en.png b/railties/guides/assets/images/i18n/demo_translated_en.png similarity index 100% rename from railties/guides/images/i18n/demo_translated_en.png rename to railties/guides/assets/images/i18n/demo_translated_en.png diff --git a/railties/guides/images/i18n/demo_translated_pirate.png b/railties/guides/assets/images/i18n/demo_translated_pirate.png similarity index 100% rename from railties/guides/images/i18n/demo_translated_pirate.png rename to railties/guides/assets/images/i18n/demo_translated_pirate.png diff --git a/railties/guides/images/i18n/demo_translation_missing.png b/railties/guides/assets/images/i18n/demo_translation_missing.png similarity index 100% rename from railties/guides/images/i18n/demo_translation_missing.png rename to railties/guides/assets/images/i18n/demo_translation_missing.png diff --git a/railties/guides/images/i18n/demo_untranslated.png b/railties/guides/assets/images/i18n/demo_untranslated.png similarity index 100% rename from railties/guides/images/i18n/demo_untranslated.png rename to railties/guides/assets/images/i18n/demo_untranslated.png diff --git a/railties/guides/images/icons/README b/railties/guides/assets/images/icons/README similarity index 100% rename from railties/guides/images/icons/README rename to railties/guides/assets/images/icons/README diff --git a/railties/guides/images/icons/callouts/1.png b/railties/guides/assets/images/icons/callouts/1.png similarity index 100% rename from railties/guides/images/icons/callouts/1.png rename to railties/guides/assets/images/icons/callouts/1.png diff --git a/railties/guides/images/icons/callouts/10.png b/railties/guides/assets/images/icons/callouts/10.png similarity index 100% rename from railties/guides/images/icons/callouts/10.png rename to railties/guides/assets/images/icons/callouts/10.png diff --git a/railties/guides/images/icons/callouts/11.png b/railties/guides/assets/images/icons/callouts/11.png similarity index 100% rename from railties/guides/images/icons/callouts/11.png rename to railties/guides/assets/images/icons/callouts/11.png diff --git a/railties/guides/images/icons/callouts/12.png b/railties/guides/assets/images/icons/callouts/12.png similarity index 100% rename from railties/guides/images/icons/callouts/12.png rename to railties/guides/assets/images/icons/callouts/12.png diff --git a/railties/guides/images/icons/callouts/13.png b/railties/guides/assets/images/icons/callouts/13.png similarity index 100% rename from railties/guides/images/icons/callouts/13.png rename to railties/guides/assets/images/icons/callouts/13.png diff --git a/railties/guides/images/icons/callouts/14.png b/railties/guides/assets/images/icons/callouts/14.png similarity index 100% rename from railties/guides/images/icons/callouts/14.png rename to railties/guides/assets/images/icons/callouts/14.png diff --git a/railties/guides/images/icons/callouts/15.png b/railties/guides/assets/images/icons/callouts/15.png similarity index 100% rename from railties/guides/images/icons/callouts/15.png rename to railties/guides/assets/images/icons/callouts/15.png diff --git a/railties/guides/images/icons/callouts/2.png b/railties/guides/assets/images/icons/callouts/2.png similarity index 100% rename from railties/guides/images/icons/callouts/2.png rename to railties/guides/assets/images/icons/callouts/2.png diff --git a/railties/guides/images/icons/callouts/3.png b/railties/guides/assets/images/icons/callouts/3.png similarity index 100% rename from railties/guides/images/icons/callouts/3.png rename to railties/guides/assets/images/icons/callouts/3.png diff --git a/railties/guides/images/icons/callouts/4.png b/railties/guides/assets/images/icons/callouts/4.png similarity index 100% rename from railties/guides/images/icons/callouts/4.png rename to railties/guides/assets/images/icons/callouts/4.png diff --git a/railties/guides/images/icons/callouts/5.png b/railties/guides/assets/images/icons/callouts/5.png similarity index 100% rename from railties/guides/images/icons/callouts/5.png rename to railties/guides/assets/images/icons/callouts/5.png diff --git a/railties/guides/images/icons/callouts/6.png b/railties/guides/assets/images/icons/callouts/6.png similarity index 100% rename from railties/guides/images/icons/callouts/6.png rename to railties/guides/assets/images/icons/callouts/6.png diff --git a/railties/guides/images/icons/callouts/7.png b/railties/guides/assets/images/icons/callouts/7.png similarity index 100% rename from railties/guides/images/icons/callouts/7.png rename to railties/guides/assets/images/icons/callouts/7.png diff --git a/railties/guides/images/icons/callouts/8.png b/railties/guides/assets/images/icons/callouts/8.png similarity index 100% rename from railties/guides/images/icons/callouts/8.png rename to railties/guides/assets/images/icons/callouts/8.png diff --git a/railties/guides/images/icons/callouts/9.png b/railties/guides/assets/images/icons/callouts/9.png similarity index 100% rename from railties/guides/images/icons/callouts/9.png rename to railties/guides/assets/images/icons/callouts/9.png diff --git a/railties/guides/images/icons/caution.png b/railties/guides/assets/images/icons/caution.png similarity index 100% rename from railties/guides/images/icons/caution.png rename to railties/guides/assets/images/icons/caution.png diff --git a/railties/guides/images/icons/example.png b/railties/guides/assets/images/icons/example.png similarity index 100% rename from railties/guides/images/icons/example.png rename to railties/guides/assets/images/icons/example.png diff --git a/railties/guides/images/icons/home.png b/railties/guides/assets/images/icons/home.png similarity index 100% rename from railties/guides/images/icons/home.png rename to railties/guides/assets/images/icons/home.png diff --git a/railties/guides/images/icons/important.png b/railties/guides/assets/images/icons/important.png similarity index 100% rename from railties/guides/images/icons/important.png rename to railties/guides/assets/images/icons/important.png diff --git a/railties/guides/images/icons/next.png b/railties/guides/assets/images/icons/next.png similarity index 100% rename from railties/guides/images/icons/next.png rename to railties/guides/assets/images/icons/next.png diff --git a/railties/guides/images/icons/note.png b/railties/guides/assets/images/icons/note.png similarity index 100% rename from railties/guides/images/icons/note.png rename to railties/guides/assets/images/icons/note.png diff --git a/railties/guides/images/icons/prev.png b/railties/guides/assets/images/icons/prev.png similarity index 100% rename from railties/guides/images/icons/prev.png rename to railties/guides/assets/images/icons/prev.png diff --git a/railties/guides/images/icons/tip.png b/railties/guides/assets/images/icons/tip.png similarity index 100% rename from railties/guides/images/icons/tip.png rename to railties/guides/assets/images/icons/tip.png diff --git a/railties/guides/images/icons/up.png b/railties/guides/assets/images/icons/up.png similarity index 100% rename from railties/guides/images/icons/up.png rename to railties/guides/assets/images/icons/up.png diff --git a/railties/guides/images/icons/warning.png b/railties/guides/assets/images/icons/warning.png similarity index 100% rename from railties/guides/images/icons/warning.png rename to railties/guides/assets/images/icons/warning.png diff --git a/railties/guides/images/nav_arrow.gif b/railties/guides/assets/images/nav_arrow.gif similarity index 100% rename from railties/guides/images/nav_arrow.gif rename to railties/guides/assets/images/nav_arrow.gif diff --git a/railties/guides/images/polymorphic.png b/railties/guides/assets/images/polymorphic.png similarity index 100% rename from railties/guides/images/polymorphic.png rename to railties/guides/assets/images/polymorphic.png diff --git a/railties/guides/images/posts_index.png b/railties/guides/assets/images/posts_index.png similarity index 100% rename from railties/guides/images/posts_index.png rename to railties/guides/assets/images/posts_index.png diff --git a/railties/guides/images/rails_guides_logo.gif b/railties/guides/assets/images/rails_guides_logo.gif similarity index 100% rename from railties/guides/images/rails_guides_logo.gif rename to railties/guides/assets/images/rails_guides_logo.gif diff --git a/railties/guides/images/rails_logo_remix.gif b/railties/guides/assets/images/rails_logo_remix.gif similarity index 100% rename from railties/guides/images/rails_logo_remix.gif rename to railties/guides/assets/images/rails_logo_remix.gif diff --git a/railties/guides/images/rails_welcome.png b/railties/guides/assets/images/rails_welcome.png similarity index 100% rename from railties/guides/images/rails_welcome.png rename to railties/guides/assets/images/rails_welcome.png diff --git a/railties/guides/images/session_fixation.png b/railties/guides/assets/images/session_fixation.png similarity index 100% rename from railties/guides/images/session_fixation.png rename to railties/guides/assets/images/session_fixation.png diff --git a/railties/guides/images/tab_grey.gif b/railties/guides/assets/images/tab_grey.gif similarity index 100% rename from railties/guides/images/tab_grey.gif rename to railties/guides/assets/images/tab_grey.gif diff --git a/railties/guides/images/tab_info.gif b/railties/guides/assets/images/tab_info.gif similarity index 100% rename from railties/guides/images/tab_info.gif rename to railties/guides/assets/images/tab_info.gif diff --git a/railties/guides/images/tab_note.gif b/railties/guides/assets/images/tab_note.gif similarity index 100% rename from railties/guides/images/tab_note.gif rename to railties/guides/assets/images/tab_note.gif diff --git a/railties/guides/images/tab_red.gif b/railties/guides/assets/images/tab_red.gif similarity index 100% rename from railties/guides/images/tab_red.gif rename to railties/guides/assets/images/tab_red.gif diff --git a/railties/guides/images/tab_yellow.gif b/railties/guides/assets/images/tab_yellow.gif similarity index 100% rename from railties/guides/images/tab_yellow.gif rename to railties/guides/assets/images/tab_yellow.gif diff --git a/railties/guides/images/tab_yellow.png b/railties/guides/assets/images/tab_yellow.png similarity index 100% rename from railties/guides/images/tab_yellow.png rename to railties/guides/assets/images/tab_yellow.png diff --git a/railties/guides/images/validation_error_messages.png b/railties/guides/assets/images/validation_error_messages.png similarity index 100% rename from railties/guides/images/validation_error_messages.png rename to railties/guides/assets/images/validation_error_messages.png diff --git a/railties/guides/files/javascripts/code_highlighter.js b/railties/guides/assets/javascripts/code_highlighter.js similarity index 100% rename from railties/guides/files/javascripts/code_highlighter.js rename to railties/guides/assets/javascripts/code_highlighter.js diff --git a/railties/guides/files/javascripts/guides.js b/railties/guides/assets/javascripts/guides.js similarity index 100% rename from railties/guides/files/javascripts/guides.js rename to railties/guides/assets/javascripts/guides.js diff --git a/railties/guides/files/javascripts/highlighters.js b/railties/guides/assets/javascripts/highlighters.js similarity index 100% rename from railties/guides/files/javascripts/highlighters.js rename to railties/guides/assets/javascripts/highlighters.js diff --git a/railties/guides/files/stylesheets/main.css b/railties/guides/assets/stylesheets/main.css similarity index 89% rename from railties/guides/files/stylesheets/main.css rename to railties/guides/assets/stylesheets/main.css index 2fd0a2f37e..7ccae2c87e 100644 --- a/railties/guides/files/stylesheets/main.css +++ b/railties/guides/assets/stylesheets/main.css @@ -92,7 +92,7 @@ body { } #header { - background: #c52f24 url(../../images/header_tile.gif) repeat-x; + background: #c52f24 url(../images/header_tile.gif) repeat-x; color: #FFF; padding: 1.5em 0; position: relative; @@ -100,7 +100,7 @@ body { } #feature { - background: #d5e9f6 url(../../images/feature_tile.gif) repeat-x; + background: #d5e9f6 url(../images/feature_tile.gif) repeat-x; color: #333; padding: 0.5em 0 1.5em; } @@ -132,7 +132,7 @@ body { #footer { padding: 2em 0; - background: url(../../images/footer_tile.gif) repeat-x; + background: url(../images/footer_tile.gif) repeat-x; } #footer .wrapper { padding-left: 2em; @@ -179,7 +179,7 @@ a, a:link, a:visited { } #header .nav .index a { - background: #980905 url(../../images/nav_arrow.gif) no-repeat right top; + background: #980905 url(../images/nav_arrow.gif) no-repeat right top; padding-right: 1em; position: relative; z-index: 15; @@ -285,7 +285,7 @@ h6 { #header h1 { float: left; - background: url(../../images/rails_guides_logo.gif) no-repeat; + background: url(../images/rails_guides_logo.gif) no-repeat; width: 297px; text-indent: -9999em; margin: 0; @@ -306,7 +306,7 @@ h6 { #feature ul {margin-left: 0;} #feature ul li { list-style: none; - background: url(../../images/check_bullet.gif) no-repeat left 0.5em; + background: url(../images/check_bullet.gif) no-repeat left 0.5em; padding: 0.5em 1.75em 0.5em 1.75em; font-size: 1.1428em; font-weight: bold; @@ -325,12 +325,12 @@ h6 { font-size: 1.2857em; padding: 0.125em 0 0.25em 0; margin-bottom: 0; - /*background: url(../../images/book_icon.gif) no-repeat left top; + /*background: url(../images/book_icon.gif) no-repeat left top; padding: 0.125em 0 0.25em 28px;*/ } #mainCol dd.ticket, #subCol dd.ticket { - background: #fff9d8 url(../../images/tab_yellow.gif) no-repeat left top; + background: #fff9d8 url(../images/tab_yellow.gif) no-repeat left top; border: none; padding: 1.25em 1em 1.25em 48px; margin-left: 0; @@ -338,7 +338,7 @@ h6 { } #mainCol div.warning, #subCol dd.warning { - background: #f9d9d8 url(../../images/tab_red.gif) no-repeat left top; + background: #f9d9d8 url(../images/tab_red.gif) no-repeat left top; border: none; padding: 1.25em 1.25em 1.25em 48px; margin-left: 0; @@ -355,7 +355,7 @@ h6 { #subCol .chapters ul li { list-style: none; padding: 0 0 0 1em; - background: url(../../images/bullet.gif) no-repeat left 0.45em; + background: url(../images/bullet.gif) no-repeat left 0.45em; margin-left: 0; font-size: 1em; font-weight: normal; @@ -366,7 +366,7 @@ tt { } div.code_container { - background: #EEE url(../../images/tab_grey.gif) no-repeat left top; + background: #EEE url(../images/tab_grey.gif) no-repeat left top; padding: 0.25em 1em 0.5em 48px; } @@ -378,14 +378,14 @@ code { } .note { - background: #fff9d8 url(../../images/tab_note.gif) no-repeat left top; + background: #fff9d8 url(../images/tab_note.gif) no-repeat left top; border: none; padding: 1em 1em 0.25em 48px; margin: 0.25em 0 1.5em 0; } .info { - background: #d5e9f6 url(../../images/tab_info.gif) no-repeat left top; + background: #d5e9f6 url(../images/tab_info.gif) no-repeat left top; border: none; padding: 1em 1em 0.25em 48px; margin: 0.25em 0 1.5em 0; @@ -395,7 +395,7 @@ code { #mainCol ul li { list-style:none; - background: url(../../images/grey_bullet.gif) no-repeat left 0.5em; + background: url(../images/grey_bullet.gif) no-repeat left 0.5em; padding-left: 1em; margin-left: 0; } diff --git a/railties/guides/files/stylesheets/print.css b/railties/guides/assets/stylesheets/print.css similarity index 100% rename from railties/guides/files/stylesheets/print.css rename to railties/guides/assets/stylesheets/print.css diff --git a/railties/guides/files/stylesheets/reset.css b/railties/guides/assets/stylesheets/reset.css similarity index 100% rename from railties/guides/files/stylesheets/reset.css rename to railties/guides/assets/stylesheets/reset.css diff --git a/railties/guides/files/stylesheets/style.css b/railties/guides/assets/stylesheets/style.css similarity index 100% rename from railties/guides/files/stylesheets/style.css rename to railties/guides/assets/stylesheets/style.css diff --git a/railties/guides/files/stylesheets/syntax.css b/railties/guides/assets/stylesheets/syntax.css similarity index 100% rename from railties/guides/files/stylesheets/syntax.css rename to railties/guides/assets/stylesheets/syntax.css diff --git a/railties/guides/rails_guides/generator.rb b/railties/guides/rails_guides/generator.rb index 1454aed6e4..b8c1913819 100644 --- a/railties/guides/rails_guides/generator.rb +++ b/railties/guides/rails_guides/generator.rb @@ -107,8 +107,7 @@ module RailsGuides end def copy_assets - FileUtils.cp_r(File.join(guides_dir, 'images'), output_dir) - FileUtils.cp_r(File.join(guides_dir, 'files'), output_dir) + FileUtils.cp_r(Dir.glob("#{guides_dir}/assets/*"), output_dir) end def output_file_for(guide) diff --git a/railties/guides/source/contribute.textile b/railties/guides/source/contribute.textile index 1203e38a4e..8c64df5362 100644 --- a/railties/guides/source/contribute.textile +++ b/railties/guides/source/contribute.textile @@ -9,7 +9,7 @@ h3. How to Contribute? * We have an open commit policy: anyone is welcome to contribute, but you'll need to ask for commit access. * PM lifo at "GitHub":http://github.com asking for "docrails":http://github.com/lifo/docrails/tree/master commit access. * Guides are written in Textile, and reside at railties/guides/source in the docrails project. -* All images are in the railties/guides/images directory. +* Assets are stored in the +railties/guides/assets+ directory. * Sample format : "Active Record Associations":http://github.com/lifo/docrails/blob/3e56a3832415476fdd1cb963980d0ae390ac1ed3/railties/guides/source/association_basics.textile * Sample output : "Active Record Associations":association_basics.html * You can build the Guides during testing by running +rake generate_guides+ in the +railties+ directory. diff --git a/railties/guides/source/layout.html.erb b/railties/guides/source/layout.html.erb index 9819db1f89..b280101d25 100644 --- a/railties/guides/source/layout.html.erb +++ b/railties/guides/source/layout.html.erb @@ -7,13 +7,13 @@ <%= yield(:page_title) || 'Ruby on Rails guides' %> - - - + + + - - - + + + From 7f956af47f4eeed54644a887dbb5f2ffcd8e41b8 Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Sun, 4 Apr 2010 11:32:47 +0200 Subject: [PATCH 07/17] Added .DS_Store to .gitignore --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 16bffc157b..9c3207049f 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ +.DS_Store *.gem pkg .bundle From 96b70229d681006ce4b169541845935bc067e294 Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Sun, 4 Apr 2010 11:44:54 +0200 Subject: [PATCH 08/17] Updated changelog on getting_started and layouts_and_rendering --- railties/guides/source/getting_started.textile | 1 + railties/guides/source/layouts_and_rendering.textile | 1 + 2 files changed, 2 insertions(+) diff --git a/railties/guides/source/getting_started.textile b/railties/guides/source/getting_started.textile index 9cc96f8205..9669f7f155 100644 --- a/railties/guides/source/getting_started.textile +++ b/railties/guides/source/getting_started.textile @@ -1432,6 +1432,7 @@ h3. Changelog "Lighthouse ticket":http://rails.lighthouseapp.com/projects/16213-rails-guides/tickets/2 +* April 1, 2010: Fixed document to validate XHTML 1.0 Strict. "Jaime Iniesta":credits.html#jaimeiniesta * February 8, 2010: Full re-write for Rails 3.0-beta, added helpers and before_filters, refactored code by "Mikel Lindsaar":credits:html#raasdnil * January 24, 2010: Re-write for Rails 3.0 by "Mikel Lindsaar":credits:html#raasdnil * July 18, 2009: Minor cleanup in anticipation of Rails 2.3.3 by "Mike Gunderloy":credits.html#mgunderloy diff --git a/railties/guides/source/layouts_and_rendering.textile b/railties/guides/source/layouts_and_rendering.textile index 1ddba807e0..d9781fc966 100644 --- a/railties/guides/source/layouts_and_rendering.textile +++ b/railties/guides/source/layouts_and_rendering.textile @@ -1197,6 +1197,7 @@ h3. Changelog "Lighthouse ticket":http://rails.lighthouseapp.com/projects/16213-rails-guides/tickets/15 +* April 4, 2010: Fixed document to validate XHTML 1.0 Strict. "Jaime Iniesta":credits.html#jaimeiniesta * January 25, 2010: Rails 3.0 Update by "Mikel Lindsaar":credits.html#raasdnil * December 27, 2008: Merge patch from Rodrigo Rosenfeld Rosas covering subtemplates * December 27, 2008: Information on new rendering defaults by "Mike Gunderloy":credits.html#mgunderloy From be72a397f809360b5158db0b32429bf82593ceb5 Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Sun, 4 Apr 2010 11:48:10 +0200 Subject: [PATCH 09/17] Added 'Rails Guides Reviewers' section to credits --- railties/guides/source/credits.html.erb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/railties/guides/source/credits.html.erb b/railties/guides/source/credits.html.erb index 0f203765ac..9851702df9 100644 --- a/railties/guides/source/credits.html.erb +++ b/railties/guides/source/credits.html.erb @@ -59,6 +59,8 @@ Mikel Lindsaar has been working with Rails since 2006 and is the author of the Ruby Mail gem and core contributor (he helped re-write Action Mailer's API). Mikel has a blog and tweets. <% end %> +

Rails Guides Reviewers

+ <%= author('Jaime Iniesta', 'jaimeiniesta', 'jaimeiniesta.jpg') do %> Jaime Iniesta works as a Ruby on Rails freelance developer since 2005. He's a member of ProRuby, co-founder of the Spanish Ruby Users Group, member of Spain.rb, and organizer of Conferencia Rails and EuRuKo 2009. Jaime has a blog and tweets. <% end %> From af87232342b1bc82b45e2ac34e926753ca03d525 Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Sun, 4 Apr 2010 12:09:09 +0200 Subject: [PATCH 10/17] Fix testing guide so that it validates XHTML 1.0 Strict --- railties/guides/source/testing.textile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/railties/guides/source/testing.textile b/railties/guides/source/testing.textile index ac9fb4276e..b1eee0ccb9 100644 --- a/railties/guides/source/testing.textile +++ b/railties/guides/source/testing.textile @@ -411,7 +411,7 @@ NOTE: +assert_valid(record)+ has been deprecated. Please use +assert(record.vali |_.Assertion |_.Purpose| |+assert_valid(record)+ |Ensures that the passed record is valid by Active Record standards and returns any error messages if it is not.| |+assert_difference(expressions, difference = 1, message = nil) {...}+ |Test numeric difference between the return value of an expression as a result of what is evaluated in the yielded block.| -|+assert_no_difference(expressions, message = nil, &block)+ |Asserts that the numeric result of evaluating an expression is not changed before and after invoking the passed in block.| +|+assert_no_difference(expressions, message = nil, &block)+ |Asserts that the numeric result of evaluating an expression is not changed before and after invoking the passed in block.| |+assert_recognizes(expected_options, path, extras={}, message=nil)+ |Asserts that the routing of the given path was handled correctly and that the parsed options (given in the expected_options hash) match path. Basically, it asserts that Rails recognizes the route given by expected_options.| |+assert_generates(expected_path, options, defaults={}, extras = {}, message=nil)+ |Asserts that the provided options can be used to generate the provided path. This is the inverse of assert_recognizes. The extras parameter is used to tell the request the names and values of additional request parameters that would be in a query string. The message parameter allows you to specify a custom error message for assertion failures.| |+assert_response(type, message = nil)+ |Asserts that the response comes with a specific status code. You can specify +:success+ to indicate 200, +:redirect+ to indicate 300-399, +:missing+ to indicate 404, or +:error+ to match the 500-599 range| @@ -940,6 +940,7 @@ h3. Changelog "Lighthouse ticket":http://rails.lighthouseapp.com/projects/16213-rails-guides/tickets/8 +* April 4, 2010: Fixed document to validate XHTML 1.0 Strict. "Jaime Iniesta":credits.html#jaimeiniesta * November 13, 2008: Revised based on feedback from Pratik Naik by "Akshay Surve":credits.html#asurve (not yet approved for publication) * October 14, 2008: Edit and formatting pass by "Mike Gunderloy":credits.html#mgunderloy (not yet approved for publication) * October 12, 2008: First draft by "Akshay Surve":credits.html#asurve (not yet approved for publication) From 395f171141e50b99516d445198a44afc12bd65ea Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Sun, 4 Apr 2010 12:21:32 +0200 Subject: [PATCH 11/17] Fixed debugging guide to pass XHTML 1.0 Strict --- railties/guides/source/debugging_rails_applications.textile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/railties/guides/source/debugging_rails_applications.textile b/railties/guides/source/debugging_rails_applications.textile index cd0098d686..3eddf1a2b1 100644 --- a/railties/guides/source/debugging_rails_applications.textile +++ b/railties/guides/source/debugging_rails_applications.textile @@ -286,7 +286,7 @@ condition down finish list ps save thread var continue edit frame method putl set tmate where -TIP: To view the help menu for any command use +help + in active debug mode. For example: _+help var+_ +TIP: To view the help menu for any command use +help <command-name>+ in active debug mode. For example: _+help var+_ The next command to learn is one of the most useful: +list+. You can also abbreviate ruby-debug commands by supplying just enough letters to distinguish them from other commands, so you can also use +l+ for the +list+ command. @@ -704,6 +704,7 @@ h3. Changelog "Lighthouse ticket":http://rails.lighthouseapp.com/projects/16213-rails-guides/tickets/5 +* April 4, 2010: Fixed document to validate XHTML 1.0 Strict. "Jaime Iniesta":credits.html#jaimeiniesta * November 3, 2008: Accepted for publication. Added RJS, memory leaks and plugins chapters by "Emilio Tagua":credits.html#miloops * October 19, 2008: Copy editing pass by "Mike Gunderloy":credits.html#mgunderloy * September 16, 2008: initial version by "Emilio Tagua":credits.html#miloops From 532f1fe07522a2f60db75c72f71778b8b0c4f81f Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Sun, 4 Apr 2010 12:29:25 +0200 Subject: [PATCH 12/17] Move credits pic to new assets/image folder --- .../guides/{ => assets}/images/jaimeiniesta.jpg | Bin 1 file changed, 0 insertions(+), 0 deletions(-) rename railties/guides/{ => assets}/images/jaimeiniesta.jpg (100%) diff --git a/railties/guides/images/jaimeiniesta.jpg b/railties/guides/assets/images/jaimeiniesta.jpg similarity index 100% rename from railties/guides/images/jaimeiniesta.jpg rename to railties/guides/assets/images/jaimeiniesta.jpg From 62fd691a7a5c90b5a56b5b8be399482fdd89928e Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Sun, 4 Apr 2010 12:33:28 +0200 Subject: [PATCH 13/17] Fix XHTML on performance guide --- railties/guides/source/performance_testing.textile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/railties/guides/source/performance_testing.textile b/railties/guides/source/performance_testing.textile index 5c760a5966..154dbbbbe6 100644 --- a/railties/guides/source/performance_testing.textile +++ b/railties/guides/source/performance_testing.textile @@ -330,7 +330,7 @@ h5. Apply the Patch h5. Configure and Install -The following will install ruby in your home directory's +/rubygc+ directory. Make sure to replace ++ with a full patch to your actual home directory. +The following will install ruby in your home directory's +/rubygc+ directory. Make sure to replace +<homedir>+ with a full patch to your actual home directory. [lifo@null ruby-version]$ ./configure --prefix=//rubygc From a6dc000158e806c1e82ee4af5e5c2e43e5f0493f Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Sun, 4 Apr 2010 12:43:19 +0200 Subject: [PATCH 14/17] Replace
 by ,  and  on plugins
 guide; making it validate XHTML 1.0 Strict

---
 railties/guides/source/plugins.textile | 29 +++++++++++++-------------
 1 file changed, 15 insertions(+), 14 deletions(-)

diff --git a/railties/guides/source/plugins.textile b/railties/guides/source/plugins.textile
index 2db421aa91..74c8ee2df9 100644
--- a/railties/guides/source/plugins.textile
+++ b/railties/guides/source/plugins.textile
@@ -35,14 +35,14 @@ h4. Create the Basic Application
 
 The examples in this guide require that you have a working rails application.  To create a simple rails app execute:
 
-
+
 gem install rails
 rails yaffle_guide
 cd yaffle_guide
 rails generate scaffold bird name:string
 rake db:migrate
 rails server
-
+
Then navigate to http://localhost:3000/birds. Make sure you have a functioning rails app before continuing. @@ -56,22 +56,22 @@ Rails ships with a plugin generator which creates a basic plugin skeleton. Pass This creates a plugin in 'vendor/plugins' including an 'init.rb' and 'README' as well as standard 'lib', 'task', and 'test' directories. Examples: -
+
 rails generate plugin yaffle
 rails generate plugin yaffle --with-generator
-
+ To get more detailed help on the plugin generator, type +rails generate plugin+. Later on this guide will describe how to work with generators, so go ahead and generate your plugin with the +--with-generator+ option now: -
+
 rails generate plugin yaffle --with-generator
-
+ You should see the following output: -
+
 create  vendor/plugins/yaffle/lib
 create  vendor/plugins/yaffle/tasks
 create  vendor/plugins/yaffle/test
@@ -89,20 +89,20 @@ create  vendor/plugins/yaffle/generators/yaffle
 create  vendor/plugins/yaffle/generators/yaffle/templates
 create  vendor/plugins/yaffle/generators/yaffle/yaffle_generator.rb
 create  vendor/plugins/yaffle/generators/yaffle/USAGE
-
+ h4. Organize Your Files To make it easy to organize your files and to make the plugin more compatible with GemPlugins, start out by altering your file system to look like this: -
+
 |-- lib
 |   |-- yaffle
 |   `-- yaffle.rb
 `-- rails
     |
     `-- init.rb
-
+ *vendor/plugins/yaffle/init.rb* @@ -124,7 +124,7 @@ h4. Test Setup *vendor/plugins/yaffle/test/database.yml:* -
+
 sqlite:
   :adapter: sqlite
   :dbfile: vendor/plugins/yaffle/test/yaffle_plugin.sqlite.db
@@ -146,7 +146,7 @@ mysql:
   :username: root
   :password: password
   :database: yaffle_plugin_test
-
+ For this guide you'll need 2 tables/models, Hickwalls and Wickwalls, so add the following: @@ -239,10 +239,10 @@ end To run this, go to the plugin directory and run +rake+: -
+
 cd vendor/plugins/yaffle
 rake
-
+ You should see output like: @@ -1511,4 +1511,5 @@ h3. Changelog "Lighthouse ticket":http://rails.lighthouseapp.com/projects/16213/tickets/32-update-plugins-guide +* April 4, 2010: Fixed document to validate XHTML 1.0 Strict. "Jaime Iniesta":credits.html#jaimeiniesta * November 17, 2008: Major revision by Jeff Dean From b352b97ff590f0db27432a8a4d3df3c632780b52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Valim?= Date: Sun, 4 Apr 2010 03:47:49 -0700 Subject: [PATCH 15/17] No .DS_Store on .gitignore. Text editor files should be ignored in your ~/.gitignore. --- .gitignore | 1 - 1 file changed, 1 deletion(-) diff --git a/.gitignore b/.gitignore index 9c3207049f..16bffc157b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,3 @@ -.DS_Store *.gem pkg .bundle From 7d7e0627a0490b6b4ddb0ee5429264ccd46f1245 Mon Sep 17 00:00:00 2001 From: Xavier Noria Date: Sun, 4 Apr 2010 08:42:54 -0700 Subject: [PATCH 16/17] fixes duplicate element IDs in some guides --- railties/guides/rails_guides/generator.rb | 2 +- railties/guides/source/action_view_overview.textile | 2 +- .../source/active_support_core_extensions.textile | 6 +++--- railties/guides/source/form_helpers.textile | 2 +- railties/guides/source/performance_testing.textile | 6 +++--- railties/guides/source/routing.textile | 6 +++--- railties/guides/source/security.textile | 10 +++++----- 7 files changed, 17 insertions(+), 17 deletions(-) diff --git a/railties/guides/rails_guides/generator.rb b/railties/guides/rails_guides/generator.rb index b8c1913819..f577182f5f 100644 --- a/railties/guides/rails_guides/generator.rb +++ b/railties/guides/rails_guides/generator.rb @@ -227,7 +227,7 @@ module RailsGuides anchors = Set.new html.scan(/ 'person', :object => @person -h5. select +h5(#prototype-select). select Returns a collection reference by finding it through a CSS pattern in the DOM. diff --git a/railties/guides/source/active_support_core_extensions.textile b/railties/guides/source/active_support_core_extensions.textile index a8410a8dd2..b41b16b728 100644 --- a/railties/guides/source/active_support_core_extensions.textile +++ b/railties/guides/source/active_support_core_extensions.textile @@ -866,7 +866,7 @@ WARNING: Note that in that case +parent+ returns +Object+. NOTE: Defined in +active_support/core_ext/module/introspection.rb+. -h5. +parents+ +h5(#module-parents). +parents+ The method +parents+ calls +parent+ on the receiver and upwards until +Object+ is reached. The chain is returned in an array, from bottom to top: @@ -2191,9 +2191,9 @@ NOTE: Defined in +active_support/core_ext/array/grouping.rb+. h3. Extensions to +Hash+ -h4. Conversions +h4(#hash-conversions). Conversions -h5. +to_xml+ +h5(#hash-to-xml). +to_xml+ The method +to_xml+ returns a string containing an XML representation of its receiver: diff --git a/railties/guides/source/form_helpers.textile b/railties/guides/source/form_helpers.textile index d33bb4b4ff..fe0f8f1ac9 100644 --- a/railties/guides/source/form_helpers.textile +++ b/railties/guides/source/form_helpers.textile @@ -501,7 +501,7 @@ Date.civil(params[:start_date][:year].to_i, params[:start_date][:month].to_i, pa The +:prefix+ option is the key used to retrieve the hash of date components from the +params+ hash. Here it was set to +start_date+, if omitted it will default to +date+. -h4. Model Object Helpers +h4(#select-model-object-helpers). Model Object Helpers +select_date+ does not work well with forms that update or create Active Record objects as Active Record expects each element of the +params+ hash to correspond to one attribute. The model object helpers for dates and times submit parameters with special names, when Active Record sees parameters with such names it knows they must be combined with the other parameters and given to a constructor appropriate to the column type. For example: diff --git a/railties/guides/source/performance_testing.textile b/railties/guides/source/performance_testing.textile index 154dbbbbe6..f74b68b0ef 100644 --- a/railties/guides/source/performance_testing.textile +++ b/railties/guides/source/performance_testing.textile @@ -213,11 +213,11 @@ h4. Understanding the Output Performance tests generate different outputs inside +tmp/performance+ directory depending on their mode and metric. -h5. Benchmarking +h5(#output-benchmarking). Benchmarking In benchmarking mode, performance tests generate two types of outputs: -h6. Command Line +h6(#output-command-line). Command Line This is the primary form of output in benchmarking mode. Example: @@ -258,7 +258,7 @@ measurement,created_at,app,rails,ruby,platform 0.00771250000000012,2009-01-09T15:46:03Z,,2.3.0.master.859e150,ruby-1.8.6.110,i686-darwin9.0.0 -h5. Profiling +h5(#output-profiling). Profiling In profiling mode, you can choose from four types of output. diff --git a/railties/guides/source/routing.textile b/railties/guides/source/routing.textile index 6625412684..0cf8c45761 100644 --- a/railties/guides/source/routing.textile +++ b/railties/guides/source/routing.textile @@ -65,7 +65,7 @@ RESTful routes take advantage of the built-in REST orientation of Rails to wrap resources :books -h4. Named Routes +h4(#quick-tour-named-routes). Named Routes Named routes give you very readable links in your code, as well as handling incoming requests. Here's a typical named route: @@ -91,7 +91,7 @@ resources :assemblies do end -h4. Regular Routes +h4(#quick-tour-regular-routes). Regular Routes In many applications, you'll also see non-RESTful routing, which explicitly connects the parts of a URL to a particular action. For example, @@ -400,7 +400,7 @@ In addition to the routes for magazines, this declaration will also create route This will also create routing helpers such as +magazine_ads_url+ and +edit_magazine_ad_path+. -h5. Using +:name_prefix+ +h5(#nested-name-prefix). Using +:name_prefix+ The +:name_prefix+ option overrides the automatically-generated prefix in nested route helpers. For example, diff --git a/railties/guides/source/security.textile b/railties/guides/source/security.textile index b62ff8cb38..1ddf094d18 100644 --- a/railties/guides/source/security.textile +++ b/railties/guides/source/security.textile @@ -611,7 +611,7 @@ h4. SQL Injection -- _Thanks to clever methods, this is hardly a problem in most Rails applications. However, this is a very devastating and common attack in web applications, so it is important to understand the problem._ -h5. Introduction +h5(#sql-injection-introduction). Introduction SQL injection attacks aim at influencing database queries by manipulating web application parameters. A popular goal of SQL injection attacks is to bypass authorization. Another goal is to carry out data manipulation or reading arbitrary data. Here is an example of how not to use user input data in a query: @@ -668,7 +668,7 @@ The result won't be a list of projects (because there is no project with an empt Also, the second query renames some columns with the AS statement so that the web application displays the values from the user table. Be sure to update your Rails "to at least 2.1.1":http://www.rorsecurity.info/2008/09/08/sql-injection-issue-in-limit-and-offset-parameter/. -h5. Countermeasures +h5(#sql-injection-countermeasures). Countermeasures Ruby on Rails has a built in filter for special SQL characters, which will escape ' , " , NULL character and line breaks. Using +Model.find(id)+ or +Model.find_by_some thing(something)+ automatically applies this countermeasure. But in SQL fragments, especially in conditions fragments (+:conditions => "..."+), the +connection.execute()+ or +Model.find_by_sql()+ methods, it has to be applied manually. @@ -760,7 +760,7 @@ http://www.cbsnews.com/stories/2002/02/15/weather_local/main501644.shtml?zipcode