本文整理汇总了PHP中student::getRemCourses方法的典型用法代码示例。如果您正苦于以下问题:PHP student::getRemCourses方法的具体用法?PHP student::getRemCourses怎么用?PHP student::getRemCourses使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类student
的用法示例。
在下文中一共展示了student::getRemCourses方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: nl2br
$done = array($course1, $course2, $course3, $course4, $course5, $course6, $course7, $course8, $course9, $course10, $course11, $course12);
//creating an array of courses that needs to be taken
$todo = array($course13, $course14, $course15, $course16, $course17, $course18, $course19, $course20, $course21, $course22, $course23, $course24, $course25, $course26, $course27, $course28);
$labs = array();
$tutorials = array();
// emtpy arrays for constructor
//Creating a new student with aforementioned courses
$lordGaben = new student(2546011, $done, $todo, $labs, $tutorials);
//printing out the course of LordGaben
echo nl2br("printing out the courses taken by LordGaben\n");
foreach ($lordGaben->getCoursesTaken() as $course) {
echo nl2br($course->getCode() . ' ' . $course->getName() . ' ' . $course->getDescription() . ' ' . $course->getSemester() . ' ' . $course->getSection() . ' ' . $course->getCredits() . "\n");
}
//printing out the course to be taken by LordGaben
echo nl2br("printing out the courses to be taken by LordGaben \n");
foreach ($lordGaben->getRemCourses() as $course) {
echo nl2br($course->getCode() . ' ' . $course->getName() . ' ' . $course->getDescription() . ' ' . $course->getSemester() . ' ' . $course->getSection() . ' ' . $course->getCredits() . "\n");
}
// echo serialize($done);
// echo unserialize(serialize($done));
//testing seriazable arrays
// foreach (unserialize(serialize($done)) as $course) {
// echo nl2br( $course->getCode() . ' ' . $course->getName() . ' ' . $course->getDescription() . ' ' . $course->getSemester() . ' ' . $course->getSection() . ' ' . $course->getCredits() . "\n" ) ;
// }
?>
</body>