DragonflyCMS Projects > Weather Harvest > Database error after clicking [Save Changes] avatar change > Community Forums > Phoenix Netology
Forum Index > Miscellania > Weather Harvest

Database error after clicking [Save Changes] avatar change Reply to topic


When a user changes their avater then clicks the [Save Changes] button they are presented with the blank white screen stating a database error has occured and the administrator has been notified. The avatar does change even with the error and the rest of the site is working. it is more of an annoyance that my user's see this and may be the tip of the ice burg for a bigger problem. This is on a new site install with only a few modules installed. The wierd thing is the SQL error has noting to do with avatars or the user account but it is saying the error is a SQL error with my weather module. here are the details e-mailed to me when a user gets this error:

--------------------
On /index.php?name=Your_Account
While executing query "SELECT * FROM cms_weatherdefaults WHERE uid="

the following error occured: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

In: /home1/clubsour/public_html/blocks/block-WeatherHarvest_small.php on line: 64

Guest information:
User id:
Username:
Admin: No
IP: 0.0.0.0
Host: 0.0.0.0

------------------------------

I am guessing the erro is coming from a null username as both the IP, Host, ID, and username all show blank in the error. Another could be related issue is one user report being automatically logged out when trying to click My Account. I have done many searches for this error and have come up empty handed. I have researched the line and file mentioned but the code looks ok as far as syntax errors. I have re-installed the weather module without a resolve. If I uninstall the weather module my site blows up and even visiting the home page returns a database error.

Anyone else ever encounter this before?

Please enter your server specs in your user profile! 😢


I don't provide that block - you should follow the advice you were already given - contact the author, layingback.

I don't have time to chase something up that, at this point, isn't of my doing.

Donations & Audit for DragonflyCMS

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):


Wow I went to the site that was listed on the download of this module and it took me here where there just happened to be a Weather forum. Why is this link the hompage for that module?

i thought forums related to a specific subject were there for the community to help and then once a solution is found others may need the same answer. Is this forum here just to waste space?

Please enter your server specs in your user profile! 😢


True, but I didn't provide that customized block and you certainly didn't download it from here.

I have no knowledge of it, or the time to investigate someone else's adaptation.

Donations & Audit for DragonflyCMS

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):


Sorry I thought I got the module from the downloads section of cpgnuke, but now I see what your are refering too. This module has a different name. I normally only download confirmed modules from cpgnuke and have used your on many sites because in the past it worked so well. I have no clue how I got this bastard download mixed up.

Sorry for the confusion and you were in the right, I just didnt relize we were talking about a customized version and not the original. Bummer that my site crashes without the bastard version being installed. I hope I can lay yours over the top without causing too many headaches.

Guess that should be a good leason for me and others. Make sure you got the legit stuff before uploading.

Please enter your server specs in your user profile! 😢


It's not the module I'm referring to, but block-WeatherHarvest_small.php that you got the error with. I didn't provide that block and have no knowledge of it - looks like you got that from layingback.net.

Whether your problem turns out to be that block, or the module (which I am responsible for) or something else entirely, the thing is that you need to start with the source of your error - the block. Just deactivate that block and see what happens from there.

In any event, I'm not even sure if WH is compatible with DF 9.2.x yet - I've only tested to 9.1.x.

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):


I was finally able to uninstall the WH module without crashing the site and installed the 9.2 version from cpgnuke downloads 9.2 section. Guessing they just copied and pasted the 9.1 version since you said that you have not made a compatible version for 9.2 yet.

Unfortuantly it looks like the compatibility may be the problem. As all the WH blocks caused the same type of error. When disabling the blocks the problem does go away. Also I tested a center and left block, both causing the problem.

Guess I will wait for a new version release, but no biggie if there will not be one. I will provide the e-mail infomration I recieved during my testing in case you are interested.

Thanks for the help and good luck in the future.




On /index.php?name=Your_Account
While executing query "SELECT * FROM cms_weatherdefaults WHERE uid="

the following error occured: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

In: /home1/clubsour/public_html/blocks/block-WeatherHarvest.php on line: 44

Guest information:
User id:
Username:
Admin: No
IP: 0.0.0.0
Host: 0.0.0.0




On /index.php?name=Your_Account
While executing query "select * from cms_weatherdefaults where uid="

the following error occured: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

In: /home1/clubsour/public_html/blocks/block-WHExtendFcast_ctr.php on line: 44

Guest information:
User id:
Username:
Admin: No
IP: 0.0.0.0
Host: 0.0.0.0

Please enter your server specs in your user profile! 😢


I cannot duplicate your error plus a quick check of existing block code doesn't suggest any coding issues.

What may be the problem is some add-on you are using that adds a "block" section within Your_Account and is incorrectly emptying the $userinfo global.

Just check which blocks show when viewing a profile,
e.g. Phoenix's Last 10 Donations:
Then ensure that you have latest versions of add-ons installed.

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):

All times are Australia/Adelaide


Jump to: