Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.6 > vBulletin 3.6 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Member Info Map - display the location of the user with Google Maps Details »»
Member Info Map - display the location of the user with Google Maps
Version: 1.1, by MrNase MrNase is offline
Developer Last Online: Sep 2010 Show Printable Version Email this Page

Category: Profile Enhancements - Version: 3.6.8 Rating:
Released: 11-29-2007 Last Update: 11-29-2007 Installs: 19
Uses Plugins Auto-Templates
Additional Files  
No support by the author.

Hi there!

This mini mod allows you to place a map of the user location on the Member Info Page (aka profile).

The user can define his/her location and wether he/she wants to show a map or not in his/her profile. It uses the Google Maps API and jQuery.


You don't need to modify a template or a file, simply follow the instructions:


First step:
Go to the 'Plugins & Products' section in your AdminCP.
Click on 'Manage Products' and import the *.xml file I attached.


Second step:
Part 1:
Go to the 'User Profile Fields' section in your AdminCP.
Add a new User Profile Field -> Single-Line Text Box
  • Enter a title and a description.
  • Edit the following settings:
  • Field Searchable on Members List -> no
  • Show on Members List -> no
Click 'save'.
Note the ID/name of that profile field (field5, field100 or whatever)


Part 2:
Add a new User Profile Field -> Single-Selection Radio Button
  • Enter a title and a description.
  • Edit the following settings:
  • Options -> yes (next line) no
  • Field Searchable on Members List -> no
  • Show on Members List -> no
Click 'save'.
Note the ID/name of that profile field (field6, field100 or whatever)



Third step:
Apply for a Google Maps API-Key: http://code.google.com/apis/maps/signup.html

Put the attached file 'jquery-1.2.1.min.js' into the folder /clientscript/



Fourth step:
Go to the 'vBulletin Options' section in your AdminCP.
Select the settings 'User Listing & Profile Viewing'.
Copy and Paste the API-Key from step three to the input field (Member Info Map API-Key).
Copy and Paste the name/ID of the first profile field you created to the input field (Member Info Map Data Field)
My profile field for the location is called 'field5' so I put 'field5' into that input field.

Copy and Paste the name/ID of the second profile field you created to the input field (Member Info Map Enabled Field)
My profile field that defines wether the user enabled or disabled his map is called 'field6' so I put 'field6' into that input field.


Fifth step:
Enable it via the Member Info Map ENABLED-setting

Now, encourage your users to edit their profile and add a location.


Version 1.1:
Fixes a stupid bug.
To update, either import the attached *.xml again or change the plugin manually.

Manual update:
Edit the plugin 'Member Info Map - member.php'.
Set the Hook Location to 'member_execute_start'.

Replace the Plugin PHP Code with this code:
Code:
if(($userinfo[$vbulletin->options['memberinfo_map_fieldenabled']] == 'yes') AND ($vbulletin->options['memberinfo_map_enabled'])) {
	$memberinfo_map_userlocation = $vbulletin->input->clean($userinfo[$vbulletin->options['memberinfo_map_fielddata']], 'TYPE_STR');
	$memberinfo_map_apikey = $vbulletin->options['memberinfo_map_apikey'];
	eval('$template_hook[memberinfo_additionalinfo] = "' . fetch_template('memberinfo_map') . '";');
	eval('$headinclude .= "' . fetch_template('memberinfo_mapcode') . '";');
}





Install this Mini Mod at own risk. I tested it once and it worked. And don't forget to click 'install'!!

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #2  
Old 12-01-2007, 05:06 AM
Magnumutz's Avatar
Magnumutz Magnumutz is offline
 
Join Date: Feb 2006
Location: Romania
Posts: 731
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

w00t, First install.
Thanks dude, it's a great asset.
Reply With Quote
  #3  
Old 12-01-2007, 07:27 AM
Robru Robru is offline
 
Join Date: Aug 2005
Location: Netherlands
Posts: 368
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for this marvelous hack
Reply With Quote
  #4  
Old 12-01-2007, 03:07 PM
Catziggy Catziggy is offline
 
Join Date: Nov 2007
Posts: 38
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Works great thanks
Reply With Quote
  #5  
Old 12-02-2007, 09:33 AM
MrNase MrNase is offline
 
Join Date: May 2003
Location: Germany
Posts: 670
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm glad it works for you.


One thing makes me wanna cry: 31 downloads and only 8 installs?
Reply With Quote
  #6  
Old 12-02-2007, 04:50 PM
Catziggy Catziggy is offline
 
Join Date: Nov 2007
Posts: 38
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I might have an issue.

My own location shows up perfectly but when i look at other peoples locations they all show as mine and even if people turn off the googlemap i still see them as my locations. Any ideas?
Reply With Quote
  #7  
Old 12-02-2007, 05:05 PM
MrNase MrNase is offline
 
Join Date: May 2003
Location: Germany
Posts: 670
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

That's strange. I'll look into it ASAP.


1.1 is out which fixes that stupid bug. I should have known that $vbulletin->userinfo and $userinfo are two different pair of shoes.
Reply With Quote
  #8  
Old 12-02-2007, 05:34 PM
Catziggy Catziggy is offline
 
Join Date: Nov 2007
Posts: 38
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is it the current download? If so do i uninstal it and then reinstal or just overwrite the files?
Reply With Quote
  #9  
Old 12-02-2007, 06:12 PM
MrNase MrNase is offline
 
Join Date: May 2003
Location: Germany
Posts: 670
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You might just overwrite the old product with the new product but then you'll need to configurate it again.

I have posted the instructions on how to manually update it, you need to edit one plugin and that's it.
Reply With Quote
  #10  
Old 12-02-2007, 06:52 PM
Catziggy Catziggy is offline
 
Join Date: Nov 2007
Posts: 38
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

still doesnt seem to be working for me

tried to do it both ways

manual editing first then overwrite

http://www.timelessgaming.com

can you check it out?
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 01:27 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04331 seconds
  • Memory Usage 2,296KB
  • Queries Executed 23 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete