News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Google Member Map

Started by TLM, December 18, 2005, 08:43:52 PM

Previous topic - Next topic

Vinspire

Quote from: Yngwiedis on October 04, 2006, 01:34:40 AM
I just install akulion version for RC3 and i find some minor problems.

1. The style.css part of the mod dont seem to work.
I change the color text from there but the text is always the same ( i think it take the color from the default body color of the style.css ).
2. It does not recognize any gender of my members forum even if they already had select a gender.

Without those minor problems it will be a great conversion from akulion ;)

P.S. Sorry for my bad english...

Thanks. Awesome mod ! :D

smashmash

Is there anyway of getting this mod applied to SMF1.08? It bailed during installation  :(

Cheers

Gobo

sorry i forgot to add a test account - totally forgot membermap was for "members only settings"

added to my first post now

As for the style.css and gender issue - I dont seem to have that on my forum at all, so have no clue why its doin that for u


Yngwiedis

Well... i just noticed that is working perfect if i set the forum language in english.
The 2 problems occured if i set the forum language in another language.
Is there anything i have to see if i use another language ?

Thank you for any help.
AmityHost.com - The Affordable Host

Gobo

Quote from: Yngwiedis on October 05, 2006, 01:29:59 AM
Well... i just noticed that is working perfect if i set the forum language in english.
The 2 problems occured if i set the forum language in another language.
Is there anything i have to see if i use another language ?

Thank you for any help.

yup just had a look

u will have to translate these into ur language from english and then add to your language file

from Modifications.english.php:



$txt['googleMap'] = 'Map';
$txt['googleMapGreenPinGD'] = 'Someones Pin';
$txt['googleMapGreenPinNG'] = 'No Gender';
$txt['googleMapBluePin'] = 'Male';
$txt['googleMapRedPin'] = 'Female';
$txt['googleMapPurplePin'] = 'Cluster of pins';
$txt['googleMapAddPinNote'] = '<a href="' . $scripturl . '?action=profile;sa=forumProfile">Click here to go place your pin if you have not already.</a>';
$txt['googleMapDisclaimer'] = 'Place your pin as close as you feel comfortable doing so.';
$txt['cannot_googleMap_view'] = 'Sorry, you\'re not allowed to view the Member Map.';
$txt['permissionname_googleMap_view'] = 'View Member Map';
$txt['permissionhelp_googleMap_view'] = 'Allow the people to view the Member Map.  If not set, the people will not see the map.';
$txt['cannot_googleMap_place'] = 'Sorry, you\'re not allowed to place a pin for the Member Map.';
$txt['permissionname_googleMap_place'] = 'Place Pin on Member Map';
$txt['permissionhelp_googleMap_place'] = 'Allow the people place there pin the Member Map.  If not set, the people will not be able to place there pins.';



and then in Modsettings.English.php
find:

$txt['karmaLabel'] = 'Karma label';
$txt['karmaApplaudLabel'] = 'Karma applaud label';
$txt['karmaSmiteLabel'] = 'Karma smite label';


Then add the fillowing after it (translate before adding)

$txt['googleMapsEnable'] = 'Enable the Google Member Map';
$txt['googleMapsEnableLegend'] = 'Show a Pin Legend';
$txt['googleSidebar'] = 'Where to show sidebar';
$txt['googleMapsKey'] = 'The key from the Google Maps API Page';
$txt['googleMapsPinGender'] = 'Should the pins reflect users gender?';
$txt['googleMapsPinNumber'] = 'Number of max pins to show on map';
$txt['googleMapsType'] = 'The map type to show';
$txt['googleMapsDefaultLat'] = 'The default Latitude';
$txt['googleMapsDefaultLong'] = 'The default Longitude';
$txt['googleMapsDefaultZoom'] = 'The defualt Zoom';
$txt['googleMapsEnableClusterer'] = 'Enable Pin Clustering';
$txt['googleMapsMinMarkerCluster'] = 'Minimum Pins Per Cluster';
$txt['googleMapsMaxVisMarker'] = 'Maximum Visable Pins On Map';
$txt['googleMapsMaxNumClusters'] = 'Max Number of Clusters';
$txt['googleMapsMaxLinesCluster'] = 'Max Number of lines in Cluster Info Box';
$txt['googleMapFO'] = 'Member Map';


I dont knok much about language packs, but it may be a good idea to ask the person who made the languages package for your specific language on how to go about this

TLM

Quote from: Valodim on October 01, 2006, 07:04:40 AM
why does it search for all these lines
'post_group' => $profile['post_group'],
'post_group_color' => $profile['post_group_color'],
'group_stars' => str_repeat('<img src="' . str_replace('$language', $context['user']['language'], isset($profile['stars'][1]) ? $settings['images_url'] . '/' . $profile['stars'][1] : '') . '" alt="*" border="0" />', empty($profile['stars'][0]) || empty($profile['stars'][1]) ? 0 : $profile['stars'][0]),
'local_time' => timeformat(time() + ($profile['timeOffset'] - $user_info['time_offset']) * 3600, false),]]></search>


