Solved

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

Posted on 2010-09-20
11
5,925 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
Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one 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

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

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…
This article discusses how to implement server side field validation and display customized error messages to the client.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…

726 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