added $view to view variables