Question

In: Computer Science

Create a student attendance form in php. please provide source code examples

Create a student attendance form in php. please provide source code examples

Solutions

Expert Solution

the following source code will help you to understand the student attendance form

source code:

SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";

CREATE TABLE IF NOT EXISTS `attendance` (

`student` varchar(40) DEFAULT NULL,

`regno` varchar(40) DEFAULT NULL,

`week` varchar(40) DEFAULT NULL,

`date` date DEFAULT NULL,

`unit` int(10) unsigned DEFAULT NULL,

`attended` varchar(40) DEFAULT NULL,

`id` int(10) unsigned NOT NULL AUTO_INCREMENT,

PRIMARY KEY (`id`),

KEY `student` (`student`),

KEY `unit` (`unit`)

) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=3 ;

INSERT INTO `attendance` (`student`, `regno`, `week`, `date`, `unit`, `attended`, `id`) VALUES

('TED/118/16', 'TED/118/16', '1', '2018-01-30', 2, '1', 1),

('COM/016/16', 'COM/016/16', '1', '2018-01-30', 1, '1', 2);

CREATE TABLE IF NOT EXISTS `courses` (

`id` int(10) unsigned NOT NULL AUTO_INCREMENT,

`name` varchar(40) DEFAULT NULL,

PRIMARY KEY (`id`)

) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=4 ;

INSERT INTO `courses` (`id`, `name`) VALUES

(1, 'Technology Education'),

(2, 'Computer Science'),

(3, 'Bussiness Administration');

CREATE TABLE IF NOT EXISTS `membership_grouppermissions` (

`permissionID` int(10) unsigned NOT NULL AUTO_INCREMENT,

`groupID` int(11) DEFAULT NULL,

`tableName` varchar(100) DEFAULT NULL,

`allowInsert` tinyint(4) DEFAULT NULL,

`allowView` tinyint(4) NOT NULL DEFAULT '0',

`allowEdit` tinyint(4) NOT NULL DEFAULT '0',

`allowDelete` tinyint(4) NOT NULL DEFAULT '0',

PRIMARY KEY (`permissionID`)

) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=9 ;

INSERT INTO `membership_grouppermissions` (`permissionID`, `groupID`, `tableName`, `allowInsert`, `allowView`, `allowEdit`, `allowDelete`) VALUES

(1, 2, 'students', 1, 3, 3, 3),

(2, 2, 'units', 1, 3, 3, 3),

(3, 2, 'courses', 1, 3, 3, 3),

(4, 2, 'attendance', 1, 3, 3, 3),

(5, 3, 'students', 1, 1, 1, 1),

(6, 3, 'units', 1, 1, 1, 1),

(7, 3, 'courses', 1, 1, 1, 1),

(8, 3, 'attendance', 1, 1, 1, 1);

CREATE TABLE IF NOT EXISTS `membership_groups` (

`groupID` int(10) unsigned NOT NULL AUTO_INCREMENT,

`name` varchar(20) DEFAULT NULL,

`description` text,

`allowSignup` tinyint(4) DEFAULT NULL,

`needsApproval` tinyint(4) DEFAULT NULL,

PRIMARY KEY (`groupID`)

) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=4 ;

INSERT INTO `membership_groups` (`groupID`, `name`, `description`, `allowSignup`, `needsApproval`) VALUES

(1, 'anonymous', 'Anonymous group created automatically on 2018-01-30', 0, 0),

(2, 'Admins', 'Admin group created automatically on 2018-01-30', 0, 1),

(3, 'Lecturer', 'lecturers can join group and add their courses and units and their students', 1, 0);

CREATE TABLE IF NOT EXISTS `membership_userpermissions` (

`permissionID` int(10) unsigned NOT NULL AUTO_INCREMENT,

`memberID` varchar(20) NOT NULL,

`tableName` varchar(100) DEFAULT NULL,

`allowInsert` tinyint(4) DEFAULT NULL,

`allowView` tinyint(4) NOT NULL DEFAULT '0',

`allowEdit` tinyint(4) NOT NULL DEFAULT '0',

`allowDelete` tinyint(4) NOT NULL DEFAULT '0',

PRIMARY KEY (`permissionID`)

) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;

CREATE TABLE IF NOT EXISTS `membership_userrecords` (

`recID` bigint(20) unsigned NOT NULL AUTO_INCREMENT,

`tableName` varchar(100) DEFAULT NULL,

`pkValue` varchar(255) DEFAULT NULL,

`memberID` varchar(20) DEFAULT NULL,

`dateAdded` bigint(20) unsigned DEFAULT NULL,

`dateUpdated` bigint(20) unsigned DEFAULT NULL,

`groupID` int(11) DEFAULT NULL,

PRIMARY KEY (`recID`),

KEY `pkValue` (`pkValue`),

KEY `tableName` (`tableName`),

KEY `memberID` (`memberID`),

KEY `groupID` (`groupID`)

) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=11 ;

INSERT INTO `membership_userrecords` (`recID`, `tableName`, `pkValue`, `memberID`, `dateAdded`, `dateUpdated`, `groupID`) VALUES

(1, 'courses', '1', 'admin', 1517324670, 1517324670, 2),

(2, 'courses', '2', 'admin', 1517324701, 1517324701, 2),

(3, 'courses', '3', 'admin', 1517324738, 1517324738, 2),

(4, 'units', '1', 'admin', 1517324782, 1517324782, 2),

(5, 'units', '2', 'admin', 1517324809, 1517324809, 2),

(6, 'students', 'TED/118/16', 'admin', 1517324964, 1517324964, 2),

(7, 'students', 'COM/016/16', 'admin', 1517325016, 1517325016, 2),

(8, 'students', 'BBA/09/16', 'admin', 1517325066, 1517325066, 2),

(9, 'attendance', '1', 'admin', 1517325147, 1517325147, 2),

(10, 'attendance', '2', 'admin', 1517325189, 1517325189, 2);

CREATE TABLE IF NOT EXISTS `membership_users` (

`memberID` varchar(20) NOT NULL,

`passMD5` varchar(40) DEFAULT NULL,

`email` varchar(100) DEFAULT NULL,

`signupDate` date DEFAULT NULL,

`groupID` int(10) unsigned DEFAULT NULL,

`isBanned` tinyint(4) DEFAULT NULL,

`isApproved` tinyint(4) DEFAULT NULL,

`custom1` text,

`custom2` text,

`custom3` text,

`custom4` text,

`comments` text,

`pass_reset_key` varchar(100) DEFAULT NULL,

`pass_reset_expiry` int(10) unsigned DEFAULT NULL,

PRIMARY KEY (`memberID`),

KEY `groupID` (`groupID`)

) ENGINE=MyISAM DEFAULT CHARSET=utf8;

INSERT INTO `membership_users` (`memberID`, `passMD5`, `email`, `signupDate`, `groupID`, `isBanned`, `isApproved`, `custom1`, `custom2`, `custom3`, `custom4`, `comments`, `pass_reset_key`, `pass_reset_expiry`) VALUES

('guest', NULL, NULL, '2018-01-30', 1, 0, 1, NULL, NULL, NULL, NULL, 'Anonymous member created automatically on 2018-01-30', NULL, NULL),

('admin', '21232f297a57a5a743894a0e4a801fc3', '[email protected]', '2018-01-30', 2, 0, 1, NULL, NULL, NULL, NULL, 'Admin member created automatically on 2018-01-30', NULL, NULL);

CREATE TABLE IF NOT EXISTS `students` (

`regno` varchar(40) NOT NULL,

`name` varchar(100) NOT NULL,

`course` varchar(40) DEFAULT NULL,

PRIMARY KEY (`regno`),

KEY `course` (`course`)

) ENGINE=MyISAM DEFAULT CHARSET=utf8;

INSERT INTO `students` (`regno`, `name`, `course`) VALUES

('TED/118/16', 'John Doe', '1'),

