Notice

The forum is in read only mode.

Support Forum

Welcome! Support Forums have been reactivated
Welcome the Technical Support section. Help us in assisting you by providing us with a concise and descriptive elaboration of your issues. Be specific and if possible, provide us with a step-by-step instruction in replicating your problem.

Geolocation issue

9 years 9 months ago
Licenses:
JomSocial Expired

Hi,

I have an issue with the geolocation of my users.
The extension HelloMaps from Gotour WebSolutions does'nt find the datas in the appropriate database for the geolocation.

Here is their answer the team of Gotour gives me.
Can you please tell me how to fix this?

From GoTour
"We just saw your database, and the latitude and longitude values ​​are not stored in the table # _community_users. (see attachment)
The latitude and longitude values ​​are generated automatically by JomSocial, when the user fills in the fields: STATE / COUNTRY / CITY / ADDRESS.
Our map receives the values ​​from this table, and if users are properly geolocated will be displayed on the map. "

Thank you for your answer,
Best regards

Attachments:
9 years 9 months ago
Licenses:

Hi Nathalie,

I confirmed this is a valid bug. for temporary fixes please follow this steps:
1. edit /components/com_community/models/profile.php
2. find function at line 495:

public function updateLocationData($userid)
3. after this code
// Build the address string
$address = $user->getAddress();
put
$address = str_replace('COM_COMMUNITY_LANG_NAME_', '', $address);

after this is any new register user or any edit profile. the latitude and longitude value will be updated.

Regards,
Albert

9 years 9 months ago
Licenses:
JomSocial Expired

Hi,

I did as you said and it worked fine for a while but then,

I did two things :
I changed a birthdate on one user,
and I went on a profile to make the "address field" visible only by me

and then it didn't worked anymore even after if I put it back as before.

The map doesn't find anymore the new members I add...

??

Best regards

9 years 9 months ago
Licenses:

Hi Nathalie,

could you please check into the DB for community_users table. and make sure the latitude and longitude value for related user not 255.000000. after edit process

Regards,
Albert

9 years 9 months ago
Licenses:
JomSocial Expired

Hi,

Yes it changed the latitude and longitude value to 255.0000 for both old and new users.
But the line in the code I added is still there.

?
Best regards

Attachments:
9 years 9 months ago
Licenses:

Hi Nathalie,

I want have a look at your site. seem your site info not valid. I want to know what address, city, state, country

here the explanation about how to jomsocial get lat lang value:
1. jomsocial will send value by using address, state, country value from profile to maps.google.com/maps/api/geocode/json?address= [ADDRESS]%2C[CITY]%2C[STATE]%2C[COUNTRY]&sensor=false
2. If the return not false, the lat lang value will put into that user table and if false / address not found at google maps, it will return 255.0000 to user table

Could you please make sure your credential information is valid at site info?

Regards,
Albert

9 years 9 months ago
Licenses:
JomSocial Expired

Hi Albertus

I created a new user with an adress which is for sure recognise by google map:
10 rue des Bordes, Sâone-et-Loire, Louhans, France
and it gives by default the value 255.00000

even the adress I was using before was recognise since it found it on the map once and then it disappear from the map after the change.


Hope we can find a solution,

Best regards

9 years 9 months ago
Licenses:

Hi Nathalie,

the return from google:
"You have exceeded your daily request quota for this API"

let wait until tomorrow, don't know why this happen.

and I found something with jomsocial toolbar. your template css make the toolbar disappear. but I already fixed for you.
I put new css rule at template custom.css

#community-wrap .navbar-inner .collapse {
  display: block !important;
}


Regards,
Albert

Attachments:
9 years 9 months ago
Licenses:

Hi Nathalie,

please follow the step to get an API key (at answer section)
salesforce.stackexchange.com/questions/2...hen-trying-to-get-la

and let me know the API key. after that I will try to put it in the google request code.

Regards,
Albert

9 years 9 months ago
Licenses:
JomSocial Expired

Hi Albertus

Here is the API Key :

Part of the message is hidden for the guests. Please log in or register to see it.


Thanks for the toolbar :)

Best regards

9 years 9 months ago
Licenses:
JomSocial Expired

Hi Albertus

Here is the API Key :

Part of the message is hidden for the guests. Please log in or register to see it.


Thanks for the toolbar :)

Best regards

9 years 9 months ago
Licenses:

Hi Nathalie,

Done... it works now.
here the changes:
/components/com_community/libraries/mapping.php line 41:

From
$url = CMapping::GEOCODE_URL . 'address='.urlencode($address) .'&sensor=false';

To
$url = 'https://'.CMapping::GEOCODE_URL . 'key=AIzaSyALaLRi2VqlFaB8Bf3J4uvDVHA-1oj5eBA&address='.urlencode($address) .'&sensor=false';

please delete my test user.

Regards,
Albert

9 years 9 months ago
Licenses:
JomSocial Expired

Hi Albertus,

I don't know what is the relation with geolocation issue but now when I create a new user he doesn't receive the activation link for his account... neither I receive a message to tell that a new account has been created...

??

9 years 9 months ago
Licenses:
JomSocial Expired

I forgot to say that I also tried to get the activation email with the "get connected" login form with the button "sending again the activation code" with the 3 new users

Moderators: Piotr Garasiński
Powered by Kunena Forum

Join 180,000 websites creating Amazing communities

JomSocial is the most complete, easy-to-use addon that turns Joomla CMS into a
full -fledged, social networking site

TRY NOW BUY NOW