I recommend learning how this works:

http://en.wikibooks.org/wiki/Ruby_Programming/Syntax/Literals#Interpolation

driver.execute_script("window.open('#{link}')")

-- 
Posted via http://www.ruby-forum.com/.