Sign up page for one product

Discussion in 'Templates customization' started by pascalevdb, Dec 24, 2012.

  1. pascalevdb

    pascalevdb Member

    Joined:
    May 30, 2007
    Messages:
    41
    amember 3.1.4

    want to create a signup page for one specific product, where it does NOT request address information. product is free-no credit card info needed.

    any suggestions?
  2. alexander

    alexander Administrator Staff Member

    Joined:
    Jan 8, 2003
    Messages:
    6,279
    Assign negative price group for that product, it will be removed from default signup page and will become available by special url: /amember/signup.php?price_group=-1 (for example)
    Then edit signup template change this line:
    {if $config.use_address_info}

    to
    {if $config.use_address_info && $smarty.request.price_group <> -1}

    Above will remove address info block.
  3. pascalevdb

    pascalevdb Member

    Joined:
    May 30, 2007
    Messages:
    41
    awesome! that worked. anyway I can also delete the first and last name field?
    thank you in advance.
  4. alexander

    alexander Administrator Staff Member

    Joined:
    Jan 8, 2003
    Messages:
    6,279
    Delete them from template, or if you want to remove these fields from price_group=-1 signup page apply these tags around these fields:
    {if $smarty.request.price_group <> -1}
    {/if}
    Then remove validation of these fields from signup.php:
    if (!strlen($vars['name_f'])){
    $error[] = _SIGNUP_PLEASE_ENTER_FNAME;
    }
    if (!strlen($vars['name_l'])){
    $error[] = _SIGNUP_PLEASE_ENTER_LNAME;
    }

Share This Page