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

Reply
 
Thread Tools
Bulletproof referral awards at registration Details »»
Bulletproof referral awards at registration
Version: 1.00, by MacMorag MacMorag is offline
Developer Last Online: Dec 2008 Show Printable Version Email this Page

Version: 3.5.0 Rating:
Released: 10-16-2005 Last Update: 11-04-2005 Installs: 41
Template Edits
 
No support by the author.

The way vb is set up, means that it is possible for a registering user to clear the "referred by" field when they are completing the registration form - thus robbing the referring member of a referral point.

The following mod is to the "register" template, and tests whether the registering member has followed a referral link, and if they have, it doesn't show the "referred by" field at all, but hides it, so that the referring member definitely gets the referral award.

In register template, look for:

<if condition="$show['referrer']">

before this add:

<if condition="$referrername">
<input type="hidden" name="referrername" value="$referrername" />
<else />


Now look for:

<tr>
<td>
$vbphrase[referrer]:<br />
<input type="text" class="bginput" name="referrername" value="$referrername" size="50" maxlength="250" />
</td>
</tr>
</table>
</fieldset>
</if>


After this, add:

</if>

And that's it. All very simple.

Show Your Support

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

Comments
  #2  
Old 10-17-2005, 10:05 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Interesting. I like this.
Reply With Quote
  #3  
Old 10-17-2005, 10:21 AM
Oblivion Knight's Avatar
Oblivion Knight Oblivion Knight is offline
 
Join Date: May 2002
Location: Sheffield, UK
Posts: 1,757
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

What a good idea.!
Reply With Quote
  #4  
Old 10-17-2005, 11:50 AM
The Realist's Avatar
The Realist The Realist is offline
 
Join Date: Oct 2001
Location: UK
Posts: 842
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nice idea M8, well done.
Reply With Quote
  #5  
Old 10-17-2005, 04:51 PM
007's Avatar
007 007 is offline
 
Join Date: Jan 2003
Location: United States
Posts: 872
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great idea! Installed!
Reply With Quote
  #6  
Old 10-17-2005, 06:08 PM
nexialys
Guest
 
Posts: n/a
Default

good... never thought of this detail... even if i browsed most of the templates.. lol
Reply With Quote
  #7  
Old 10-17-2005, 08:07 PM
hotrod1 hotrod1 is offline
 
Join Date: Apr 2005
Posts: 112
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Cool mod, thanks!
Reply With Quote
  #8  
Old 11-05-2005, 10:25 AM
o1dirtydog o1dirtydog is offline
 
Join Date: Aug 2005
Posts: 24
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

im gettnig the following error with the first edit

In register template, look for:

<if condition="$show['referrer']">

before this add:

<if condition="$referrername">
<input type="hidden" name="referrername" value="$referrername" />
<else />


Quote:
The following error occurred when attempting to evaluate this template:

Parse error: parse error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home/emceepla/public_html/forum/includes/adminfunctions_template.php(3532) : eval()'d code on line 233

This is likely caused by a malformed conditional statement. It is highly recommended that you fix this error before continuing, but you may continue as-is if you wish.
Reply With Quote
  #9  
Old 11-05-2005, 10:27 AM
o1dirtydog o1dirtydog is offline
 
Join Date: Aug 2005
Posts: 24
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

actually never mind, you have to do both edits before u save.

i was in the habit of saving after each edit.

thanks for this mod, it's great.
Reply With Quote
  #10  
Old 11-05-2005, 11:09 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Please post this in a text file for those who want to re-add it after an upgrade.
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 03:34 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.04460 seconds
  • Memory Usage 2,289KB
  • Queries Executed 23 (?)
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
  • (1)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
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (9)postbit_onlinestatus
  • (10)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