add functions
apply view to html
add time, loading