conkhidannb
Corporal
- Tham gia
- 07/09/2015
- Bài viết
- 189
- Được Like
- 133
Description:
Creates a button called View Map for use in messages. Clicking the View Map button will show a Google map with a marker to a specific location.
Live Example:
http://www.southbayriders.com/forums/threads/2143/
(Example of View Map button)
(Example of View Map)
(Example of View Map link in visitors tab)
(Example of Options page)
Features:
Copy the following two files from the add-on directory to a web viewable directory of your choice, for example a /misc/ folder:
viewmap.php
viewmap_crosshair.gif
Setup step 2:
Edit the viewmap.php file and change the first few variables to reflect your forum information.
Setup step 3:
Option 1: Contact me so I can add your domain to the allowed URLS that can use this add-on. In the conversation explain you're using the View Map add-on and would like to have your URL added to the allowed URLs that can use this API.
https://xenforo.com/community/conversations/add?to=AndyB
Option 2: Get your own key from Google using this link:
https://developers.google.com/maps/documentation/javascript/get-api-key
Update the viewmap.php file variable called $key located on the top of the file.
Setup step 4:
In the Options page, add the Location and Default Coordinates.
How to create a View Map button:
If you like this add-on, please consider sending a small donation.
https://www.paypal.me/andybajka
Thank you.
Creates a button called View Map for use in messages. Clicking the View Map button will show a Google map with a marker to a specific location.
Live Example:
http://www.southbayriders.com/forums/threads/2143/
(Example of View Map button)
(Example of View Map)
(Example of View Map link in visitors tab)
(Example of Options page)
Features:
- Large easy to use Google map displayed full screen.
- Responsive code supports all devices.
- Visitors tab has a link called View Map, this allows viewing the Google map.
- View Map button when clicked shows exact location in Google map.
- All phrases start with viewmap_ for your convenience.
- Download viewmap_v1.4.zip and unzip it.
- Upload the Andy folder to your server. The correct location is library/Andy.
- From your Admin Control Panel, go to the "Install Add-on" page.
- Upload the addon-ViewMap_v1.4.xml file.
- Click the Install Add-on button.
Copy the following two files from the add-on directory to a web viewable directory of your choice, for example a /misc/ folder:
viewmap.php
viewmap_crosshair.gif
Setup step 2:
Edit the viewmap.php file and change the first few variables to reflect your forum information.
Setup step 3:
Option 1: Contact me so I can add your domain to the allowed URLS that can use this add-on. In the conversation explain you're using the View Map add-on and would like to have your URL added to the allowed URLs that can use this API.
https://xenforo.com/community/conversations/add?to=AndyB
Option 2: Get your own key from Google using this link:
https://developers.google.com/maps/documentation/javascript/get-api-key
Update the viewmap.php file variable called $key located on the top of the file.
Setup step 4:
In the Options page, add the Location and Default Coordinates.
How to create a View Map button:
- Under the Visitors tab, click the View Map link.
- Move map to desired location.
- Copy the Map code and paste it into a message.
Example of map code:
- To change the word "View Map" to another language, edit the following BB Code:
Admin CP -> Custom BB Codes -> [map] -> HTML Replacement:
- Member clicks View Map button.
- The View Map button is a Custom BB Code.
- Custom BB Code calls a link which is defined in the Route Prefix.
- The Route Prefix calls Viewmap.php located in the add-on directory.
- The Viewmap.php redirects to viewmap.php.
- The viewmap.php file calls the Google API to display a map.
If you like this add-on, please consider sending a small donation.
https://www.paypal.me/andybajka
Thank you.
Đính kèm
Bài viết liên quan
Bài viết mới