PDA

View Full Version : Ever Have 'One of Those Days'?


Sualdam
06-14-2003, 08:24 PM
I've been working on this small project - an online 'to do list' application - all day and I've been pulling my hair out.

It's dead simple - it uses PHP to write new 'to do' items to a text file. Then, it reads the text file in, splits it into a multi-dimensional array for display purposes.

The problem I've had is that no matter how I try, when you add a new record it duplicates the entire text file contents in the display window. SO you get two of everything.

After just about every possible attempt to debug, I've just found the problem. I have a string called 'mainStr' which is the new record data. I clear this string out when the 'submit' button is pressed.

Trouble is, I'd called it 'minStr' (damned typo).

Aaargh. The whole day it's taken me to find that.

Timmee_3Styler
06-14-2003, 09:13 PM
yup, happens alot of times... I remember doing a computer exam once, it was a graph generator for java, and as I was finished... I kept testing n testing but only a blank screen with a few numbers appeared

I 4got I have implemented a test screen where it outputs the value of some variables and waits for my user input b4 generating the screen.......

took me 30 minutes of rewiring the code before realizing it was a stupid mistake...... :( luckity didnt do too bad on the exam tho