It is the duty of any physician, surgeon, obstetrician, midwife, nurse, maternity home or hospital of any nature, parent, relative, and any person or persons attendant upon, or assisting in any way whatsoever, either the mother or child, or both, at childbirth, to treat both eyes of the infant within two hours after birth with a prophylactic efficient treatment, and in all cases where the child develops within two weeks after its birth ophthalmia neonatorum, and such person knows it to exist, to report the case within 24 hours after knowledge, in such form as the department directs, to the local health officer of the county or city within which the mother of any such infant resides.