Difference between revisions of "Custom Combined Sign-Up Page"

From SmartWiki
Jump to: navigation, search
Line 1: Line 1:
 +
The method below is no longer recommended as it involves hardcoding information. To create an organization and contact at the same time use [[Creating_a_System_Generated_Organization_and_Contact_signup_page|Creating a System Generated Organization and Contact signup page]]
 +
 
To create a Custom Combined Sign-Up Page (also known as a hybrid sign-up page), follow the instructions below:
 
To create a Custom Combined Sign-Up Page (also known as a hybrid sign-up page), follow the instructions below:
Note: A basic understanding of HTML and JavaScript is required to complete this task.
 
  
1. Create a '''Company Signup''' page within [[SmartSimple]]. Remember to set (as required):
+
Note: A basic understanding of HTML and JavaScript is required to complete this task.
 +
 
 +
1. Create a '''Company Signup''' page within [[SmartSimple]]. Remember to set (as required):
 +
 
 
* The '''mandatory''' and '''optional''' standard fields.
 
* The '''mandatory''' and '''optional''' standard fields.
 +
 
* The company '''categories'''.
 
* The company '''categories'''.
 +
 
* Insert the '''sample sign-up''' and '''confirmation''' template - required to save the page.
 
* Insert the '''sample sign-up''' and '''confirmation''' template - required to save the page.
 +
 
* Click the '''Activate Page''' option button.
 
* Click the '''Activate Page''' option button.
 +
 
* Set the '''Name Check''' field as appropriate (update profile or create new profile).
 
* Set the '''Name Check''' field as appropriate (update profile or create new profile).
 +
 
* Click the '''Save''' button.
 
* Click the '''Save''' button.
  
 +
2. Create a '''Contact Signup''' page within [[SmartSimple]]. Remember to set (as required):
  
2. Create a '''Contact Signup''' page within [[SmartSimple]]. Remember to set (as required):
 
 
* The '''mandatory''' and '''optional''' standard fields.
 
* The '''mandatory''' and '''optional''' standard fields.
 +
 
* The contact [[Role|roles]].
 
* The contact [[Role|roles]].
 +
 
* Insert the '''sample sign-up''' and '''confirmation''' template - required to save the page.
 
* Insert the '''sample sign-up''' and '''confirmation''' template - required to save the page.
 +
 
* Click the '''Activate Page''' option button.
 
* Click the '''Activate Page''' option button.
 +
 
* Set the '''Email Check''' field as appropriate (update profile or create new profile).
 
* Set the '''Email Check''' field as appropriate (update profile or create new profile).
 +
 
* Set the '''Enable Login''' - if required.
 
* Set the '''Enable Login''' - if required.
 +
 
* Click the '''Save''' button.
 
* Click the '''Save''' button.
  
 +
3. View the HTML source of both '''signup''' pages and join them together as desired.
  
3. View the HTML source of both '''signup''' pages and join them together as desired.
 
 
* Ensure there is only one form tag (see below), with action: '''/s_cpsignup.jsp'''
 
* Ensure there is only one form tag (see below), with action: '''/s_cpsignup.jsp'''
 +
 
* Both the '''ctoken''' from the company sigup and '''ptoken''' from the contact signup pages must be present. Example:
 
* Both the '''ctoken''' from the company sigup and '''ptoken''' from the contact signup pages must be present. Example:
    <form action='/s_cpsignup.jsp' method='POST' onsubmit='return sb(this);'>
+
 
   
+
<form action='/s_cpsignup.jsp' method='POST' onsubmit='return sb(this);'>
    &lt;!-- this must be company signup page token --&gt;
+
 
    <input type=hidden name=ctoken value="XVtQHUUGYFpfRBdfXxJSRlNZYg%3D%3D">
+
&lt;!-- this must be company signup page token --&gt;
    &lt;!-- this must be contact signup page token --&gt;
+
 
    <input type=hidden name=ptoken value="XVtQC1oGYFpfRBdfXxJSRlNZYg%3D%3D">
+
<input type=hidden name=ctoken value="XVtQHUUGYFpfRBdfXxJSRlNZYg%3D%3D">
 +
 
 +
&lt;!-- this must be contact signup page token --&gt;
 +
 
 +
<input type=hidden name=ptoken value="XVtQC1oGYFpfRBdfXxJSRlNZYg%3D%3D">
  
 
* Ensure there is only one Submit button.
 
* Ensure there is only one Submit button.
* If your Company and Contact signup pages both have a standard phone field. Leave the company field as is and rename the input for the contact phone to “uphone” example:
+
 
    <input type=text class='Large' name='uphone' id='uphone'>
+
* If your Company and Contact signup pages both have a standard phone field. Leave the company field as is and rename the input for the contact phone to “uphone” example:
 +
 
 +
<input type=text class='Large' name='uphone' id='uphone'>
  
 
* The JavaScript validations for the "Contact Signup" and "Company Signup" should both be executed when submit is clicked.
 
* The JavaScript validations for the "Contact Signup" and "Company Signup" should both be executed when submit is clicked.
 
+
 
 
 
 
4. With a new '''Restrict Duplicate Emails''' functionality (May 2013 upgrade [[Upgrades]]) when enabled on system sign up page by selecting '''Do not update profile for existing user''' you can look at the compiled source code and take out the script that use to check the duplicate and paste it into your smart folder hybrid page. The part of the code that you will need is the following within the sb(frm) function:
 
