Jump to content

How to create separate pages for login and signup


Tech Support
 Share

Recommended Posts

Most of KVS themes come with popups for utility forms, such as login and signup. If you need to refer login or signup popups, you can do that without actually having them as separate pages:

https://kvs-demo.com/?login
https://kvs-demo.com/?signup

If you want to create separate pages for them with custom design, you can also do that by following this guide.

 

Creating login page

Step 1. In Website UI -> Pages create a new page with the following template code:

{{assign var="page_title" value=$lang.html.login_title}}
{{assign var="page_canonical" value=$lang.urls.login}}

{{include file="include_header_general.tpl"}}

<div class="content">
	<div class="main-content">
		<div class="main-container">
			{{insert name="getBlock" block_id="logon" block_name="Logon Form"}}
		</div>
	</div>
</div>

{{include file="include_footer_general.tpl"}}

 Set page External ID to login, you can set title to Login, this is only title for admin panel.

NOTE: if you have error message saying that there are no permissions to create files, you have 2 choices:

  • Either put 777 permissions on the directory where KVS is installed (using FTP client or server File manager tool)
  • Or manually create /login.php file in the document root with the following code:
    <?php require_once("admin/include/process_page.php");?>

 

Step 2. After you saved page in Step 1, you should see Logon Form block added to this page's blocks list at the bottom. Open it for editing. Now open another browser tab and go to Website UI -> Global blocks -> Logon Form and copy template code and block parameters from there into the settings of Logon Form on the new login page.

 

Step 3. In /.htaccess file in the root directory of your project find these 2 lines:

RewriteRule ^login/$                                index.php?mode=async&function=get_block&block_id=logon_logon_form&global=true [L,QSA]
RewriteRule ^login-required/$                       index.php?mode=async&function=get_block&block_id=logon_logon_form&global=true&error=only_for_members [L,QSA]

and change them to these:

RewriteRule ^login/$                                login.php [L,QSA]
RewriteRule ^login-required/$                       login.php?error=only_for_members [L,QSA]

 

Step 4. In Website UI -> Texts add new text for rendering title of your newly selected login page:

  • External ID: html.login_title
  • Default: Login Page Title

 

Now you should be able to click on login link in header and see your new login page. Do you still see it is open in popup instead of separate page? If yes, please update this file on your server with a newer version from kvs-demo.com (only for KVS default theme):

https://kvs-demo.com/static/js/main.min.js

 

Creating signup page

Step 1. In Website UI -> Pages create a new page with the following template code:

{{assign var="page_title" value=$lang.html.signup_title}}
{{assign var="page_canonical" value=$lang.urls.signup}}

{{include file="include_header_general.tpl"}}

<div class="content">
	<div class="main-content">
		<div class="main-container">
			{{insert name="getBlock" block_id="signup" block_name="Signup Form"}}
		</div>
	</div>
</div>

{{include file="include_footer_general.tpl"}}

 Set page External ID to signup, you can set title to Signup, this is only title for admin panel.

NOTE: if you have error message saying that there are no permissions to create files, you have 2 choices:

  • Either put 777 permissions on the directory where KVS is installed (using FTP client or server File manager tool)
  • Or manually create /login.php file in the document root with the following code:
    <?php require_once("admin/include/process_page.php");?>

 

Step 2. After you saved page in Step 1, you should see Signup Form block added to this page's blocks list at the bottom. Open it for editing. Now open another browser tab and go to Website UI -> Global blocks -> Signup Form XXX and copy template code and block parameters from there into the settings of Signup Form on the new signup page.

NOTE: There are multiple different signup forms support in KVS themes: Simple signup form is default, Simple2 signup form requires email as a login, Advanced signup form renders additional profile fields on signup; finally Premium signup form renders paid access options. Choose the form that you need and copy its template and settings.

 

 Step 3. In /.htaccess file in the root directory of your project find this line:

RewriteRule ^signup/$                               index.php?mode=async&function=get_block&block_id=signup_signup_form_simple&global=true [L,QSA]

and change it to this:

RewriteRule ^signup/$                               signup.php [L,QSA]

 

Step 4. In Website UI -> Texts add new text for rendering title of your newly selected signup page:

  • External ID: html.signup_title
  • Default: Signup Page Title

 

Now you should be able to click on signup link in header and see your new signup page. Do you still see it is open in popup instead of separate page? If yes, please update this file on your server with a newer version from kvs-demo.com (only for KVS default theme):

https://kvs-demo.com/static/js/main.min.js

 

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...