Google Member Map

Started by Spuds, December 12, 2007, 01:49:12 PM

Previous topic - Next topic

seraphikah

Sorry, I am a BAD explainer! lol. What I want is to get a link to the map on the menu bar, like where it says home, profile, admin, etc. I figured out how to get a link to show up there, but I don't know how to get it to function. I'm assuming it has to have another code put in somewhere to define it, like the shop mod did. But I don't know where or what code. This is the code I put in to get the link to show, if that will help:

// GoogleMap
      echo'<a href="', $scripturl, '?action=map" class="menulinks">Map</a> | ';

brianjw

#21
It should be this:

// GoogleMap
if (($modSettings['googleMapsEnable']) && (allowedTo('googleMap_view')))
      echo'<a href="', $scripturl, '?action=googlemap" class="menulinks">Map</a> | ';


brianjw

PS{ Does it show up at all? }

seraphikah

#22
Ok, I'll try that. The link shows up in the menu bar but when I click it, it takes me to the home page. Everyone can access the map though through their profile. But I'll try your code and report back :)

Thank you! I had to modify that a little bit to get it work. This is the code that works for me, but I'm sure that's because of the theme I was using it on.

// GoogleMap
      echo'<a href="', $scripturl, '?action=googlemap" class="menulinks">Map</a> | ';


So I guess all I had wrong was the action name, I had map instead of googlemap. With the other line in it, my map link wasn't showing up at all...but without it, it functions perfect, so thanks!

brianjw

All you really need to do is change ?action=map to ?action=googlemap
?action=map doesn't exsist so it is taking you to the homepage. ;)

Remember to enable and enter pin in the 'Features an Options' >> 'Member Map'

brianjw

brianjw

If anyone is interested in doing some translations for this mod, that would be awesome. :)
There have been other languages posted in the past, but since I added and changed things, I'd need a new translation of all languages that are possible.
Code (These are the default english strings) Select

$txt['googleMap'] = 'Member Map';
$txt['googleMappinned'] = 'Pinned Member\'s';
$txt['googleMapc'] = 'Member Map Mod by <a href="http://www.gamerzgarage.com/">brianjw</a>';
$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.';


Thanks,
brianjw

caryb

I have install errors on my 1.1.4 forum! http://www.qah.org.au I have attached pictures of the error & other installed mods!


Cary

TEOC2

#26
@brianjw, or anyone who knows, is it possible to make it so that when you click on a member's name on the coloum on the right the pin will be centered on the screen, like almost exactly center?
http://binkles.wsnw.net/qwerty/index.php?action=googlemap


@cary. Whoa! you need to crop the screenies down to just show the relavant info.
See my attachments. v


falguni1


brianjw

Quote from: caryb on December 16, 2007, 03:16:50 AM
I have install errors on my 1.1.4 forum! http://www.qah.org.au I have attached pictures of the error & other installed mods!
The Custom Action Mod is conflicting in ModSettings.php and index.template.php, I am not sure yet. Go ahead and install even though you get that error, then attach ModSettings.php and index.template.php, I will make the appropriate edits for the mod to work.

Quote from: TEOC2 on December 16, 2007, 04:42:54 AM
@brianjw, or anyone who knows, is it possible to make it so that when you click on a member's name on the coloum on the right the pin will be centered on the screen, like almost exactly center?
http://binkles.wsnw.net/qwerty/index.php?action=googlemap
Well, there is no way of making it center unless their is something at the google map docs or anything but it does move the map so you can completely see the balloon and the pin location. But it isn't center. I will look into this and get back to you if I find anything.

brianjw

fiver

Hi brianjw,

Just installed this mod and playing with it for a while. Had a look in Forum Error Log and found these:

Quotehttp://www.fivearts.net/index.php?action=googlemap                                                                                       
                        8: Undefined index:  googleSidebar
File: /home/fivearts/public_html/Themes/default/GoogleMap.template.php (map sub template - eval?)
Line: 57



Quotehttp://www.fivearts.net/index.php?action=googlemap                                                                                       
                        8: Undefined index:  googleSidebar
File: /home/fivearts/public_html/Themes/default/GoogleMap.template.php (map sub template - eval?)
Line: 62



Quotehttp://www.fivearts.net/index.php?action=googlemap;sa=.js                                                                                       
                        
8: Undefined index:  googleSidebar
File: /home/fivearts/public_html/Sources/GoogleMap.php
Line: 108

Quotehttp://www.fivearts.net/index.php?action=googlemap;sa=.js                                                                                       
                        
8: Undefined index:  googleSidebar
File: /home/fivearts/public_html/Sources/GoogleMap.php
Line: 111

The same 4 messages for each member throughtout the error log.

Great mod. Hope the error can be fixed.

Many thanks.

;)





brianjw

Those errors won't have any affect on your forum other than filling up the error log. I will see if I can fix them. ;)

fals

Im using the "old" google maps scripts.... might upgrade to this instead :-)
http://www.fg-forum.dk/smf/index.php?action=googlemap

I would love to have the "mousewheel zoom" function included..... used on http://maps.google.dk/maps






500fan.dk - SMF 2.0 ~ custom theme
ls-forum.dk - SMF 2.0.2 ~ custom theme and custom iPhone theme

Louis EX

#32
I had a "test failed" on style.css, I installed it anyway I'm using the default theme. I'll tell you later if it works.

