vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Auto PM new members? (https://vborg.vbsupport.ru/showthread.php?t=20583)

mojotim 06-18-2001 09:26 AM

Hi, does anyone have a hack to send a new user a PM welcome message automatically? I had one in my iKonboard and the response was positive from new users. I would get emails from new users after they got their PM saying, "Thanks for the warm welcome!".
Anyone?

Dockaych 08-05-2001 06:39 PM

I would love to have this hack also! To introduce people to the site, and also to the PM featuer, it's a great idea! A much better way than to mail them than plaster a huge email to them.

-dock

Dennis Wrenn 08-05-2001 07:07 PM

Code:

  $DB_site->query("INSERT INTO user (userid,username,passw{etc}...");
  $userid=$DB_site->insert_id();
  $adminstuff = $DB_site->query_first("SELECT userid, signature FROM user WHERE username='Dennis Wrenn'");
  $adminid = $adminstuff["userid"];
  $adminsig = $adminstuff["signature"];
  $message = "Welcome to our forums $username \n The rest of the message goes here.\n-Admin";
  if($adminsig != "") {
    $adminsig = 1;
  } else {
    $adminsig = 0;
  }
  $DB_site->query("INSERT INTO privatemessage (privatemessageid,userid,touserid,fromuserid,title,message,dateline,showsignature,iconid,messageread,folderid,receipt) VALUES (NULL,$userid,$userid,$adminid,'".addslashes(htmlspecialchars("Welcome $username!"))."','".addslashes($message)."',".time().",'$adminsig','',0,0,0)");

Add this to register.php starting at line 407.


This works with vB 2.0.3.

Dockaych 08-05-2001 07:22 PM

Great, I'm about to upgrade to 2.03, I'll install that afterwards! Thanks!

mjames 08-05-2001 11:09 PM

What I do doesn't require a hack. Simply change your settings so all new users go into the Users Waiting E-mail Confirmation user group. Then change the permissions for that group so they can do anything regular members can. Then all you have to do is edit the appropriate e-mail template with your welcome message and there you go!

Dockaych 08-06-2001 05:08 AM

That sounds like a good idea, but how can I make it so that a PM is sent instead of a welcome email?

--dock

bedehi 10-08-2003 12:27 PM

hi dennis
how can i add this code to register.php
and where is register.php?
pls help me

sohrab ,

Sylvus 10-08-2003 06:29 PM

There is a hack that does this for you, found in the database. I use it on my own forum, v2.3.0

Syl...

delmarva 11-17-2006 12:30 AM

Will this hack still work in version 3.6.3?

Shazz 11-17-2006 12:34 AM

^Its built in..


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

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01127 seconds
  • Memory Usage 1,726KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete