change constants names add $db instance
change constants, add require db from lib, add table names to $wpdb
add statistics count of classes, students