Editing buttons and pages for third-party authentication

To use third-party authentication for portal users, you must add a QQ or email authentication button to the portal logon page. After a portal user clicks the QQ or email authentication button on the portal logon page, the user is redirected to the QQ or email authentication page.

Editing a third-party authentication button on the logon page

Edit a third-party authentication button on the portal logon page (logon.htm). For more information about editing portal authentication pages, see "Customizing authentication pages."

When you edit the QQ authentication button, you must call the pt_getQQSubmitUrl() function to get the URL of the QQ authentication page.

The following example shows part of the script of the QQ authentication button.

    <html>
    <head>
    <title>Logon</title>
    <script type="text/javascript" language="javascript" src="pt_private.js"></script>
<script type="text/javascript">
      function setQQUrl(){
          document.getElementById("qqurl").href = pt_getQQSubmitUrl();
            }
</script>
    </head>
    <body>
    ... ...
<a href="javascript:void(null)" id="qqurl" onclick="setQQUrl()">QQ</a>
    ... ...
    </body>
</html>

No special requirements exist in the process of editing an email authentication button.

Editing a third-party authentication page

You only need to edit the email authentication page. The QQ authentication page is provided by Tencent.

When you edit the email authentication page, follow the rules in "Customizing authentication pages" and the following rules:

The following example shows part of the script of the emailLogon.htm page.

<form action= maillogin.html method = post >
<p>User name:<input type="text" name = "PtUser" style="width:160px;height:22px" maxlength=64>
<p>Password :<input type="password" name = "PtPwd" style="width:160px;height:22px" maxlength=32>
<p><input type=SUBMIT value="Logon" name = "PtButton" style="width:60px;" onclick="form.action=form.action+location.search;>
</form>