It works but I would prefer if it was like the previous google map, when you just typed your location and it automatically pins that point for you. Cause now everybody has to place their pin themselves and members are quite lazy.

brianjw

Quote from: fals on December 16, 2007, 04:37:48 PM
Im using the "old" google maps scripts.... might upgrade to this instead :-)
http://www.fg-forum.dk/smf/index.php?action=googlemap

I would love to have the "mousewheel zoom" function included..... used on http://maps.google.dk/maps
I have not read anything in the google map docs with this feature, allthough the map you linked to does have "mousewheel zoom", I will get in touch with google about this...
Quote from: Louis EX on December 16, 2007, 07:05:08 PM
I had a "test failed" on style.css, I installed it anyway I'm using the default theme. I'll tell you later if it works.

It works but I would prefer if it was like the previous google map, when you just typed your location and it automatically pins that point for you. Cause now everybody has to place their pin themselves and members are quite lazy.
Manually install the style.css file. ;)
I don't recall a previous member map that had this function, I will talk to TLM.

Louis EX

#34
Quote from: brianjw on December 16, 2007, 07:37:33 PM
Quote from: fals on December 16, 2007, 04:37:48 PM
Im using the "old" google maps scripts.... might upgrade to this instead :-)
http://www.fg-forum.dk/smf/index.php?action=googlemap [nofollow]

I would love to have the "mousewheel zoom" function included..... used on http://maps.google.dk/maps [nofollow]
I have not read anything in the google map docs with this feature, allthough the map you linked to does have "mousewheel zoom", I will get in touch with google about this...
Quote from: Louis EX on December 16, 2007, 07:05:08 PM
I had a "test failed" on style.css, I installed it anyway I'm using the default theme. I'll tell you later if it works.

It works but I would prefer if it was like the previous google map, when you just typed your location and it automatically pins that point for you. Cause now everybody has to place their pin themselves and members are quite lazy.
Manually install the style.css file. ;)
I don't recall a previous member map that had this function, I will talk to TLM.
Wait I misunderstood, what I meant was, not map related but the old one's pinned member's list had categorised members to their countries. I'm not sure if its TLM's version or not but  http://www.soldatforums.com/index.php?action=mm [nofollow]

Anyway great mod, I dont really care if you add that feature, its working great for me. <3

qubbah

how can i make scrolling in the username list?

TEOC2

Quote from: qubbah on December 17, 2007, 01:51:49 AM
how can i make scrolling in the username list?

You already asked this and got an answer in the post after your question.

qubbah

ok .. sorry about misschecked....

im using the old one...
now i updated it manually..

tq

cbmr777

I installed the Google Maps mod tonight.  I did have to install it manually as it failed on the Load.php upon trying to use the package manager.  FTR, I have these other mods installed:

1.     Simple_Mood      1.0 
2.    TinyPortal    0.983    
3.    View Single PM    1.3    
4.    Show Multiple Badges (Aka Stars)    1.0    
5.    Display Age and Location next to posts    1.0    
6.    SMF Trader System    1.1

But I installed it manually with no problems. 

Anyway, I do have one minor problem that perhaps someone can help me with...

When I click on "Member Map", and once at the map, click on a userid or pin, the popup properly displays the information. If I close the popup and zoom in/out, and call up a popup again, it does not display properly.

2007-12-20_popupdefault.jpg - shows what happens upon clicking on the popup when initially arriving at the member map.
2007-12-20_popupzoomout.jpg - shows what happens after zooming in/out.

Is there a way to fix this?

I also would like to see the avatars in the popups resized (via HTML or whatever).  Our avatars are set at 125x125 and in the popup they are just too large for my liking.  Can this be remedied, too?

Thank you for a great mod.  I've been manually editing a map myself and it is getting tedious.  Loving having something more automated!   :D


digit

Quote from: fivearts on December 16, 2007, 09:12:12 AM
Hi brianjw,

Just installed this mod and playing with it for a while. Had a look in Forum Error Log and found these:

Quotehttp://www.fivearts.net/index.php?action=googlemap                                                                                       
                        8: Undefined index:  googleSidebar
File: /home/fivearts/public_html/Themes/default/GoogleMap.template.php (map sub template - eval?)
Line: 57



Quotehttp://www.fivearts.net/index.php?action=googlemap                                                                                       
                        8: Undefined index:  googleSidebar
File: /home/fivearts/public_html/Themes/default/GoogleMap.template.php (map sub template - eval?)
Line: 62



Quotehttp://www.fivearts.net/index.php?action=googlemap;sa=.js                                                                                       
                        
8: Undefined index:  googleSidebar
File: /home/fivearts/public_html/Sources/GoogleMap.php
Line: 108

Quotehttp://www.fivearts.net/index.php?action=googlemap;sa=.js                                                                                       
                        
8: Undefined index:  googleSidebar
File: /home/fivearts/public_html/Sources/GoogleMap.php
Line: 111

The same 4 messages for each member throughtout the error log.

Great mod. Hope the error can be fixed.

Many thanks.

;)






It sounds like your installation failed to add $txt['googleSidebar'] = 'Where to show sidebar';

to your ModSettings.english.php file. (So it probably missed that whole block of text)   Look at modification.xml for more info.
Happily using a heavily modified 1.1.16 version of SMF!

2748011 Posts in 320998 Topics by 50986 Members


SOLD my website - thanks it was a good run - they converted to vbadvanced. (and screwed it up good!)

Advertisement: