Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.7 > vBulletin 3.7 Template Modifications

Reply
 
Thread Tools
Mass Private Messages on Memberlist Details »»
Mass Private Messages on Memberlist
Version: 1.00, by ThorstenA ThorstenA is offline
Developer Last Online: Nov 2023 Show Printable Version Email this Page

Category: Private Messages Enhancements - Version: 3.7.4 Rating:
Released: 08-18-2008 Last Update: Never Installs: 32
Template Edits
Re-useable Code  
No support by the author.

What does this modification do?
On memberlist select multiple users for Mass Private Messages them. This is done by only 2 template edits
What is Mass PM? It's like Mass Mail in admincp. You write one pm to multiple users.

How to
In template memberlist_resultsbit replace
Code:
</tr>
with
Code:
<td class="$bgclass"><input type="checkbox" name="deletebox[$userinfo[userid]]" value="$userinfo[userid]" /></td>
</tr>
In template memberlist replace
Code:
<form action="profile.php?do=deleteusergroups&amp;usergroupid=$usergroupid" method="post">
<input type="hidden" name="do" value="deleteusergroups" />
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="usergroupid" value="$usergroupid" />
with
Code:
	<script type="text/javascript">
	<!--
	function pm(tform)
	{
		var users = new Array();
		var arrCount = 0;
		for (i = 0; i < tform.elements.length; i++)
		{
			var element = tform.elements[i];
			if ((element.name != "allbox") && (element.type == "checkbox") && (element.checked == true))
			{
				users[arrCount] = element.value;
				arrCount++;
			}
		}
		if (arrCount == 0)
		{
			alert("$vbphrase[no_users_selected]");
		}
		else
		{
			var querystring = "";
			for (i = 0; i < users.length; i++)
			{
				querystring += "&userid[]=" + users[i];
			}

			self.location=	"private.php?$session[sessionurl]do=newpm" + querystring;

		}
	}
	// -->
	</script>
<if condition="$totalcols++"></if>
<form action="private.php" method="post" name="vbform">
In template memberlist also replace
Code:
</form>
with
Code:
<input type="button" class="button" value="$vbphrase[send_private_message_to_selected_users]" onclick="pm(this.form);" title="title" style="float:right"/>
</form>
In template memberlist also replace
Code:
</tr>
$memberlistbits
with
Code:
<td class="thead" align="right"><input type="checkbox" name="allbox" title="$vbphrase[check_uncheck_all]" onclick="js_check_all(this.form);" />$vbphrase[check_uncheck_all]</td>
</tr>
$memberlistbits


How does this template modification work?
This template edit puts a checkbox right to each user. If you click on "Send PMs", the small javascript generates a custom url "private.php?do=newpm&userid[]=1&userid[]=2&userid[]=3" and refreshes actual window with this url. Javascript code is mostly from Quick Links > Open Buddy List.

FAQ
Quote:
Originally Posted by chikkoo View Post
I installed this product. But I don't want to show this feature to everyone. Is there a way to restrict few usergroups, such as admin, supermoderators and moderators?
You can for example only show this mod for moderators, supermoderators and administrators (usergroups 5,7,6). Note that you have to put this condition for any template edit you want to only show to these usergroups.
Code:
<if condition="in_array($bbuserinfo[usergroupid], array(5,6,7))">
here you do put template edits
</if>

Show Your Support

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

Comments
  #22  
Old 08-21-2008, 05:33 AM
MarkoP MarkoP is offline
 
Join Date: Jul 2008
Posts: 40
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is this the only PM mod available?

I'd like to be able to have the option to send a mass PM to a whole usergroup 'without' also sending an email notification.

The reason is we imported thousands of users from another system and many of these are no longer really members. If I pm'ed the whole list and everyone got an email I'd probably get shut down for spam.
Reply With Quote
  #23  
Old 08-21-2008, 06:02 AM
ThorstenA's Avatar
ThorstenA ThorstenA is offline
 
Join Date: Nov 2004
Posts: 669
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by m3rl1nuk View Post
I like this but how about making it so it appears as an option for new pm like the old super pm did?
I would rather have the option in pm's than the member list if its possible as an additional option.
Quote:
Originally Posted by hornstar1337 View Post
I think this should have extra permissions. eg. only x usergroup be allowed to see the check boxes.
Quote:
Originally Posted by MarkoP View Post
I'd like to be able to have the option to send a mass PM to a whole usergroup 'without' also sending an email notification.
New options are available once I write an auto-template product. I write this product if more members install this product.
Reply With Quote
  #24  
