vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=252)
-   -   registration process (https://vborg.vbsupport.ru/showthread.php?t=240630)

merk_aus 04-17-2010 04:26 AM

registration process
 
Hey all,
I was just wondering if there was a way to install a redirect through the registration process.

What I am trying to do is add a radio button check point field in the registration process for paid memberships so it will say:-
- Free Membership
- 3 Month Membership
- 6 Month Membership
- 1 Year Membership
- Life-time Membership

If they select Free Membership it registers them as usual, if they click any of the other options it registers them then immediately re-directs them to the paid membership/payment page with their selection (3m/6m/1y/LT) already selected and waiting for their paypal stuff.

Does anyone know how to do this?

NickyDee 04-17-2010 11:20 AM

I'm not sure what level your coding is at but on method of achieving this might be to stick some javascript into the registration template.

e.g. onClick="runFunction()" would go in the user profile field form. Then in the function something like;

HTML Code:

runFunction() {
var profilefield = '<vb:raw userprofilefieldX>';
if (profilefield == '3 months') { window.open('http://www.site.com/billing.php?duration=3','mywindow'); } else if
(profilefield == '6 months') { window.open('http://www.site.com/billing.php?duration=6','mywindow'); } else if
(profilefield == '1 year') { window.open('http://www.site.com/billing.php?duration=1,'mywindow'); } else if
(profilefield == 'LT') { window.open('http://www.site.com/billing.php?duration=0,'mywindow'); }
}

I haven't tested this and it will probably need modification to work, but its just to give you a general idea how you might achieve this.


All times are GMT. The time now is 10:26 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.01286 seconds
  • Memory Usage 1,710KB
  • 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_html_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (2)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete