It depends. For instance, the Pennsylvania Department of Transportation doesn't regulate online traffic school. A judge may still allow you in this case, but you have to ask permission. Look for schools and courses that are state-approved.