Old 08-21-2008, 12:23 PM
Gene Steinberg Gene Steinberg is offline
 
Join Date: Dec 2006
Posts: 278
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This is a cart before the horse argument. I'll install the product that performs the tasks I want, and yours doesn't -- yet. As MarkP says, I'd like to be able to send a mass PM to an entire usergroup, which is an option that should probably be added in -- what? -- Admin CP?

Peace,
Gene
Reply With Quote
  #25  
Old 08-21-2008, 12:43 PM
ThorstenA's Avatar
ThorstenA ThorstenA is offline
 
Join Date: Nov 2004
Posts: 669
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by genesteinberg View Post
This is a cart before the horse argument. I'll install the product that performs the tasks I want, and yours doesn't -- yet. As MarkP says, I'd like to be able to send a mass PM to an entire usergroup, which is an option that should probably be added in -- what? -- Admin CP?
This modification will never be in admincp as it uses memberlist.php. I wanted to express that you can mass pm all users that are shown on memberlist. If there is a modification available, that only shows members of a specific usergroup within memberlist (I remember a mod like this), then you can mass pm a usergroup with this template modification.
Reply With Quote
  #26  
Old 08-21-2008, 12:54 PM
Gene Steinberg Gene Steinberg is offline
 
Join Date: Dec 2006
Posts: 278
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I understand your point. But going through a member list when you have a thousand members or more can take a little time. However, being able to globally send PM to an entire usergroup in Admin CP would be a whole lot faster, don't you think? Just a suggestion.

Peace,
Gene
Reply With Quote
  #27  
Old 08-21-2008, 01:23 PM
ThorstenA's Avatar
ThorstenA ThorstenA is offline
 
Join Date: Nov 2004
Posts: 669
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by genesteinberg View Post
I understand your point. But going through a member list when you have a thousand members or more can take a little time. However, being able to globally send PM to an entire usergroup in Admin CP would be a whole lot faster, don't you think? Just a suggestion.
I would also like to have a admincp mass pm product. I think there was one online for vbulletin 3.5 or vbulletin 3.6. However it has two downside points
  • it's somewhat complicated and therefore an advanced programmer should write this modification
  • only administrators can access this modification
What I am looking forward to is, that my moderators write regularly pms to members they specify in advanced memberlist search. For example all users, that drive a bmw (profile field), have registered in the last five days and did not write any post.

While writing another modification about buddylist, I saw that a memberlist mass pm could be possible with a template modification, so here we are and if this template mod becomes more famous, I am putting more energy inside
Reply With Quote
  #28  
Old 09-02-2008, 06:47 AM
samiro's Avatar
samiro samiro is offline
 
Join Date: Jan 2007
Posts: 136
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nice one.
but i also wat to send Mass PM without sendin Email notification ...
Reply With Quote
  #29  
Old 09-06-2008, 08:40 AM
yotsume's Avatar
yotsume yotsume is offline
 
Join Date: Dec 2006
Posts: 844
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If you make this a product I will install this as well. PLEASE make this a product. I am not going to do all the edits and then install a product. So please make this ASAP! THANKS!
Reply With Quote
  #30  
Old 09-06-2008, 08:45 AM
ThorstenA's Avatar
ThorstenA ThorstenA is offline
 
Join Date: Nov 2004
Posts: 669
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by yotsume View Post
If you make this a product I will install this as well. PLEASE make this a product. I am not going to do all the edits and then install a product. So please make this ASAP! THANKS!
Only 2 templates need to be edited. There are only 12 installs that far, so I consider a mass pm solution as not that important to most administrators.
Reply With Quote
  #31  
Old 09-06-2008, 08:53 AM
yotsume's Avatar
yotsume yotsume is offline
 
Join Date: Dec 2006
Posts: 844
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I am sorry but your math thinking is way off! Such a features is of critical importance. I need it to be for admins only so I hope you consider doing it.
Reply With Quote
Reply

Thread Tools

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 08:22 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.04536 seconds
  • Memory Usage 2,319KB
  • Queries Executed 25 (?)
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
  • (9)bbcode_code
  • (7)bbcode_quote
  • (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
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)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