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

Reply
 
Thread Tools
Automatically Start a Welcome Thread in the Forum of Your Choice Details »»
Automatically Start a Welcome Thread in the Forum of Your Choice
Version: 1.5, by amykhar amykhar is offline
Developer Last Online: Nov 2013 Show Printable Version Email this Page

Version: 3.5.0 Rating:
Released: 07-08-2005 Last Update: 10-16-2005 Installs: 272
Uses Plugins Template Edits
 
No support by the author.

This little mod will start a new thread in the forum of your choice when somebody registers.

The thread message is contained in a template, and easily customizeable on your part.

This version posts the thread when the user registers - but before he activates his email address.

Thanks to flypaper for providing a bugfix.

Installation Instructions: Import the product. Change the welcome_thread template to suit your needs. Change the setup variables in the welcome thread plugin to suit your needs.

Amy

Show Your Support

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

Comments
  #107  
Old 10-17-2005, 04:40 PM
WildSharky's Avatar
WildSharky WildSharky is offline
 
Join Date: Jun 2004
Posts: 69
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nope dont work i get this error

Fatal error: Cannot pass parameter 2 by reference in /usr/home/sharky/public_html/forums/register.php(419) : eval()'d code on line 31

PHP Code:
 // Insert thread 
    
$threaddm->do_set('forumid'$forumid); 
    
$threaddm->do_set('postuserid'$postuserid); 
    
$threaddm->do_set('userid'$postuserid); 
    
$threaddm->do_set('username'$postusername); 
    
$threaddm->do_set('pagetext'$pagetext); 
    
$threaddm->do_set('title'$title); 
    
$threaddm->do_set('allowsmilie'$allowsmilie); 
    
$threaddm->do_set('visible'$visible); 
    
$threaddm->do_set('showsignature'1); 
    
$tid $threaddm->save(); 
thats where i put it
Reply With Quote
  #108  
Old 10-17-2005, 05:01 PM
fly fly is offline
 
Join Date: Oct 2003
Posts: 1,215
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by WildSharky
nope dont work i get this error

Fatal error: Cannot pass parameter 2 by reference in /usr/home/sharky/public_html/forums/register.php(419) : eval()'d code on line 31



