GithubHelp home page GithubHelp logo

deathnerd / ekulms Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 1.0 3.74 MB

A simple Learning Management System for Eastern Kentucky University

Python 0.28% Shell 0.66% PHP 67.24% JavaScript 15.39% CSS 16.40% Perl 0.05%

ekulms's People

Contributors

deathnerd avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Forkers

kawingwong

ekulms's Issues

Getting these errors after install

checkIsSet(array($user_name), array(""))) { //if not logged in already, go to login page $Utils->redirectTo('signin.php'); } /* * Class declarations _/ $UI = new UI($SERVER['PHP_SELF'], "Index - EKULMS"); $errors = array(); $user = $Users->fetchUser($user_name); / * The very unlikely chance that the user isn't in the database / if (!$user) { array_push($errors, "Well this is awkward... The user was not found in the database"); } $enrolled_courses = $Courses->fetchEnrolledCourses($user_name, 'student'); / * If the user isn't enrolled in a course, prompt them to enroll in one / if (!$enrolled_courses) { array_push($errors, "It appears you are not enrolled in a course. Please enroll in one"); } / * Build a list of tests / $list_of_tests = array(); foreach ($enrolled_courses as $course) { $allByCourseId = $Tests->fetchAllByCourseId($course['courseId']); if ($allByCourseId) { $list_of_tests[$course['courseName']][] = $allByCourseId; } else { continue; } } / * Count the errors and build the error message / $errors_to_display = ""; if (count($errors) > 0) { foreach ($errors as $error) { $errors_to_display .= "$error
"; } } /
* Get the tests available to the student and build the list / $test_options = ""; if (count($list_of_tests) > 0) { $test_options = ""; foreach ($list_of_tests as $course) { foreach ($course as $test) { foreach ($test as $t) { $test_options .= ""; } } } } / * Update the template variables / / * Set the template variables with the new values, parse the header template, and show the header and footer */ if(boolval($_SESSION['admin'])){ $UI->addToTemplateVariables(array("admin_link" => "
Admin Area
")); } $UI->addToTemplateVariables(array("errors_to_display" => $errors_to_display, "test_options" => $test_options, "description" => "Tests for EKULMS", "home_active" => 'active')) ->executeHeaderTemplate("index_header") ->show("header")->show("footer"); exit();

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.