Jump to content

PHP 2 Week date Schedule


welch

Recommended Posts

im at a bit loss on how to start a 2 week schedule with php.

 

What would be the best way to generate a table of 2 weeks ahead worth of options?

 

Dec 4th 2007

--------------------------------------------------------------

Date    | Am | PM | EV

12 / 4  | 1    |  1  |  1

12 / 5  | 1    |  1  |  1

12 / 6  | 1    |  1  |  1

 

and so on.

 

Thanks

Matt

Link to comment
https://forums.phpfreaks.com/topic/80112-php-2-week-date-schedule/
Share on other sites

you need to structure the table like this

 

RowID Integer

SchedDate date

SchedTime time

SchedWho Varchar 50

SchedEvent Varchar 255

 

and then you enter items as needed, you don't enter a table of all 2 weeks, it's a moving target and if you fill a database table with all dates for all people it will be immense,

 

when you query you just from current date + 2 weeks

and if it only returns 3 records that is fine you just show them.

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.