thats where i put it
In keeping with the same format for the rest of the plugin, use the following instead. (It didn't work previously cause I forgot the single quotes around the one)

PHP Code:
// Start thread create
    
$threaddm = new vB_DataManager_Thread_FirstPost($vbulletinERRTYPE_STANDARD);

    
$username htmlspecialchars_uni($username); 
    
$allowsmilie '1';
    
$visible '1';
    
$sig '1';  //show signature 1/on 0/off
    
eval('$pagetext .= "' fetch_template('welcome_thread') . '";'); 

// Insert thread
    
$threaddm->do_set('forumid'$forumid);
    
$threaddm->do_set('postuserid'$postuserid);
    
$threaddm->do_set('userid'$userid);
    
$threaddm->do_set('username'$postusername);
    
$threaddm->do_set('pagetext'$pagetext);
    
$threaddm->do_set('title'$title);
    
$threaddm->do_set('allowsmilie'$allowsmilie);
    
$threaddm->do_set('visible'$visible);
    
$threaddm->do_set('showsignature'$sig);
    
$tid $threaddm->save(); 
Reply With Quote
  #109  
Old 10-17-2005, 05:25 PM
WildSharky's Avatar
WildSharky WildSharky is offline
 
Join Date: Jun 2004
Posts: 69
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

here is the right code as your made the name wrong like befor.. and thanks the sig works now to..
this
PHP Code:
    $threaddm->do_set('userid'$userid); 
should be this
PHP Code:
    $threaddm->do_set('userid'$postuserid); 
PHP Code:
// Start thread create 
    
$threaddm = new vB_DataManager_Thread_FirstPost($vbulletinERRTYPE_STANDARD); 

    
$username htmlspecialchars_uni($username);  
    
$allowsmilie '1'
    
$visible '1'
    
$sig '1';  //show signature 1/on 0/off 
    
eval('$pagetext .= "' fetch_template('welcome_thread') . '";');  

// Insert thread 
    
$threaddm->do_set('forumid'$forumid); 
    
$threaddm->do_set('postuserid'$postuserid); 
    
$threaddm->do_set('userid'$postuserid); 
    
$threaddm->do_set('username'$postusername); 
    
$threaddm->do_set('pagetext'$pagetext); 
    
$threaddm->do_set('title'$title); 
    
$threaddm->do_set('allowsmilie'$allowsmilie); 
    
$threaddm->do_set('visible'$visible); 
    
$threaddm->do_set('showsignature'$sig); 
    
$tid $threaddm->save(); 
Reply With Quote
  #110  
Old 10-17-2005, 05:31 PM
fly fly is offline
 
Join Date: Oct 2003
Posts: 1,215
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by WildSharky
here is the right code as your made the name wrong like befor.. and thanks the sig works now to..
Oh yeah, forgot about that $userid thing.
Reply With Quote
  #111  
Old 10-17-2005, 09:54 PM
Mr Chad's Avatar
Mr Chad Mr Chad is offline
 
Join Date: Jul 2005
Posts: 911
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by chatbum
hey is it possible to make it post the users profile field info? If so please explain how, Because i want to use this as an introduction system where it posts all the required profile fields.
anyone?
Reply With Quote
  #112  
Old 10-19-2005, 12:27 AM
fly fly is offline
 
Join Date: Oct 2003
Posts: 1,215
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by chatbum
anyone?
Can you explain a little better what you're looking for?
Reply With Quote
  #113  
Old 10-19-2005, 09:51 AM
WildSharky's Avatar
WildSharky WildSharky is offline
 
Join Date: Jun 2004
Posts: 69
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You know what would make this hack nicer would be to send a pm to the user when theey sign up telling them they have a welcome post and a link in the pm to the post..


Think you can do that???
Reply With Quote
  #114  
Old 10-19-2005, 10:07 AM
jluerken's Avatar
jluerken jluerken is offline
 
Join Date: Aug 2003
Location: Germany
Posts: 1,016
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is this version not working with the welcome PM hack?
Reply With Quote
  #115  
Old 10-19-2005, 10:09 AM
WildSharky's Avatar
WildSharky WildSharky is offline
 
Join Date: Jun 2004
Posts: 69
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It might be as i havnt looked at all the addons on this forums so im not sure i will look for the welcome pm addon and try it thanks..
Reply With Quote
  #116  
Old 10-19-2005, 11:33 AM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by WildSharky
You know what would make this hack nicer would be to send a pm to the user when theey sign up telling them they have a welcome post and a link in the pm to the post..


Think you can do that???
In my version on my board, I had it hacked so that it redirected new users directly to their welcome thread after registration. But that took a file mod.
Reply With Quote
  #117  
Old 10-19-2005, 11:36 AM
WildSharky's Avatar
WildSharky WildSharky is offline
 
Join Date: Jun 2004
Posts: 69
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

can you give us that mod?
Reply With Quote
  #118  
Old 10-19-2005, 11:55 AM
fly fly is offline
 
Join Date: Oct 2003
Posts: 1,215
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by WildSharky
You know what would make this hack nicer would be to send a pm to the user when theey sign up telling them they have a welcome post and a link in the pm to the post..


Think you can do that???
This is how I did that.

PHP Code:
// Start thread create 
    
$threaddm = new vB_DataManager_Thread_FirstPost($vbulletinERRTYPE_STANDARD); 

    
$username htmlspecialchars_uni($username);  
    
$allowsmilie '1'
    
$visible '1'
    
$sig '1';  //show signature 1/on 0/off 
    
eval('$pagetext .= "' fetch_template('welcome_thread') . '";');  

// Insert thread 
    
$threaddm->do_set('forumid'$forumid); 
    
$threaddm->do_set('postuserid'$postuserid); 
    
$threaddm->do_set('userid'$postuserid); 
    
$threaddm->do_set('username'$postusername); 
    
$threaddm->do_set('pagetext'$pagetext); 
    
$threaddm->do_set('title'$title); 
    
$threaddm->do_set('allowsmilie'$allowsmilie); 
    
$threaddm->do_set('visible'$visible); 
    
$threaddm->do_set('showsignature'$sig); 
    
$tid $threaddm->save();  

// Now let's send a PM notifying the user of their thread
    
$userdata->save(); 
    
$fromuser '1'
    
$username unhtmlspecialchars($userinfo['username']); 
    
$registry =& $vbulletin;

// create the DM to do error checking and insert the new PM 
    
$pmdm =& datamanager_init('PM'$vbulletinERRTYPE_SILENT); 
    
$pmdm->set('fromuserid'$fromuser['userid']); 
    
$pmdm->set('fromusername'$fromuser['username']); 
    
$pmdm->set_info('receipt'false); 
    
$pmdm->set_info('savecopy'false); 
    
$pmdm->set('title'"Important information regarding your registration!"); 
    
$pmdm->set('message'"[center][b]AUTOGENERATED PM[/b][/center] \n Pending your full approval to xxxx Forums, we have created a thread for you.  The thread is located [url=http://xxxxxforums.com/showthread.php?t=" $tid "]here[/url].  This will be the only thread you can post in until an administrator approves your membership.  If you have any questions that you'd rather not post, feel free to reply to this private message. \n \n [url]http://xxxxxxforums.com/showthread.php?t=" $tid "[/url] \n [b]Note: You may have to log in again when clicking on the thread link above[/b]"); 
    
$pmdm->set_recipients($userinfo['username'], $fromuser['permissions']); 
    
$pmdm->set('dateline'TIMENOW); 
    
$pmdm->save();

// Fin 
There is some rough code in there. If that doesn't work, I'll check back later and help ya out. Right now busy w/ work...
Reply With Quote
  #119  
Old 10-19-2005, 12:22 PM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It's better to use the mod that was released for private messages already - do a search WildSharky. It's a plugin. That code has been thoroughly tested and used by hundreds of people.
Reply With Quote
  #120  
Old 10-19-2005, 01:48 PM
fly fly is offline
 
Join Date: Oct 2003
Posts: 1,215
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by amykhar
It's better to use the mod that was released for private messages already - do a search WildSharky. It's a plugin. That code has been thoroughly tested and used by hundreds of people.
But if you want to link to the thread created, it needs to be in the same plugin, afaik...
Reply With Quote
  #121  
Old 10-19-2005, 06:15 PM
Xplorer4x4 Xplorer4x4 is offline
 
Join Date: Apr 2005
Posts: 938
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This is working for me BUT it starts the thread by the person who registered....not me! I have filled out the proper variables in the XML file.
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 11:40 AM.


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.17399 seconds
  • Memory Usage 2,419KB
  • Queries Executed 30 (?)
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
  • (6)bbcode_php
  • (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
  • (1)pagenav_pagelinkrel
  • (16)post_thanks_box
  • (16)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (16)post_thanks_postbit_info
  • (15)postbit
  • (16)postbit_onlinestatus
  • (16)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