in load.php? even the first line on its own is distinct, using that many lines just makes it less compatible to other mods (for example mods which change star behaviour)...
I did that cause i did not really look at the code, I used a diff file from original src and converted it by hand into xml for the package.  That would be why...

Quote from: Valodim on October 01, 2006, 07:04:40 AM
also, I found it useful to have the maps shown in the profile only on demand, since it's rather bulky otherwise. If anyone else wants to have that, just replace this line

<div id="map" style="width: 600px; height: 350px; color: #000000;"></div>

with this

                        <div id="map" style="width: 600px; height: 350px; color: #000000; display: none;"></div>
<div id="hmap"><a href="#" onclick="if(GBrowserIsCompatible()) LoadMap();">Show Map</a></div>


add these lines

                                document.getElementById(\"hmap\").style.display = 'none';
                                document.getElementById(\"map\").style.display = 'block';


right below

function LoadMap() {


and remove these lines

}

if (GBrowserIsCompatible()) {
window.onload=LoadMap;

entirely, all in profile.template.php...
You dont mind if I steal this for the next version?  I found it bulky but could not think of how to fix that.  Although I am gonna have to re-work part of this, for I am trying to pull the javascript out of the profile and put it in its own file.

Quote from: smashmash on October 04, 2006, 03:48:41 AM
Is there anyway of getting this mod applied to SMF1.08? It bailed during installation  :(

Cheers
I dont suppose you can upgrade to 1.1rc2(soon to be 3) could you?  I really dont have time to back port.




akulion,
I dont suppose once I get the next version done I can get you to take that down for thats using the old API.

Gobo

Quote
akulion,
I dont suppose once I get the next version done I can get you to take that down for thats using the old API.

sure man - if u want i can take it down now - just say the word anytime :)

Webrunner

I'm having a problem in Intermet Explorer.
looking at the map gives the following error ( see screenshot, sorry in dutch)
and shows a non existing page after that.
Am i missing something?
There is a difference between knowing the path and walking the path.

=========================================
Vrouwen Power! | Sprintweb: No nonsense e-Business consultancy

Gobo

Quote from: Webrunner on October 06, 2006, 02:49:21 PM
I'm having a problem in Intermet Explorer.
looking at the map gives the following error ( see screenshot, sorry in dutch)
and shows a non existing page after that.
Am i missing something?

good catch - im getting that too

il look into it a bit later but I doubt ill be able to fix that - but it only occurs in IE and in FF and Opera it runs just fine. Very strange

Gobo

#589
Hold on

just found it!!

http://www.simplemachines.org/community/index.php?topic=61213.msg470855#msg470855

There is an IE fix posted there - we should apply it and see ::)

Webrunner

That is an old patch. You would expect that the newer version has the patch included. Did you try it?
There is a difference between knowing the path and walking the path.

=========================================
Vrouwen Power! | Sprintweb: No nonsense e-Business consultancy

Gobo

nope havent tried yet

still too busy trying to answer support questions on another forum and also answering debate questions on one other while working on my site lol

ill try it out soon enough :)

Gobo

just tried it out

yes it fixes the problem right up :D


but get the file from this post:
http://www.simplemachines.org/community/index.php?topic=61213.msg470855#msg470855

upload to ur forum/Sources folder and replace the old one...now working on IE,FF and Opera

u can check on my site b4 updating
user: test
pass: test
addy: http://path-to-peace.net/forum

:D

Yngwiedis

Quote from: akulion on October 05, 2006, 10:11:59 AM
Quote from: Yngwiedis on October 05, 2006, 01:29:59 AM
Well... i just noticed that is working perfect if i set the forum language in english.
The 2 problems occured if i set the forum language in another language.
Is there anything i have to see if i use another language ?

Thank you for any help.

yup just had a look

u will have to translate these into ur language from english and then add to your language file

from Modifications.english.php:



$txt['googleMap'] = 'Map';
$txt['googleMapGreenPinGD'] = 'Someones Pin';
$txt['googleMapGreenPinNG'] = 'No Gender';
$txt['googleMapBluePin'] = 'Male';
$txt['googleMapRedPin'] = 'Female';
$txt['googleMapPurplePin'] = 'Cluster of pins';
$txt['googleMapAddPinNote'] = '<a href="' . $scripturl . '?action=profile;sa=forumProfile">Click here to go place your pin if you have not already.</a>';
$txt['googleMapDisclaimer'] = 'Place your pin as close as you feel comfortable doing so.';
$txt['cannot_googleMap_view'] = 'Sorry, you\'re not allowed to view the Member Map.';
$txt['permissionname_googleMap_view'] = 'View Member Map';
$txt['permissionhelp_googleMap_view'] = 'Allow the people to view the Member Map.  If not set, the people will not see the map.';
$txt['cannot_googleMap_place'] = 'Sorry, you\'re not allowed to place a pin for the Member Map.';
$txt['permissionname_googleMap_place'] = 'Place Pin on Member Map';
$txt['permissionhelp_googleMap_place'] = 'Allow the people place there pin the Member Map.  If not set, the people will not be able to place there pins.';



and then in Modsettings.English.php
find:

$txt['karmaLabel'] = 'Karma label';
$txt['karmaApplaudLabel'] = 'Karma applaud label';
$txt['karmaSmiteLabel'] = 'Karma smite label';


Then add the fillowing after it (translate before adding)

$txt['googleMapsEnable'] = 'Enable the Google Member Map';
$txt['googleMapsEnableLegend'] = 'Show a Pin Legend';
$txt['googleSidebar'] = 'Where to show sidebar';
$txt['googleMapsKey'] = 'The key from the Google Maps API Page';
$txt['googleMapsPinGender'] = 'Should the pins reflect users gender?';
$txt['googleMapsPinNumber'] = 'Number of max pins to show on map';
$txt['googleMapsType'] = 'The map type to show';
$txt['googleMapsDefaultLat'] = 'The default Latitude';
$txt['googleMapsDefaultLong'] = 'The default Longitude';
$txt['googleMapsDefaultZoom'] = 'The defualt Zoom';
$txt['googleMapsEnableClusterer'] = 'Enable Pin Clustering';
$txt['googleMapsMinMarkerCluster'] = 'Minimum Pins Per Cluster';
$txt['googleMapsMaxVisMarker'] = 'Maximum Visable Pins On Map';
$txt['googleMapsMaxNumClusters'] = 'Max Number of Clusters';
$txt['googleMapsMaxLinesCluster'] = 'Max Number of lines in Cluster Info Box';
$txt['googleMapFO'] = 'Member Map';


I dont knok much about language packs, but it may be a good idea to ask the person who made the languages package for your specific language on how to go about this

I made all this changes when i make the installation of the mod.
So the problem is not from the language strings.
AmityHost.com - The Affordable Host

Gobo

Yngwiedis I have no clue why it wont work for other languages

ur best bet would be to wait for the authors update

Valodim

Quote from: TLM on October 05, 2006, 10:20:38 PM
You dont mind if I steal this for the next version?  I found it bulky but could not think of how to fix that.  Although I am gonna have to re-work part of this, for I am trying to pull the javascript out of the profile and put it in its own file.

sure, no prob.

StormLrd

akulion

this was one of those mods I always wanted to get to work and make into a tp mod instead of smf mod lol, so if you have some successes with it let me know.

Gobo

Quote from: StormLrd on October 08, 2006, 09:00:56 AM
akulion

this was one of those mods I always wanted to get to work and make into a tp mod instead of smf mod lol, so if you have some successes with it let me know.

of course :D anything for u bro!

StormLrd

Quote from: akulion on October 08, 2006, 10:05:27 AM
Quote from: StormLrd on October 08, 2006, 09:00:56 AM
akulion

this was one of those mods I always wanted to get to work and make into a tp mod instead of smf mod lol, so if you have some successes with it let me know.

of course :D anything for u bro!

danka m8

bmhm

Quote from: Yngwiedis on October 07, 2006, 08:08:16 AM
Quote from: akulion on October 05, 2006, 10:11:59 AM
Quote from: Yngwiedis on October 05, 2006, 01:29:59 AM
Well... i just noticed that is working perfect if i set the forum language in english.
The 2 problems occured if i set the forum language in another language.
Is there anything i have to see if i use another language ?

Thank you for any help.

yup just had a look

u will have to translate these into ur language from english and then add to your language file

from Modifications.english.php:

I dont knok much about language packs, but it may be a good idea to ask the person who made the languages package for your specific language on how to go about this

I made all this changes when i make the installation of the mod.
So the problem is not from the language strings.


Got it? ;D Rename/copy that file and it should work fine. I already did a german one.

Advertisement: