moved javascript back to html as erb is needed for opener to sfdc