Solved

php code to remind of important dates

Posted on 2011-09-12
1
318 Views
Last Modified: 2013-11-13
Hi,

I was wondering where would i start about finding php that reminded me via a web page of dates? i have seen them on socail networking sites, does anybody know where i would start?

Thank you so much
0
Comment
Question by:jonathanduane2010
1 Comment
 
LVL 108

Accepted Solution

by:
Ray Paseur earned 250 total points
ID: 36526349
Start by learning about how PHP and MySQL work together to handle DATETIME values.
http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/PHP/A_201-Handling-date-and-time-in-PHP-and-MySQL.html

The next thing you might do is get this little book and work through the examples.   They do not have exactly what you want, but you will need some standard programming ideas, and SitePoint is very good at providing those in clear explanations.
http://www.sitepoint.com/books/phpmysql4/

The general design pattern you would follow would be to have a MySQL table with two columns.  One would be a DATETIME column and one would be a VARCHAR column.  You would have a table-maintenance script that would allow you to add the dates and the reminders.  Your PHP-driven web page would get the current date, turn it into an ISO-8601 string and query the data base for anything that was greater than the current date value.  It might display the next three reminders, for example.  To do that you would use LIMIT 3 in your query.

HTH, ~Ray
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Envision that you are chipping away at another e-business site with a team of pundit developers and designers. Everything seems, by all accounts, to be going easily.
This article discusses how to create an extensible mechanism for linked drop downs.
The viewer will learn how to count occurrences of each item in an array.
The viewer will get a basic understanding of what section 508 compliance can entail, learn about skip navigation links, alt text, transcripts, and font size controls.

760 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

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now