Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 01-21-2009, 11:19 PM   #1
Registered User
 
Join Date: Nov 2007
Posts: 45
Default What changed since last night?

Why won't this work today? I was able to query my database last night, but today no joy. (OK, I did have some problems -- I was able to create records but MySQL wasn't returning any value -- but today I realized I had insufficient permissions, which I have repaired.)

This should work, right?

Code:
$output = "<ids>\n";

if ($result = $mysqli->query($query)) {
	while( $row = $result->fetch_assoc() ) {
		$output .= "\t<eventid>" . $row['eventid'] . "</eventid>\n";
		$output .= "\t<eventeditid>" . $row['eventeditid'] . "</eventeditid>\n";
	}
	
	$result->close(); 
}
$output .= "</ids>";

$mysqli->close();
My forehead is so bloody and pulpy that maybe I'm missing something.

Any help would be appreciated,

Thanks,
Jennifer

PS I know my query is correct. I can paste it into phpMyAdmin and it works. I just can't query the database from PHP. I also know that PHP is processing the query properly (ie: converting variables in the query) because PHP is returning the query to Flash and that's what I'm pasting into phpMyAdmin.
petkusj@virtualight.com is offline   Reply With Quote
Old 01-22-2009, 03:24 AM   #2
Registered User
 
Join Date: Nov 2007
Posts: 45
Default

I am such an idiot. Somehow this:

if ($mysqli->multi_query($query)) {

became this:

if ($mysqli->query($query)) {

That's what happens when you cut and paste scripts and you don't pay attention.

Jennifer
petkusj@virtualight.com is offline   Reply With Quote
Old 01-22-2009, 03:41 AM   #3
CyanBlue
Super Moderator
 
CyanBlue's Avatar
 
Join Date: Jan 2002
Location: Centreville, VA
Posts: 26,666
Default

Glad to hear that you found the problem quick... That's type of error that's somewhat hard to find...
__________________
CyanBlue / Jason Je / Macromedia Certified Flash Developer & Designer
http://CyanBlue.FlashVacuum.com
http://www.FlashVacuum.com
http://tutorials.FlashVacuum.com

Do NOT PM, Email or Call me... Your question belongs right in this forum...
CyanBlue is offline   Reply With Quote
Old 01-22-2009, 03:45 AM   #4
Registered User
 
Join Date: Nov 2007
Posts: 45
Default

Thanks, it was hard to find. Had to step away for a while and when I looked at the code again, it jumped out at me.

Yeah, me!
petkusj@virtualight.com is offline   Reply With Quote
Old 01-22-2009, 03:50 AM   #5
CyanBlue
Super Moderator
 
CyanBlue's Avatar
 
Join Date: Jan 2002
Location: Centreville, VA
Posts: 26,666
Default

Yay!!!
__________________
CyanBlue / Jason Je / Macromedia Certified Flash Developer & Designer
http://CyanBlue.FlashVacuum.com
http://www.FlashVacuum.com
http://tutorials.FlashVacuum.com

Do NOT PM, Email or Call me... Your question belongs right in this forum...
CyanBlue is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Night and Day Based on users clock 2UseLess2 ActionScript 2.0 8 09-03-2008 03:25 PM
Checking if the text box value is changed. rajeshambady ActionScript 2.0 5 07-16-2006 05:25 AM
How to make an object "listen" for when one of its properties is changed? retrotron ActionScript 1.0 (and below) 2 05-04-2003 03:29 PM
Need a hittest...I think Napalm ActionScript 1.0 (and below) 0 04-02-2003 06:34 AM
Day and Night troyhipolito ActionScript 1.0 (and below) 3 12-30-2002 04:11 PM


All times are GMT. The time now is 11:18 AM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.