Advertisement
Guest User

Untitled

a guest
Sep 27th, 2012
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Rails 0.28 KB | None | 0 0
  1.     def fancy_link_to(title, url, *options)
  2.         puts options.join(",")
  3.         link_to title, url, :class=>"btn btn-large btn-primary", options.join(",")
  4.     end
  5.  
  6.     ######## Caller Example ########
  7.     <%= fancy_link_to('Destroy', [@owner, wall], method: :delete, data: { confirm: 'Are you sure?' } ) %>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement