Made the script property default to the dynamic class id if specified or the dynamic class name otherwise