-
Invité
- rang:
- 1
- enregistré depuis:
- décembre 2003
- Status:
- hors ligne
- dernière visite:
- 06.03.05
- Messages:
- 0
Hi, I'm tyring to install the weather module 1.30 under postnuke 0.726, for Antwerp - Belgium but get following error when adding a location:
Error updating information in database
I entered West-Europe - Belgium and then 'BEXX0003' for Antwerp and then 'Antwerp' for city.
What am I doing wrong?
Thanks, G -
- rang:
-
Site Admin
- enregistré depuis:
- décembre 2003
- Status:
- hors ligne
- dernière visite:
- 09.10.08
- Messages:
- 266
Hello,
Normaly, you shouldn't have to enter the code yourself. So I think the error you get is because BEXX0003 is already in the database (wich is the case if you added the Belgium city package)
Here the complete procedure, if you already installed the Belgium city package you can omit the first steps.
Just go to the administration panel of the weather module and click on the "Install city package(s)" link.
Choose Belgium in the menu and click on the "Install city package(s) button. Please be carefull NOT to click on the "Install ALL city package(s)" button as this will install thousands of city and render the module very very slow (and you will have to delete the packages one by one, and yes I made the mistake myself one day, I should add a confirmation !!)
You should see "Package added to the database" on the first line if everything goes well.
Now click on the "Change default local weather" link
Choose Western Europe as region and click on the select button on the first line
Belgiun should be available in the Country list on the second line, choose it and click on the select button on the second line
As Belgium has no subdivision, nothing is necessary on the third line
Select Antwerp on the fourth line and click on the corresponding select button
Choose temperature and wind speed units
AND DON'T FORGET TO CLICK ON THE "Save changes" BUTTON (I made the mistake myself several times !!)
If anything goes wrong in the process it's the sign of an incorrect install (or upgrade if you had a previous version installed) so please mail me and I will send you detailed instruction to be sure to do a "clean" install
NOTE : The only cases where I saw installation going wrong is when previous version were installed and badly or incompletely unistalled (I had a lot of problem writing the install and update parts of the program because several patched versions of 1.26, 1.27 and 1.28 are available on the web)
As a last solution it is possible to :
- deactivate and remove the weather module in the modules administration panel
-completely erase the weather folder in the modules folder
- use phpmyadmin to drop the 7 tables of the modules in your mysql database (these tables have name like (yourprefix)_wthr_ where (yourprefix) is the common prefix to all your tables, it's normaly nuke_ if you didn't change it during PostNuke installation)
- do aclean install
But normally you shouldn't have to use such extreme solution !! -
Invité
- rang:
- 1
- enregistré depuis:
- décembre 2003
- Status:
- hors ligne
- dernière visite:
- 06.03.05
- Messages:
- 0
Thanks it works now! Reason was probably that I tried to enter the code myself.
BTW, do you happen to know whether there's a dutch language file available for weather module?
Thanks again, G -
- rang:
-
Site Admin
- enregistré depuis:
- décembre 2003
- Status:
- hors ligne
- dernière visite:
- 09.10.08
- Messages:
- 266
Hello,
Unfortunately there is no dutch langage file available that I know of. As I only speak french and english, I can't make one (the german one was done by Juergen Hofmann [jh@jh-edv.com] one of my testers)
If you wanted to contribute, you are welcome !!
Here is the process
- all the langages files are in 2 folders : lang for the block (1 file) and pnlang for the module (6 files)
go in one of these folders and copy the folder of the most familiar langage for you
paste and change the name of the new folder to the 3 letters for dutch langage (I don't know them for france it's fra, eng for english, ...)
open that folder and edit each file in it
each line has the form
define('_WEATHERSETTINGS', 'Change settings');
you should only change the last string (Change settings in the above example) to the correct translation in your langage
CAUTION : I don't know if the dutch langage use simple quote like this ' if this is the case you should put a \ before each quote in your translated string. Example :
define('_UNSAVEDSETT', 'Current unsaved settings. Click on \'Save Changes\' at the bottom to start using these new settings.');
repeat this process for all the line in the file
repeat this process for all the file in the folder
repaet this process for the 2 pnlang and lang folders
upload and test
send your work to me ... -
Invité
- rang:
- 1
- enregistré depuis:
- décembre 2003
- Status:
- hors ligne
- dernière visite:
- 06.03.05
- Messages:
- 0
I am having a similar problem.
I have removed the entire folder, made sure the tables were deleted, then re-uploaded, initialised and activated.
When I go into the weather admin and try to install a city package i get a error:
"Error updating information in database"
have tried twice now. -
Invité
- rang:
- 1
- enregistré depuis:
- décembre 2003
- Status:
- hors ligne
- dernière visite:
- 06.03.05
- Messages:
- 0
Hmmm.
I think my problem lies with the package I am tryin gto install as I have just tried some others and they seem to work fine.
The city package that I am working on has the following:
<?php
// City package for Queensland Australia
$city_name = 'Australia: Queensland';
$city_version = 1.0;
$subdiv_id = 124;
$country_id = 5;
$region_id = 3;
$city_data = array();
$city_data[] = array('accid' => 'ASXX0002', 'name' => 'Alice Springs');
$city_data[] = array('accid' => 'ASXX0005', 'name' => 'Ayres Rock');
$city_data[] = array('accid' => 'ASXX0011', 'name' => 'Beenleigh');
$city_data[] = array('accid' => 'ASXX0016', 'name' => 'Brisbane');
$city_data[] = array('accid' => 'ASXX0020', 'name' => 'Cairns');
$city_data[] = array('accid' => 'ASXX0021', 'name' => 'Caloundra');
$city_data[] = array('accid' => 'ASXX0027', 'name' => 'Cooktown');
$city_data[] = array('accid' => 'ASXX0047', 'name' => 'Gold Coast');
$city_data[] = array('accid' => 'ASXX0046', 'name' => 'Gladstone');
$city_data[] = array('accid' => 'ASXX0217', 'name' => 'Hervey Bay');
$city_data[] = array('accid' => 'ASXX0061', 'name' => 'Ipswich');
$city_data[] = array('accid' => 'ASXX0117', 'name' => 'Townsville');
$city_data[] = array('accid' => 'ASXX0070', 'name' => 'Mackay');
$city_data[] = array('accid' => 'ASXX0079', 'name' => 'Mount Isa');
$city_data[] = array('accid' => 'ASXX0016', 'name' => 'Nambour');
$city_data[] = array('accid' => 'ASXX0216', 'name' => 'Warwick');
?> -
- rang:
-
Site Admin
- enregistré depuis:
- décembre 2003
- Status:
- hors ligne
- dernière visite:
- 09.10.08
- Messages:
- 266
Hello, due to the way tables are set in the database each city code has to be unique so the message you get in certainly caused by a duplicate city code (you are tring to add a city code that's already in the table)
this can be caused by
- a city code entered "by hand" and later you are trying to install a package with the same city code
- an error in one of the australian packages with the same city code in 2 or more packages : the first intall ok but all other packages with the same city give an error (I had this problem with canadian packages).
- an older version of the same package is already installed, you have to :
* either uninstall the previous version before
* or increment the line $city_version = 1.0; to something greater than 1.0 (this make the program to automatically unistall the previous version before installing the new one)
I know the message "Error updating the database" is not very explicit, I should add a more descriptive one but this part of the prog ram is the same since Christopher Grote wrote it a long time ago !! -
Invité
- rang:
- 1
- enregistré depuis:
- décembre 2003
- Status:
- hors ligne
- dernière visite:
- 06.03.05
- Messages:
- 0
Nope.. Those did not fix it.
This is a new install (twice now) and it will not let me install the city package (as listed above for Australia).
Even though now packages are installed, I still tried incrementing the version.. and still had the same error... must be something else causing this. And I can still install / un-install other packages... weird. -
- rang:
-
Site Admin
- enregistré depuis:
- décembre 2003
- Status:
- hors ligne
- dernière visite:
- 09.10.08
- Messages:
- 266
Sometimes things are just under your eyes and you don't see them !! I tried several times to install your package and had the same error message as you !! I looked in the database and some cities where added (unfortunately I didn't at wich ones WEREN'T added !!) so I had to delete them with phpmyadmin to be able to do another try I modified the program so that it print the name of the city who caused the problem : it was Nambour. And suddently I looked at your package and just realised you have 2 cities with the code ASXX00016 !!
The right code for Nambour is ASXX0344.
Correct it and everything should be ok.
BUT BEFORE INSTALLING THE CORRECTED PACKAGE you will have to delete all the australian cities added by the buggy package before stopping on Nambour. You can do this with phpmyadmin, on simply unistall and reinstall all the weather package but you can't simply delete the Queeensland package as it wasn't successfully installed (this is a problem because currently if something goes wrong during a package install, all the cities added stay in the database but the package name isn't added to the list of installed package)
I look stupid because I told you to look EVERYWHERE for duplicate codes EXCEPT in the file you have problem with !!
Don't forget to send me your australian packages. -
Invité
- rang:
- 1
- enregistré depuis:
- décembre 2003
- Status:
- hors ligne
- dernière visite:
- 06.03.05
- Messages:
- 0
LOL... I cant believe I didnt see that..
Thanks mate..
Yeah no probs.. hope to have the Australian package finished in the next few days... as long as I dont duplicate any codes :wink:








