Solved

How can i build a student attendance register with PHP/MySQL?

Posted on 2010-09-20
11
6,087 Views
Last Modified: 2013-12-12
Hi there,

I'm building a school intranet system. Everything has been a breeze so far but now i'm getting to building the student register.

I have the student contact table already but just need to build an attendance register,

It will be Monday to Friday and have AM and PM boxes.

Whats the best way to go about coding this as its wrecking my head.

If you need any more info please let me know :D

Thanks
0
Comment
Question by:projectstudios
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
  • 2
  • +1
11 Comments
 
LVL 7

Expert Comment

by:rangasuman
ID: 33720293
Hi,

There is a free open source PHP solution that might be useful to your requirement.
http://sourceforge.net/projects/freesms/

Goodluck.
0
 
LVL 12

Expert Comment

by:Rok-Kralj
ID: 33720534
If you will go to program it on your own...

Let's say you have a database table with students, each have an ID number.

You can then make an additional table to the database, named attendencies.

student_ID INT
class_start UNIX_TIMESTAMP
class_end UNIX_TIMESTAMP

0
 

Author Comment

by:projectstudios
ID: 33720638
Hi folks, thanks for replying. I've looked at the program you gave me @rangasuman but it seems to be very buggy and i cant even login after installing it.

@Rok-Kralj - The students table is setup, all with an ID number.

If i create a table like:


ID -student_id - date - time(if it's AM or PM) - Record

1 - 1 - 2010-09-20 - AM - B (B means present)

If i do that, it would mean all students would have 10  records a week. How could i then display those 10 rows in a table in one line. If i echo them they will all be displayed under one another?\

Thanks
0
Creating Instructional Tutorials  

For Any Use & On Any Platform

Contextual Guidance at the moment of need helps your employees/users adopt software o& achieve even the most complex tasks instantly. Boost knowledge retention, software adoption & employee engagement with easy solution.

 
LVL 110

Expert Comment

by:Ray Paseur
ID: 33720771
This would be a good place to hire a developer instead of trying to learn the entire design paradigm by asking "how" at EE.  But there are many examples available in the technical literature.  Is this by any chance a classroom assignment?  If so, we are prohibited by the TOS of EE from offering more than general guidance and learning resources.

Check the links here:
http://lmgtfy.com?q=PHP+MySQL+attendance+database
0
 

Author Comment

by:projectstudios
ID: 33720810
@Ray Paseur - Thanks for replying.. No this is not a classroom assignment. I'm basically building a local intranet site to keep our students information and attendance organised instead of being all in hundreds of word documents.

I have built pretty much everything else i need to build right now apart from this. I can't really afford to hire anyone to do this as im the one who is being paid to put together the system.

I just cannot find a way in my head which will be the best way to do this.

Any help or guidance will be much appreciated.

Thanks
0
 

Author Comment

by:projectstudios
ID: 33720825
Just to add also,

I have a way lined out in the DB but on the page it displays the results under one another and not in the same row of the html table.

Does anyone know how i can get it to display all the result from the query in one HTML table row?
0
 
LVL 110

Expert Comment

by:Ray Paseur
ID: 33721020
OK, here are the tables I would probably use.

Students with names, Classes with DATETIME.

Each time a student attends a class, you would add a row to a pivot table that associates the Student with the Class.  Your queries can join these tables together to create the attendance roster.
0
 
LVL 110

Expert Comment

by:Ray Paseur
ID: 33721034
I'm not sure I can envision how an attendance record could be produced in a single row of HTML.  I think formatting the output is really a different question from designing the DB tables and queries.
0
 

Author Comment

by:projectstudios
ID: 33721056
Awesome, i shall give it a go tomorrow. I'm guessing instead of having classes in a table, i could just have Morning & Afternoon as periods?
0
 
LVL 110

Accepted Solution

by:
Ray Paseur earned 500 total points
ID: 33721269
Yes, you could have something that simple and it would be workable, or you could use DATETIME columns to identify the class times.
0
 
LVL 12

Expert Comment

by:Rok-Kralj
ID: 33722584
This application can be as complicated as you want it to be.

You can have a table of students, teachers, classrooms, classes (connects teacher and classrom at certain time), class_attendencies (connects students to classes), etc...
0

Featured Post

Why Off-Site Backups Are The Only Way To Go

You are probably backing up your data—but how and where? Ransomware is on the rise and there are variants that specifically target backups. Read on to discover why off-site is the way to go.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

All of the resources available today make learning a new digital media easier than ever-- if you know where to begin. This is a clear, simple guide to a few of the basic digital art mediums and how to begin learning them on your own.
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question