javascript loop to check for rules and display errors
finished editor rule checking and error displaying