News:

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

Main Menu

Google Route Map v.1

Started by Mick., April 25, 2010, 01:06:39 PM

Previous topic - Next topic

Mick.

Link to Mod

Google Route Map v.1
By Mick G.

COMPATIBLE WITH SMF 2.0

This mod installs a route page to your SMF forum with a directions map provided by google.   Useful to those forum owners that offer gas, travel, hotels, trips services, etc......  as well for automotive enthusiasts that do the "club" thing.   In fact, it can be use for whatever else comes to mind.

The key is required by the Google Maps API, and can be aquired at, http://www.google.com/apis/maps/signup.html

Upon sign up there you will need to put in your sites URL, example, Your Forum is at: http://www.example.com

In there sign up box put exactly that, do not include any file name just the directory path in the url.

If you need support or need customize help, please post in the thread at SimpleMachines.org Thanks!

Bug Fixes / Updates
1.) Created v.1 | March 11th 2010
2.) Added "Print" button | March 26 2010
3.) Fixed issue with IE not loading | March 27 2010

Arantor

Holder of controversial views, all of which my own.

Mick.

Quote from: Arantor on April 25, 2010, 01:07:39 PM
Nice mod :)

Thanx.  The team didnt like at first.  I had it all hard coded....  lol stupid me.

JBlaze

Congrats on the approval ;)

* JBlaze whistles innocently

Nice mod btw :D
Jason Clemons
Former Team Member 2009 - 2012

Mick.

Quote from: JBlaze on April 25, 2010, 01:28:34 PM
Congrats on the approval ;)

* JBlaze whistles innocently

Nice mod btw :D

Thanx JB ;)

kizer

Is the start and finish locations fixed in the config? If not then how do you direct your visitor to your location or the location you would like them to visit?

Also could this use a "Print" feature so they could print out the directions and take them with them?
Own a Jeep? Links4Jeeps.com

Mick.

Yes, the example start and finish seen is default and can be set in the language file.

Find:
$txt['toAddress'] = '3666 Madison Ave, San Diego, CA 92116';
$txt['fromAddress'] = 'San Diego';


and change to:
$txt['toAddress'] = 'miami,fl';
$txt['fromAddress'] = 'San Diego,ca';


or

$txt['toAddress'] = '3666 Madison Ave, San Diego, CA 92116';
$txt['fromAddress'] = '1600 Pennsylvania Ave Washington,DC';



Yep. The SMF print button im assuming it can be added.

Mick.

New Zip loaded.   Added a "Print" button per request.  Tested on IE & FF and fixed an issue with the template.

Uninstall old Zip and delete from mod list in admin.  Upload new Zip and empty file cache.

Sabre™

Do NOT give admin and/or ftp details to just anybody, see if they are trust worthy first!!  Do your homework ;)


TheListener

Hey BD is this mod viewable at your place?

Mick.

Quote from: Brack1 on April 26, 2010, 09:43:57 PM
Hey BD is this mod viewable at your place?

Yes.   ...and look at the reply #1.


Quote from: Sabre™ on April 26, 2010, 09:41:38 PM
Very nice mate :)
Thanks.

Thanx Sabre.

TheListener


Mick.

Quote from: Brack1 on April 26, 2010, 09:51:10 PM
Ok see ya at 10 lol

;D
I get it now.   lol

no, that's not my addy.   ;)

TheListener

Hmm

Looks good. Will have another look when it is daytime. ( Is 3:03am).

Be good for a local forum like MKA.

TheListener

Er whats a error message: 602?

Sabre™

Did you type in the correct address?
Do NOT give admin and/or ftp details to just anybody, see if they are trust worthy first!!  Do your homework ;)


Mick.

Quote from: Brack1 on April 26, 2010, 10:07:42 PM
Er whats a error message: 602?

Its an incomplete or unknown address.

QuoteNo corresponding geographic location could be found for one of the specified addresses. This may be due to the fact that the address is relatively new, or it may be incorrect.
Error code: 602

Bruno36

Hello!

The mod does not work with Internet Explorer.
It works well with Google Chrome
Bruno36 the French
SMF 2.0.9

TheListener

#18
Had this error. The install was clean had no manual edits.

Apply Filter: Only show the error messages of this URL
http://xxxxxxxxxxxxxxxxxxxxxx/index.php?action=admin;area=modsettings;sa=routemap
Apply Filter: Only show the errors with the same message
8: Undefined index: googleRouteMapsEnable
Apply Filter: Only show the errors from this file
File: xxxxxxxxxxxxxxxxxxx/Sources/Subs.php
Line: 4319

Attachment supplied

Bruno I use Firefox.

EDIT:

4315:     
// Google Route Maps Mod
4316:    
'routemap' => array(
4317:    
'title' => $txt['googleRouteMap'],
4318:    
'href' => $scripturl . '?action=routemap',
==>4319:    
'show' => $modSettings['googleRouteMapsEnable'] && allowedTo('googleRouteMap_view'),
4320:    
'sub_buttons' => array(
4321:    
),
4322:    
),

Mick.

Quote from: Bruno36 on April 27, 2010, 08:10:36 AM
Hello!

The mod does not work with Internet Explorer.
It works well with Google Chrome

You're right.

Gotta love the useless IE.   It may be in the javascript.    I'll take a look.   

Advertisement: