This project is archived and is in readonly mode.
Add content_for?(name) helper
Reported by Darragh Curran | October 31st, 2008 @ 05:38 PM | in 2.x
Sometimes I do things in my layout based on whether content has been yielded to a particular content_for label.
Easy to do at the moment - but I reckoned it might be nice to hide this implementation detail. (similar to how we used to do @content_for_something but now do yield :something)
@content_for_right_col.present?
becomes
content_for?(:right_col)
Comments and changes to this ticket
-
Pratik March 6th, 2009 @ 05:13 PM
- Assigned user set to Pratik
- Title changed from add content_for?(name) helper to Add content_for?(name) helper
Looks good. Will add after 2.3 is released.
Thanks.
-
Pratik June 21st, 2009 @ 05:42 PM
- State changed from new to resolved
Resolved in 9cb8c812f2a23ab5653a7888740a014a02c97c18
-
Repository June 21st, 2009 @ 09:25 PM
(from [9cb8c812f2a23ab5653a7888740a014a02c97c18]) Add content_for?(:name) helper to check if content_for(:name) is present [#1311 state:resolved]
Signed-off-by: Pratik Naik pratiknaik@gmail.com
http://github.com/rails/rails/commit/9cb8c812f2a23ab5653a7888740a01... -
Repository June 23rd, 2009 @ 10:50 PM
(from [fa926b8eff2198ac06736c5085b7069a0a8ebf39]) Add content_for?(:name) helper to check if content_for(:name) is present [#1311 state:resolved]
Signed-off-by: Pratik Naik pratiknaik@gmail.com
http://github.com/rails/rails/commit/fa926b8eff2198ac06736c5085b706...
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>
People watching this ticket
Attachments
Tags
Referenced by
- 1311 Add content_for?(name) helper (from [9cb8c812f2a23ab5653a7888740a014a02c97c18]) Add con...
- 1311 Add content_for?(name) helper (from [fa926b8eff2198ac06736c5085b7069a0a8ebf39]) Add con...