Jump to content

To Do List / Homework Manager


benrothwell

Recommended Posts

Hi,

 

Trying to build a simple homework manager for the school I am Head of ICT in, using PHP and MySQL. Currently at the design stage - so no code to share yet. But I will share with you how I intend to get it working, and the issue I have...

 

I anticipate having 5 tables

 

Table 1

Student_ID  |  Student_name

 

Table 2

Class_ID  |  Teacher_name

 

Table 3

 

Student_ID  |  Class_ID

 

Table 4

 

Class_ID  | Class_name

 

Table 5

 

Class_ID | Activity | Date_set | Date_due | Visible

 

So, at its simplest it should be possible to select from the database all classes that match your student_id and show the homework set for those. Also, I have a visible tag set so that teachers can pseudo delete homeworks using a small control panel.

 

But what I would like to do, is allow the students to set whether or not they have done the homework (kind of like a task in remember the milk) - but obvioulsy they cant have access to the database.

 

Anyone got any idea how this could be achieved?

Link to comment
Share on other sites

I would change that design slightly and have a new table to store teachers e.g.

 

Teachers ( id, firstname, lastname, gender )

 

Then there is no need for your table #2

 

Then finally in table #4 I would add the teacher like

 

Table 4 (id, teacher_id, classname )

 

 

As for the homework part, I'd have this structure

 

Homework ( id, class_id, description, duedate )

 

Homework_Assoc ( id, homework_id, student_id, completed )

 

So you'll need a login system to allow the student to login, then have a page that lists out all their homework and let them declare when a homework is complete using something like a checkbox. In the backend you'd be inserting a row into Homework_Assoc and setting completed to 1 (or 0 if the student decided they in fact haven't completed it after declaring they had, or just delete the row instead of setting to 0).

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.