Translations of this page:

How to change the login page?

Here is a way to change the login page, and use your own login page.

Requirements :

Your procedure building the login page must have a parameter for entering a desired page, where the user want to go.

  • p_requested_url : Destination url where the user will be redirected if the connection is ok.
  • p_cancel_url : Destination url where the user will be redirected if the connection is canceled.

Step by step :

You can use any desired url here

Step 1

First we need to create a specific procedure (change the url to your own url)

Script : New Login Procedure

 
SET DEFINE OFF
 
-- Display_login2 procedure
-- 16/02/2005 by helyos : Modify the link when the passed url is null
-- 15/02/2005 by helyos : Add url_encode function
-- 14/02/2005 by helyos : Creation
CREATE OR REPLACE PROCEDURE display_login2(p_url VARCHAR2 DEFAULT NULL) IS
v_link VARCHAR2(32767);
BEGIN
-- Check if there is an asked url
IF p_url IS NOT NULL THEN
-- if the login credentials are ok redirect to the desired page
-- if the login credentials are wrong redirect to the home page
v_link := 'http://<servername>/<dad>/
PORTAL.wwsec_app_priv.login?p_requested_url=' ||
portal.wwv_standard_util.url_encode(p_url) ||
'&p_cancel_url=' ||
portal.wwv_standard_util.url_encode(forum_constant.c_url_website ||
forum_constant.c_url_dad ||
'/portal.home');
ELSE
-- if there is no url we redirect the user to a specific page.
v_link := 'http://<servername>/<dad>/
PORTAL.wwsec_app_priv.login?p_requested_url=' ||
portal.wwv_standard_util.url_encode(forum_constant.c_url_forum) ||
'&p_cancel_url=' ||
portal.wwv_standard_util.url_encode(forum_constant.c_url_forum);
END IF;
owa_util.redirect_url(v_link);
END;
/
 
SET DEFINE ON
 
GRANT EXECUTE ON display_login2 TO public;

Step 2

Now we need to change the rewrite Rule.

You will have to open your httpd.conf file with the OEM Website.

Replace the login rule Example : Changing rewrite rule

Changing rewrite rule

RewriteRule ^/forums/login/?$ http://<your server>/<your dad>/forum_app.forum_display.display_login [L,P,QSA]
By
RewriteRule ^/forums/login/?$ http://<your server>/<your dad>/forum_app.display_login2 [L,P,QSA]

 
forum/faq/change_login_page.txt · Last modified: 2009/08/12 09:35 by helyos
 
Except where otherwise noted, content on this wiki is licensed under the following license:CC Attribution-Noncommercial-Share Alike 3.0 Unported