Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Details »»

Version: 1.00, by Steve_S Steve_S is offline
Developer Last Online: Nov 2023 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 01-10-2002 Last Update: Never Installs: 22
 
No support by the author.

Tell A Friend + Automatic Referral Code

Edited 1-13-01. JavaScript pop version available at:

https://vborg.vbsupport.ru/showthrea...838#post212838

The JS version permits you to place the link anywhere you want on your board.

This version in this post returns your members to the thread they were reading using the same browser window.



Purpose: Permit members to promote your Board via email using their unique Referral code which is automatically inserted. Reward them for x number of referrals

Does not require any modifications to source code but does require hacking.

Requires 3 custom templates and a renamed and hacked version of sendtofriend.php which I have called referbbtofriend.php

1. Create 3 custom templates which are really a save of your current templates with a new name:

sendtofriend saved as referbbtofriend
email_sendtofriend saved as email_referbbtofriend
redirect_sentemail saved as redirect_referbbsentemail

2. Edit your custom templates. See zip for mine

3. Grab your copy of sendtofriend.php and save it as referbbtofriend.php

Edit referbbtofriend.php as follows and place in your forum root:

Code:
Change this line
< $templatesused = "sendtofriend,email_sendtofriend,redirect_sentemail";
--- To this line
> $templatesused = "referbbtofriend,email_referbbtofriend,redirect_referbbsentemail";
Change this line
<   eval("dooutput(\"".gettemplate("sendtofriend")."\");");
--- To This line
>   eval("dooutput(\"".gettemplate("referbbtofriend")."\");");
Change this line
<   eval("\$message = \"".gettemplate("email_sendtofriend",1,0)."\";");
--- To This line
>   eval("\$message = \"".gettemplate("email_referbbtofriend",1,0)."\";");
Change this line
<   eval("standardredirect(\"".gettemplate("redirect_sentemail")."\",\"showthread.php?s=$session[sessionhash]&threadid=".intval($threadid)."\");");
--- To This line
>   eval("standardredirect(\"".gettemplate("redirect_referbbsentemail")."\",\"showthread.php?s=$session[sessionhash]&threadid=".intval($threadid)."\");");
4. Insert this link in your Show Thread Templates >> showthread template

Code:
<a href="referbbtofriend.php?s=$session[sessionhash]&threadid=$threadid">Tell a friend about your Board</a>
Notes: Uses a redirect to return them to the thread they were reading.

Thoughts and comments welcome.

Show Your Support

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

Comments
  #42  
Old 02-02-2002, 08:34 PM
LuBi LuBi is offline
 
Join Date: Oct 2001
Posts: 416
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

From what I've read you have to manually place the links to the JS script around the board.. Isn't there a simple way to make a template that will replace them all? Like a way to make all the old refer a friend links link to the JS popup? Maybe using a new template or replacing the old with this new code..? Clarification would be great.
Reply With Quote
  #43  
Old 02-05-2002, 02:33 AM
Evoir Evoir is offline
 
Join Date: Nov 2001
Posts: 72
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Steve,

This is a really nice hack. Thanks.

I saw you mention in this thread that you weren't able to get the error code just the way you wanted it. What is happening for me is that if the fields are not filled out properly, the system uses the header and footer file, but within the javascript window. I believe I followed your directions completely. This only happens on the error page.

Is this supposed to be this way? Can it be fixed so the error message goes into the javascript window like the referbbsentemail_thanks template does?
Reply With Quote
  #44  
Old 02-08-2002, 01:29 PM
Lucky Lucky is offline
 
Join Date: Dec 2001
Posts: 234
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Works in 2.2.2

Thank you kindly!
Reply With Quote
  #45  
Old 03-04-2002, 02:40 AM
wvvwnet wvvwnet is offline
 
Join Date: Feb 2002
Posts: 10
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for this great code, but
I wonder if I can use the next URL
http://www.your-domain.com/register....&action=signup
will that account a point for the one whois # is (2)?
Or they will be able to register but will not account as a point?
What I mean, visitors will go directly to the sign up page instead of the mean page of the forum.
What do you think about that
Reply With Quote
  #46  
Old 03-14-2002, 08:46 AM
Birdie501's Avatar
Birdie501 Birdie501 is offline
 
Join Date: Dec 2001
Location: Germany
Posts: 272
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How can i change the configuration that if someone is not logged it that he first has to log in before he can see the pop up! Because i don't like it that the user is called "unregistered"??

Thanks! btw really nice hack!
Reply With Quote
  #47  
Old 03-17-2002, 04:51 AM
Michael2's Avatar
Michael2 Michael2 is offline
 
Join Date: Nov 2001
Posts: 188
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just wanted to thank you for your work on this! I love it!
Reply With Quote
  #48  
Old 03-18-2002, 10:14 AM
Webmasta XT's Avatar
Webmasta XT Webmasta XT is offline
 
Join Date: Mar 2002
Posts: 359
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

cool hack dude, nice work!!
Reply With Quote
  #49  
Old 05-03-2002, 08:50 PM
freeshares1 freeshares1 is offline
 
Join Date: Mar 2002
Posts: 127
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just installed the javascript one and it works great.

Thanks

Phil
Reply With Quote
  #50  
Old 06-23-2002, 10:48 PM
Bro_Joey_Gowdy's Avatar
Bro_Joey_Gowdy Bro_Joey_Gowdy is offline
 
Join Date: May 2002
Location: Hickory Flat MS 38633
Posts: 364
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Can something like this :

http://www.joeygowdy.com/forum/previ...te-friend.html

be done for vb2.2.6 ??

If its already made - then where is it at
Reply With Quote
  #51  
Old 07-07-2002, 05:08 PM
wvvwnet wvvwnet is offline
 
Join Date: Feb 2002
Posts: 10
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Dear sir,
I have
2.0.2
and when I click on the link, I got blank page says


Fatal error: Call to undefined function: updateuserforum() in /home/alameer/public_html/amt/referbbtofriend.php on line 22


please help
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 02:40 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.11201 seconds
  • Memory Usage 2,305KB
  • 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
  • (2)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
  • (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