Refacto heavy osc_esc_html calls in ajax_photos