Solved

unable to pick up multiple rows...

Posted on 2012-04-09
3
234 Views
Last Modified: 2012-04-09
Hi, I have an application that populates an events calendar. For the most part  the application works as per my requirement. The only place where I am finding an issue is when I try to pick up multiple events on the same day. for eg, on April 10th I have scheduled two events but when I view my calendar only the last event is shown. Can someone let me know what I am doing wrong here. I have attached a part of my code that is used to pick up the events from the db. Thanks for the help.

A
events.php
0
Comment
Question by:aej1973
  • 2
3 Comments
 
LVL 108

Accepted Solution

by:
Ray Paseur earned 200 total points
ID: 37824240
It looks like maybe the code is using the event date as an array key?  Not sure, but if you do it that way, you can only have one event per day.  You might want to substitute the auto_increment kdy from the data base. It will always be unique.
0
 

Author Comment

by:aej1973
ID: 37824292
How do I do this Ray? The auto increment key in the db is visit_id.
0
 

Author Closing Comment

by:aej1973
ID: 37825814
Thanks for pointing me in the right direction.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Author Note: Since this E-E article was originally written, years ago, formal testing has come into common use in the world of PHP.  PHPUnit (http://en.wikipedia.org/wiki/PHPUnit) and similar technologies have enjoyed wide adoption, making it possib…
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

863 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

20 Experts available now in Live!

Get 1:1 Help Now