src/Course.php
//Save a course to courses table:
Save a course to courses table.
Save a course to courses table .
function save() {
        $statement = $GLOBALS['DB']->exec("INSERT INTO courses (course_name, crn)
                VALUES ('{$this->getCourseName()}', '{$this->getCRN()}');");
        $this->id = $GLOBALS['DB']->lastInsertId();
    }
function save ( ) { $ statement = $ GLOBALS [ 'DB' ] -> exec ( " INSERT INTO courses (course_name, crn)
                VALUES (' { $ this -> getCourseName ( ) } ', ' { $ this -> getCRN ( ) } '); " ) ; $ this -> id = $ GLOBALS [ 'DB' ] -> lastInsertId ( ) ; }
Save a course to courses table:
Save a course to courses table :