cleaned up JavaScript details_course as per Niks suggestions