aboutsummaryrefslogtreecommitdiffstats
path: root/guides
diff options
context:
space:
mode:
authorRyan Bigg <radarlistener@gmail.com>2012-05-17 19:17:17 +1000
committerRyan Bigg <radarlistener@gmail.com>2012-05-17 19:56:57 +1000
commit42c6f89c5dfa59ad2f91eb6f9f9da8f49999b03e (patch)
tree4e3f266b2e3cdcb80631f4241850af52f942027f /guides
parent9fc5b456a000f5fada0edb7b483b14915fd90b83 (diff)
downloadrails-42c6f89c5dfa59ad2f91eb6f9f9da8f49999b03e.tar.gz
rails-42c6f89c5dfa59ad2f91eb6f9f9da8f49999b03e.tar.bz2
rails-42c6f89c5dfa59ad2f91eb6f9f9da8f49999b03e.zip
[getting started] dialog box is not automatic, is provided through jquery_ujs, which is necessary to have in application layout
Diffstat (limited to 'guides')
-rw-r--r--guides/source/getting_started.textile9
1 files changed, 6 insertions, 3 deletions
diff --git a/guides/source/getting_started.textile b/guides/source/getting_started.textile
index 87e3aea2aa..4aeba5debe 100644
--- a/guides/source/getting_started.textile
+++ b/guides/source/getting_started.textile
@@ -1129,11 +1129,14 @@ together.
</erb>
Here we're using +link_to+ in a different way. We wrap the
-+:action+ and +:id+ attributes in a hash so that we can pass other
-arguments to +link_to+. The +:method+ and +:confirm+
++:action+ and +:id+ attributes in a hash so that we can pass those two keys in
+first as one argument, and then the final two keys as another argument. The +:method+ and +:confirm+
options are used as html5 attributes so that when the click is linked,
Rails will first show a confirm dialog to the user, and then submit the
-link with method +delete+. This is done via javascript automatically.
+link with method +delete+. This is done via the JavaScript file +jquery_ujs+
+which is automatically included into your application's layout
+(+app/views/layouts/application.html.erb+) when you generated the application.
+Without this file, the confirmation dialog box wouldn't appear.
!images/getting_started/confirm_dialog.png(Confirm Dialog)!