ajaxifying taking photo