PDA
Partners

View Full Version : downloaded php/mysql poll. Seems to work, but isn't. No errors, though


WorldBuilder
January 26th, 2004, 08:32 PM
Hi guys, I have another one. I downloaded a php/mysql script for an online poll. I have follwed the instructions, done everything right (I think) and this is not working. It looks fairly complex and since i'm still in the learning stages, I'm stuck. I got the script from here (http://www.widgetmonkey.com/app.php?id=2).

I attached the files necessary to this post. My use of the script can be found here (http://www.bartlett-family.net/quiz/index.php). As you can see, all there is is the "See how you did" button. In phpmyadmin, I created a database named "quiz", a table in that database also named "quiz", and the necessary 7 fields: id, question, opt1, 2, 3, answer, and q. I also created a user: "quiz"

When I try to add questions through the "editquiz.php" file in a browser, it seems to work, but no questions show up.

I don't even know where to begin debugging. Is it a mysql or php problem? I've been working on it all day, have made a little progress here and there, but am stumped. Any help would be most appreciated. Thanks!

Chris

maverik60
January 26th, 2004, 09:02 PM
quiz@yourhost.com is what should be ithink. if u put quiz then it shouldnt work >.<

WorldBuilder
January 26th, 2004, 09:04 PM
I don't understand what you mean by that. Actually, I just noticed some mysql errors in the browser. I think I screwed up some permissions somewhere. I wasn't getting these earlier. What do you mean?

Chris

That was a password problem. I had changed my password in the .sql file (it's in the zipped package attached above) to xxxx, but forgot to change it back to normal on my server :p). Now, you'll see what I mean on the web. Sorry about that.

ZYV
January 27th, 2004, 02:44 AM
I am not sure, but it looks like just another register_globals problem... Try to alter config.php as you did for the flash poll script.

WorldBuilder
January 27th, 2004, 08:56 AM
Yeah, I thought about that last night after I walked away from it for a while. You're right. I added extract($_COOKIE); extract($_POST); extract($_GET); extract($_SERVER); and it works like a charm. Thanks again. ;)

Chris

ZYV
January 27th, 2004, 09:42 AM
Glad that it helped.