I wrote a webform using Sinatra and Haml that will be used to call a Ruby script.
Everything seems fine except for one thing: I need to pass an argument to a Haml view f
Haml supports passing variables as locals. With Sinatra, you can send these locals like so:
haml :fail, :locals => {:vm_name => name}
and in the view, reference the variable using locals[:vm_name] or simply vm_name.
locals[:vm_name]
vm_name