4. With a new '''Restrict Duplicate Emails''' functionality (May 2013 upgrade [[Upgrades]]) when enabled on system sign up page by selecting '''Do not update profile for existing user''' you can look at the compiled source code and take out the script that use to check the duplicate and paste it into your smart folder hybrid page. The part of the code that you will need is the following within the sb(frm) function:
  
var paramrs=new in_ssRecordSet();paramrs.addfieldnames("pageid,matchvalue");
+
var paramrs=new in_ssRecordSet();paramrs.addfieldnames("pageid,matchvalue");
var idx=paramrs.getnewrecnumber();
+
 
paramrs.addfieldvaluebyname(idx,"pageid",90);
+
var idx=paramrs.getnewrecnumber();
paramrs.addfieldvaluebyname(idx,"matchvalue",frm.cname.value);
+
 
if (!SS_UTADuplicateCheck(false,'',0,30,'0','0',paramrs)) {
+
paramrs.addfieldvaluebyname(idx,"pageid",90);
  return false;
+
 
}
+
paramrs.addfieldvaluebyname(idx,"matchvalue",frm.cname.value);
 +
 
 +
if (!SS_UTADuplicateCheck(false,'',0,30,'0','0',paramrs)) {
 +
 
 +
return false;
 +
 
 +
}
  
 
Also, make sure you include the javascript file "/Ajax/uta/in_uta.js" on the page as well
 
Also, make sure you include the javascript file "/Ajax/uta/in_uta.js" on the page as well
Note: the duplicate check script above will be different based on different settings on the signup page, so you cannot just copy and paste the code above for all signup page.  You have to look into the source of each individual signup page you are referencing.
 
  
 +
Note: the duplicate check script above will be different based on different settings on the signup page, so you cannot just copy and paste the code above for all signup page. You have to look into the source of each individual signup page you are referencing.
  
 
5. '''Save''' the page.
 
5. '''Save''' the page.
Line 61: Line 88:
  
 
==See Also==
 
==See Also==
 +
 
* [[System Combined Sign-Up Page]]
 
* [[System Combined Sign-Up Page]]
 
  
 
[[Category:System Management]][[Category:Sign-Up Features]]
 
[[Category:System Management]][[Category:Sign-Up Features]]

Revision as of 13:46, 28 February 2014

The method below is no longer recommended as it involves hardcoding information. To create an organization and contact at the same time use Creating a System Generated Organization and Contact signup page

To create a Custom Combined Sign-Up Page (also known as a hybrid sign-up page), follow the instructions below:

Note: A basic understanding of HTML and JavaScript is required to complete this task.

1. Create a Company Signup page within SmartSimple. Remember to set (as required):

  • The mandatory and optional standard fields.
  • The company categories.
  • Insert the sample sign-up and confirmation template - required to save the page.
  • Click the Activate Page option button.
  • Set the Name Check field as appropriate (update profile or create new profile).
  • Click the Save button.

2. Create a Contact Signup page within SmartSimple. Remember to set (as required):

  • The mandatory and optional standard fields.
  • Insert the sample sign-up and confirmation template - required to save the page.
  • Click the Activate Page option button.
  • Set the Email Check field as appropriate (update profile or create new profile).
  • Set the Enable Login - if required.
  • Click the Save button.

3. View the HTML source of both signup pages and join them together as desired.

  • Ensure there is only one form tag (see below), with action: /s_cpsignup.jsp
  • Both the ctoken from the company sigup and ptoken from the contact signup pages must be present. Example:

<form action='/s_cpsignup.jsp' method='POST' onsubmit='return sb(this);'>

<!-- this must be company signup page token -->

<input type=hidden name=ctoken value="XVtQHUUGYFpfRBdfXxJSRlNZYg%3D%3D">

<!-- this must be contact signup page token -->

<input type=hidden name=ptoken value="XVtQC1oGYFpfRBdfXxJSRlNZYg%3D%3D">

  • Ensure there is only one Submit button.
  • If your Company and Contact signup pages both have a standard phone field. Leave the company field as is and rename the input for the contact phone to “uphone” example:

<input type=text class='Large' name='uphone' id='uphone'>

  • The JavaScript validations for the "Contact Signup" and "Company Signup" should both be executed when submit is clicked.

4. With a new Restrict Duplicate Emails functionality (May 2013 upgrade Upgrades) when enabled on system sign up page by selecting Do not update profile for existing user you can look at the compiled source code and take out the script that use to check the duplicate and paste it into your smart folder hybrid page. The part of the code that you will need is the following within the sb(frm) function:

var paramrs=new in_ssRecordSet();paramrs.addfieldnames("pageid,matchvalue");

var idx=paramrs.getnewrecnumber();

paramrs.addfieldvaluebyname(idx,"pageid",90);

paramrs.addfieldvaluebyname(idx,"matchvalue",frm.cname.value);

if (!SS_UTADuplicateCheck(false,,0,30,'0','0',paramrs)) {

return false;

}

Also, make sure you include the javascript file "/Ajax/uta/in_uta.js" on the page as well

Note: the duplicate check script above will be different based on different settings on the signup page, so you cannot just copy and paste the code above for all signup page. You have to look into the source of each individual signup page you are referencing.

5. Save the page.

6. Create a web enabled Smart Folder and store the modified page in the folder.

7. Select the URL for this file through the File Options.

8. Use this URL as the link in the website.

See Also