vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Send default PM to all new users (https://vborg.vbsupport.ru/showthread.php?t=34498)

bandersen 05-07-2002 02:23 PM

I have no other hacks in the register.php.
I even tried a clean install of the original file just in case... included the code again... but still nothing. I made sure everything was checked "yes" if to receive PMs or not....

vbf.Falco171 05-07-2002 03:39 PM

Yes, same for me...

Sparkz 05-07-2002 04:00 PM

If at least I was able to reproduce the problem, I could try to solve it. Sorry for not being able to help you guys :/

vbf.Falco171 05-07-2002 08:07 PM

I've a first correction for this hack...

In php file of the hack, replace on line 17 and 18, $username by \$username, because with $username you can't see this text in admin panel...

Sparkz 05-07-2002 08:18 PM

I actually knew about that one. Just forgot to update the file :)

bonnmac 05-08-2002 05:34 PM

Thank You very much for this hack. I've installed it and it works great. Will make for a nice friendly atmosphere of a board to be welcomed.

vbf.Falco171 05-09-2002 07:28 PM

Ouhhh I've the solution, from Nicolas2000 a moderator of vBulletin-France Team...

The new code to insert into register.php :
PHP Code:

// Sparkz - Send Default PM to new users
   
if ($defpmactive && ($defpmadminmail || $adminemail)) {
      
$DB_site->query ("INSERT INTO privatemessage
                        (privatemessageid,userid,touserid,fromuserid,title,message,dateline,messageread,folderid)
                        VALUES (NULL,
$userid,$userid," $defpmuserid ",'" addslashes (htmlspecialchars (str_replace ('$username'$username$defpmsubject))) . "','".addslashes (htmlspecialchars (str_replace ('$username'$username$defpmbody))) . "',".time().",0,0)");
      if (
$pmpopup) {
         if (
$noshutdownfunc) {
            
$DB_site->query("UPDATE user SET pmpopup=2 WHERE userid='$userid'");
         } else {
            
$shutdownqueries[]="UPDATE user SET pmpopup=2 WHERE userid='$userid'";
         }
      }
   }
// Sparkz - Send Default PM to new users 

Modifications in php file :
PHP Code:

         $optionstemplate=generateoptions();
         
$DB_site->query("UPDATE template SET template='$optionstemplate' WHERE title='options'"); 

Put that on line 34 after } and on line 71 after } .

I test it and it run ! But the installation and un-installation don't work

bandersen 05-09-2002 08:41 PM

Vive la France!!!!

Can you pls. tell what's on line 34 and 71... just in case we do not have the same? then I'll try it out. thanks.

vbf.Falco171 05-09-2002 09:25 PM

Ouais vive la Belgique, vive la France, vive les pays Francophones :)

And for answer you :
On line 34 after
PHP Code:

       } elseif ($result['total'] > 1) {
            echo 
'<tr class="'.getrowbg().'" valign="top"><td><p><font size="1">Les param&egravetres existent d&eacuteja ' $result['total'] . ' fois</font></p></td></tr>';
            echo 
'<tr class="'.getrowbg().'" valign="top"><td><p><font size="1">Essayez de modifier vos param&egravetres.</font></p></td></tr>';
         } 

and on line 71 after
PHP Code:

            }
         } else {
            echo 
'<tr class="'.getrowbg().'" valign="top"><td><p><font size="1">Impossible de trouver des param?tres ? supprimer.</font></p></td></tr>';
         } 


Sparkz 05-09-2002 10:08 PM

I will look at it and update the files tomorrow... I've already had a few beers, so I'm not gonna mess with any code now :)


All times are GMT. The time now is 03:27 AM.

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.01200 seconds
  • Memory Usage 1,749KB
  • 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
  • (4)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)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