public
Fork of rails/rails
Description: Ruby on Rails
Homepage: http://rubyonrails.org
Clone URL: git://github.com/ddollar/rails.git
Update documentation for erb trim syntax. #5651 [matt@mattmargolis.net] 
Merge doc patches with stable.

git-svn-id: http://svn-commit.rubyonrails.org/rails/branches/stable@4701 
5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Marcel Molina (author)
Sun Aug 06 23:18:33 -0700 2006
commit  fc1ded46e7e9665cc130681e3a9214295043225d
tree    0505999e90059736a599fe96b33cff80ee6799fc
parent  33bc251ede4f77c4343af83d8996a37af646ccd1
...
 
 
 
 
 
1
2
3
 
4
5
6
...
1
2
3
4
5
6
7
 
8
9
10
11
0
@@ -1,6 +1,11 @@
0
+*1.12.3* (June 28th, 2006)
0
+=======
0
+
0
+* Update documentation for erb trim syntax. #5651 [matt@mattmargolis.net]
0
+
0
 * Short documentation to mention use of Mime::Type.register. #5710 [choonkeat@gmail.com]
0
 
0
-*1.12.3* (June 28th, 2006)
0
+* Pass :id => nil or :class => nil to error_messages_for to supress that html attribute. #3586 [olivier_ansaldi@yahoo.com, sebastien@goetzilla.info]
0
 
0
 * Fix broken traverse_to_controller. We now:
0
   Look for a _controller.rb file under RAILS_ROOT to load.
...
11
12
13
14
 
15
16
17
...
19
20
21
22
 
23
24
25
26
27
 
 
 
28
29
30
...
11
12
13
 
14
15
16
17
...
19
20
21
 
22
23
24
25
26
 
27
28
29
30
31
32
0
@@ -11,7 +11,7 @@ module ActionView #:nodoc:
0
   #
0
   # = ERb
0
   #
0
- # You trigger ERb by using embeddings such as <% %> and <%= %>. The difference is whether you want output or not. Consider the
0
+ # You trigger ERb by using embeddings such as <% %>, <% -%>, and <%= %>. The <%= %> tag set is used when you want output. Consider the
0
   # following loop for names:
0
   #
0
   # <b>Names of all the people</b>
0
@@ -19,12 +19,14 @@ module ActionView #:nodoc:
0
   # Name: <%= person.name %><br/>
0
   # <% end %>
0
   #
0
- # The loop is setup in regular embedding tags (<% %>) and the name is written using the output embedding tag (<%= %>). Note that this
0
+ # The loop is setup in regular embedding tags <% %> and the name is written using the output embedding tag <%= %>. Note that this
0
   # is not just a usage suggestion. Regular output functions like print or puts won't work with ERb templates. So this would be wrong:
0
   #
0
   # Hi, Mr. <% puts "Frodo" %>
0
   #
0
- # (If you absolutely must write from within a function, you can use the TextHelper#concat)
0
+ # If you absolutely must write from within a function, you can use the TextHelper#concat
0
+ #
0
+ # <%- and -%> suppress leading and trailing whitespace, including the trailing newline, and can be used interchangeably with <% and %>.
0
   #
0
   # == Using sub templates
0
   #

Comments

    No one has commented yet.