Commit Graph

506 Commits

Author SHA1 Message Date
David Heinemeier Hansson
bdd16a75e6 render :nothing shouldnt cause layouts
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1353 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-22 16:57:51 +00:00
David Heinemeier Hansson
060ecf1a24 Set redirected_to proper
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1352 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-22 16:52:54 +00:00
David Heinemeier Hansson
2f7c5f84e4 Cure some ills discovered with the refactoring
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1351 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-22 11:07:09 +00:00
David Heinemeier Hansson
da0c4c5c96 Deprecated all render_* methods in favor of consolidating all rendering behavior in Base#render(options). This enables more natural use of combining options, such as layouts
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1350 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-22 08:58:43 +00:00
David Heinemeier Hansson
0367317dd6 Deprecated redirect_to_path and redirect_to_url in favor of letting redirect_to do the right thing when passed either a path or url. Introduced r as a unified method for render (still under construction)
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1349 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-22 07:43:05 +00:00
David Heinemeier Hansson
dab360e181 Added DoubleRenderError exception that'll be raised if render* is called twice #518 [Nicholas Seckar]. Fixed exceptions occuring after render has been called #1096 [Nicholas Seckar]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1348 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-21 18:51:08 +00:00
David Heinemeier Hansson
7159402c6d Fixed use of an integer as return code for renders, so render_text "hello world", 404 now works #1327
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1345 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-21 17:50:57 +00:00
David Heinemeier Hansson
997eb90c90 Made the post_format work with content-type
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1337 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-20 18:39:40 +00:00
David Heinemeier Hansson
24b13acd42 Made the post_format work with content-type
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1336 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-20 18:32:04 +00:00
David Heinemeier Hansson
9bf38dec69 Include flash in the list of attributes with accessors in the view
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1334 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-20 07:04:51 +00:00
David Heinemeier Hansson
d3704f888b Fixed assert_redirect_to to work with redirect_to_path #869 [Nicholas Seckar]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1332 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 19:19:58 +00:00
David Heinemeier Hansson
7160ab1c18 Fixed escaping of :method option in remote_form_tag #1218 [Rick Olson]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1328 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 19:08:16 +00:00
David Heinemeier Hansson
977671c226 Optimize ActionCacheFilter by using url_for less #1230 [skaen]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1326 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 18:59:43 +00:00
David Heinemeier Hansson
caf6ff6a2f Cache relative_url_root and optimize path #1232 [skaen]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1325 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 18:55:50 +00:00
David Heinemeier Hansson
3a057ea4ac Faster action_exempted? #1231 [skaen]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1324 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 18:54:16 +00:00
David Heinemeier Hansson
45ee71af3c Added Serbia and Montenegro to the country_select #1239 [todd@robotcoop.com]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1323 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 18:30:53 +00:00
David Heinemeier Hansson
dd8c92ea5b Fixed Request#remote_ip in testing #1251 [bitsweat]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1322 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 18:24:52 +00:00
David Heinemeier Hansson
473e5bde74 Fixed that compute_public_path should recognize external URLs, so image_tag("http://www.example.com/images/icon.gif") is not prefixed with the relative url path #1254 [victor-ronr-trac@carotena.net]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1321 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 18:06:12 +00:00
David Heinemeier Hansson
202d5c0751 Added support for descending year values in DateHelper#select_year, like select_year(Date.today, :start_year => 2005, :end_year => 1900), which would count down from 2005 to 1900 instead of the other way #1274 [nwoods@mail.com]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1320 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 17:40:02 +00:00
David Heinemeier Hansson
26022d8d2a Ajax docing #1282 [Dee.Zsombor@gmail.com]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1318 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 17:29:20 +00:00
David Heinemeier Hansson
496ee0cd1b Fixed that FormHelper#checkbox should return a checked checkbox if the value is the same as checked_value #1286 [Florian Weber]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1317 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 17:27:08 +00:00
David Heinemeier Hansson
9b1fefbf54 Fixed doc #1291
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1315 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 17:14:35 +00:00
David Heinemeier Hansson
7ec91d4651 Fixed Form.disable in Prototype #1317 [Wintermute]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1311 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 16:45:53 +00:00
David Heinemeier Hansson
6ea6a725c4 Push to .org instead
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1310 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 16:42:47 +00:00
David Heinemeier Hansson
aa20834222 Added accessors to logger, params, response, session, and headers from the view, so you can write <% logger.info "stuff" %> instead of <% @logger.info "others" %> -- more consistent with the preferred way of accessing these attributes and collections from the controller
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1307 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-19 16:00:04 +00:00
David Heinemeier Hansson
68cdcf5ed3 Update docs to X-POST_DATA_MARSHAL
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1306 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-14 09:36:30 +00:00
David Heinemeier Hansson
cada2c71d3 Use X-POST_DATA_FORMAT instead of just POST_DATA_FORMAT
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1305 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-14 09:31:35 +00:00
David Heinemeier Hansson
86d2b2792a Added support for POST data in form of YAML or XML, which is controller through the POST_DATA_MARSHAL header
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1304 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-14 08:38:37 +00:00
David Heinemeier Hansson
db11abbfba Added support for POST data in form of YAML or XML, which is controller through the POST_DATA_MARSHAL header
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1303 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-14 08:36:19 +00:00
David Heinemeier Hansson
51f9c931ea Fixed that render_partial_collection should always return a string (and not sometimes an array, despite <%= %> not caring)
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1302 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-13 16:27:36 +00:00
David Heinemeier Hansson
8983a09752 Go straight to the class for asset_host
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1299 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-09 11:27:39 +00:00
David Heinemeier Hansson
45780be2a7 Added TextHelper#sanitize that can will remove any Javascript handlers, blocks, and forms from an input of HTML. This allows for use of HTML on public sites, but still be free of XSS issues. #1277 [Jamis Buck]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1298 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-09 11:24:18 +00:00
David Heinemeier Hansson
b167248b21 Fixed the HTML scanner used by assert_tag where a infinite loop could be caused by a stray less-than sign in the input #1270 [Jamis Buck]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1297 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-09 11:20:19 +00:00
David Heinemeier Hansson
8a41ea4588 Only gsub on a string
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1292 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-06 18:10:13 +00:00
David Heinemeier Hansson
409bc0970a Added functionality to assert_tag, so you can now do tests on the siblings of a node, to assert that some element comes before or after the element in question, or just to assert that some element exists as a sibling #1226 [Jamis Buck]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1291 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-06 16:42:01 +00:00
David Heinemeier Hansson
c971c24839 Changed RAILS_ASSET_HOST to become ActionController::Base.asset_host
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1289 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-06 05:10:36 +00:00
David Heinemeier Hansson
358a669390 Added better error handling for regexp caching expiration
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1288 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-06 05:09:01 +00:00
David Heinemeier Hansson
ac44be3494 Treat all request types as upper-case so the switch will work
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1283 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-04 10:46:33 +00:00
David Heinemeier Hansson
8b2598bb64 Made it default to assuming a GET request and reading from command-line only in case of the new CMD method
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1282 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-04 09:39:41 +00:00
David Heinemeier Hansson
dacb61c8ca Added that both AssetHelper#stylesheet_link_tag and AssetHelper#javascript_include_tag now accept an option hash as the last parameter, so you can do stuff like: stylesheet_link_tag "style", :media => "all"
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1281 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-03 14:39:57 +00:00
David Heinemeier Hansson
d2fb072563 Added FormTagHelper#image_submit_tag for making submit buttons that uses images
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1280 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-03 14:30:53 +00:00
David Heinemeier Hansson
2eebd11e0b Added the option of specifying a RAILS_ASSET_HOST that will then be used by all the asset helpers. This enables you to easily offload static content like javascripts and images to a separate server tuned just for that.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1279 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-03 10:25:01 +00:00
David Heinemeier Hansson
1edb807aff Dont expire or read fragments if caching is turned off
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1270 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-02 07:49:55 +00:00
David Heinemeier Hansson
577a22c47e Dont benchmark if the logger has been turned off
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1269 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-05-02 07:05:15 +00:00
David Heinemeier Hansson
e6f3e5d900 Fixed action/fragment caching using the filestore when a directory and a file wanted to to use the same name. Now there's a .cache prefix that sidesteps the conflict #1188 [imbcmdth@hotmail.com]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1260 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-04-30 15:29:27 +00:00
David Heinemeier Hansson
537efa36d0 Doc fix #1200
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1257 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-04-30 13:36:40 +00:00
David Heinemeier Hansson
90b08c5b92 Fixed documentation #1214
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1254 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-04-30 08:50:10 +00:00
David Heinemeier Hansson
98306bed05 Fixed missing id uniqueness in FormTag#radio_button #1207 [Jarkko]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1253 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-04-30 08:46:22 +00:00
David Heinemeier Hansson
b4fe4daa84 Fixed assert_redirected_to to work with :only_path => false #1204 [Alisdair McDiarmid]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1251 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-04-30 08:34:02 +00:00
David Heinemeier Hansson
c29cfe389e Check definition on constant not string
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1250 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-04-30 08:33:25 +00:00