('COM/016/16', 'Mark Zuckerburg', '2'),

('BBA/09/16', 'Bill Gates', '3');

CREATE TABLE IF NOT EXISTS `units` (

`id` int(10) unsigned NOT NULL AUTO_INCREMENT,

`name` varchar(40) DEFAULT NULL,

PRIMARY KEY (`id`)

) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=3 ;

INSERT INTO `units` (`id`, `name`) VALUES

(1, 'IRD 200'),

(2, 'EDF 211');


Related Solutions

- Create an html form (bank form) and the PHP code with 2 accounts with options...
- Create an html form (bank form) and the PHP code with 2 accounts with options to transfer, deposit or withdraw money.
Utilizing PHP and HTML code Create a form that has text inputs for two numbers and...
Utilizing PHP and HTML code Create a form that has text inputs for two numbers and a submit button. Submit the values to a program that calculates and displays the GCD of the two numbers. The greatest common divisor of two integers a and b is the largest integer that is a factor of both a and b. The GCD of any number and 1 is 1, and the GCD of any number and 0 is that number. For example:...
Using PHP, Create a form that uses the method POST to send the information. The form...
Using PHP, Create a form that uses the method POST to send the information. The form should capture the distance the package needs to travel with the one field for the distance in miles. All fields should have the REQUIRED attribute. The form should have a submit button and reset button. The form should look nice. All the labels should line up horizontally and all the INPUTS/SELECT should line up horizontally.
Using PHP, create a form that uses the method GET. The form should capture a date...
Using PHP, create a form that uses the method GET. The form should capture a date using two numbers        Month (1 - 12) and Day (1 - 31) Make sure the form is filled with the user's input after the form is submitted and processed, and the page is redisplayed. If data is being passed into the page, then the page should display the date entered by the user and the season of the year. For example, if the...
Please create a PHP action codes for the HTML CODE provided below. <!DOCTYPE html> <html> <head>...
Please create a PHP action codes for the HTML CODE provided below. <!DOCTYPE html> <html> <head> <title> Project for keeping all your input </title> </head> <body> <h1>Welcome to this Web Based Test!!!</h1> <p>Please answer the following questions:</p> <hr/> <form action="" method="post"> Name: <input type="text" name="name" value=""> <font color=red>*</font><br/><br/> E-mail: <input type="text" name="email" value=""> <font color=red>*</font><br> <hr/> Choose your major area of study: <select name="major"> <option value="Digital Media" >Digital Media</option> <option value="Software" >Software</option> <option value="Security" >Security</option> <option value="Business" >Business</option> <option value="Other"...
Please provide HTML code for the following: - Create a page that lists a set of...
Please provide HTML code for the following: - Create a page that lists a set of audio files and shows their duration - Create a page that lists a set of video files and plays a different video when you click on the play icon
Please create a response to the following discussion post form a student: Avon had a business...
Please create a response to the following discussion post form a student: Avon had a business strategy that relied heavily on the international market, specifically in developing nations (Hill, 2015). The strategy may have continued to be successful had it not been for the sudden ban on direct sales marketing in China and the steadily declining economies of Russia, Mexico, and Eastern Europe (Hill, 2015). The reason the foreign market was so valuable to Avon is that when the company...
Using C# Windows App Form Create a simple calculator using +,-,*,/ Please show code GUI Code...
Using C# Windows App Form Create a simple calculator using +,-,*,/ Please show code GUI Code for calculator menus radio button input text boxes
At what point does commercialization start to create inequality? Please provide examples.
At what point does commercialization start to create inequality? Please provide examples.
I need this code in C++ form using visual studios please: Create a class that simulates...
I need this code in C++ form using visual studios please: Create a class that simulates an alarm clock. In this class you should: •       Store time in hours, minutes, and seconds. Note if time is AM or PM. (Hint: You should have separate private members for the alarm and the clock. Do not forget to have a character variable representing AM or PM.) •       Initialize the clock to a specified time. •       Allow the clock to increment to the...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT