fix 2 problems in backend/vbox

1) it was using undef $template
2) it tried to use File::Temp without importing it