Jump to content

timer-controlled input?


happysmile

Recommended Posts

Hi all,

 

I'm a newbie here and I might post this question in the wrong section. Please forgive me  ;D

 

I have to work at a project in a very short time and I do not know where to start from! Please help me  ::)

 

I have to create a website for a teacher who wants to ask some students to connect  to the internet at the same time, watch a distance lesson in real time (streaming video, but I am not working at that) and give immediate feedback during the lesson, so she can try to modify the lesson if people are not too interested.

 

Before worrying about input analysis and output, I have a much bigger problem.

How can I control the input (20 values for each connected student) with a timer?

Ideally I would need a button the teacher clicks, which starts a timer, so that before it starts no input is saved in the database. Also, I must save data every minute and for 20 minutes, after which no data is saved. Also, I would need a 'stop' button as well, in case the 'start' button has been clicked by mistake.

 

Please save me :)

 

Have a nice Sunday everyone!!!  8)

 

PS. I shouldn't worry about that yet, but is there a way to dynamically generate bar graphs with the data of the database?

Thanks a lot :)

 

Link to comment
Share on other sites

Hmm, well, you could always store the time that the teacher starts the timer, and wether or not you are accepting data.

 

Then, each time any data is supposed to be put into the database, you first check to see if you are supposed to be accepting data, and then you can check to see if the timer was started more or less than 20 minutes previously. If it is less than, you can put the data into the database, if it more than, you can update the field in the database to not accept data, and reject the data.

 

Perhaps you could improve this with cron jobs. Ive never used them so im not too sure.

 

PS. I shouldn't worry about that yet, but is there a way to dynamically generate bar graphs with the data of the database?

Thanks a lot :)

 

Definately. The GD library in php can be used to create graphs. One of the staff members on the site, barand, has written a class for creating charts. You might find it useful:

http://members.aol.com/barryaandrew/baaChart/baachartguide.html

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.