Learn something new... every 30 minutes

| No Comments

Re: (newbie) Why doesn't this line work?

Every time I work on my app. I feel like I learn something new about every 30 minutes...

this time it was that the :confirm parameter on :link_to (which pops up a confirmation box when you click a link), is an HTML option and thus needs syntax like

<%= link_to "delete", {:action => delete, :id => @item.id}, {:confirm => 'Are you sure?'} %>

Leave a comment

Pages

Powered by Movable Type 4.32-en

About this Entry

This page contains a single entry by Rory2 published on September 28, 2006 7:32 PM.

Dependant Destruction and the problems with Rails books was the previous entry in this blog.

Mega Rails cheatsheet is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.