This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to add Custom text to or change text on the sign in/login page?

I would like to add some custom text to the sign in page, or possibly change the text. Right now it is set to:

"Please Sign In

To access your applications."

We will be using LDAP with SBM so I'd like to add text reminding users to use their network logins.

I found loginform.html and modified it with the text I wanted, but this file is being overwritten as soon as i restart the application on IIS.

Just for information, We are not using workcenter page to login.

  • 0  

    The customization options are documented here: SBM 11.7.1+: How to customize the SBM Work Center login screen with my company logo (microfocus.com)

    Maybe add some text at the bottom (section #5), or change the subheading (section #4).

    I hope that helps.

  • 0 in reply to   

    Thank you for your response Vickie.

    But, As I mentioned above, We are not using work center login page. We are using tmtrack page only. We have 11.04 version.

    The link mentioned above is only for work center.

  • 0   in reply to 

    Hi Anil, 

    That KB references articles for the various versions.  See this KB for branding the classic interface.  It does assume that the login page in use is the SSO login page. 

    If you are using "SBM Sessions" under authentication, you can easily switch that to Single Sign On for a more modern authentication system. 

    The SBM Sessions login page is the login.htm file in C:\Program Files\Serena\SBM\Application Engine\template.  You would need to Put Files in DB after updating this page.

    David

  • 0 in reply to   

    what do you mean by "You would need to Put Files in DB after updating this page.". Could you please give more details about this. I mean which table?

  • 0   in reply to 

    David may have more details to share, but for this "put" question.... On the SBM server, there is an application called "SBM System Administrator". Open that application, and go to Fiile > "Put fies into database". The system will take care of updating the tables.

  • 0   in reply to 

    This is only If you are using "SBM Sessions" under authentication.  We recommed using Single Sign On as it is newer and more robust.

    1. Modify the login.htm file in C:\Program Files\Serena\SBM\Application Engine\template. 

    2. Stop IIS and copy it into C:\Program Files\Serena\SBM\Application Engine\template. 

    3. On the server, Open the SBM System Administrator and login to the database.

    4. Go to File > Put Files in database.

    5. Sart IIS.

  • 0 in reply to   

    I see that we are using loginform.html. I am trying to add some custom data to it. Then I upload files to database. Nothing happens. Below is the code for loginform. Not sure where I am going wrong.

    <!DOCTYPE html>
    <html>
    <!--loginform-->
    <head>
    <title>$TITLE()</title> $INCLUDE(ttcharset)
    <link rel="shortcut icon" href="images/favicon.ico" />
    $JAVASCRIPT(3rdparty/jquery-sbm.min.js)
    $JAVASCRIPT(3rdparty/jquery-migrate-1.4.1.min.js)
    $JAVASCRIPT(3rdparty/jquery.jsonp.serena.min.js)
    <script type="text/javascript">
    var defaultTitle = '$TITLE()';
    var bWaitForStyles = false;

    function SetSecureCookie(name, value, expires, path, domain)
    {
    setCookie(name, value, expires, path, domain, "SecureIfHttps");
    }

    function setCookie(name, value, expires, path, domain, secure)
    {
    var newCookie = name + "=" + escape (value) +
    ((expires) ? "; expires=" + expires : "") +
    ((path) ? "; path=" + path : "") +
    ((domain) ? "; domain=" + domain : "");

    if (secure)
    {
    if (secure != "SecureIfHttps" || "https:" == document.location.protocol )
    {
    newCookie += "; secure";
    }
    }
    document.cookie = newCookie;
    }

    function getTeamtrackRootWindow(currentWindow) {
    return _getTeamtrackRootWindow(currentWindow, currentWindow);
    }

    function _getTeamtrackRootWindow(currentWindow, storedAeWindow) {
    var currentWindowHasAeTemplate = false;
    var reachedTheTopFrame = (currentWindow == currentWindow.parent);
    try {
    if (currentWindow.windowHtmlTemplate != undefined) {
    currentWindowHasAeTemplate = (currentWindow.windowHtmlTemplate.indexOf('ae_') != -1);
    }

    if (reachedTheTopFrame) {
    if (currentWindowHasAeTemplate) {
    return currentWindow;
    }
    else {
    return storedAeWindow;
    }
    }
    else {
    if (currentWindowHasAeTemplate) {
    return _getTeamtrackRootWindow(currentWindow.parent, currentWindow);
    }
    else {
    return _getTeamtrackRootWindow(currentWindow.parent, storedAeWindow);
    }
    }
    }
    catch (e) {
    return storedAeWindow;
    }
    }

    $(document).ready(function(){
    // Frame busting
    var teamtrackRootWindow = getTeamtrackRootWindow(window);
    if (teamtrackRootWindow != self) {
    teamtrackRootWindow.location = teamtrackRootWindow.location;
    }

    var loadingMsg = $("#loading");
    var height = $(window).height();
    var width = $(document).width();

    loadingMsg.css({
    'left' : width/2 - (loadingMsg.width() / 2), // half width - half element width
    'top' : height/2 - (loadingMsg.height() / 2) // similar
    });

    // Set up mouseovers for buttons
    $("#logonButton").hover(
    function(){$(this).removeClass("roundedbutton").addClass("roundedbuttonHover")},
    function(){$(this).removeClass("roundedbuttonHover").addClass("roundedbutton")}
    )
    $("#clientCertLogonButton").hover(
    function(){$(this).removeClass("roundedbutton").addClass("roundedbuttonHover")},
    function(){$(this).removeClass("roundedbuttonHover").addClass("roundedbutton")}
    )

    // Set up the click handlers for the buttons
    $("#logonButton").click(function(){
    $(this).attr("disabled","disabled");
    $("#clientCertLogonButton").attr("disabled","disabled");
    document.lf.submit();
    });

    // Set up the error message
    var errormsg = "$MESSAGE()";
    if ( errormsg!= "" ){
    $(".formmessage").text(errormsg).addClass("errormsg");
    }

    // Set up the call back to get the catalog file
    $.jsonp({
    url: "$DLL()AnonymousUse&template=ssocatalog.jsvar",
    callbackParameter: "loginui",
    timeout: 10000,
    cache : true,
    success:
    function(data){
    if ( data.stylesheet )
    {
    bWaitForStyles = true;
    var sStyleLink;
    var path = "";
    // Did we get a relative URL for the stylesheet?
    if ( data.stylesheet.indexOf( "http" ) == -1 )
    {
    var match = location.href.match("(.+)\/");
    path = (match===null)?"":match[0];
    sStyleLink = "<link rel='stylesheet' type='text/css' href='"+path+data.stylesheet+"' />";
    }
    else {
    sStyleLink = "<link rel='stylesheet' type='text/css' href='"+data.stylesheet+"' />";
    }
    $(sStyleLink).appendTo("head").ready(function(){DisplayPage();});
    }
    if ( data.title && data.title != "" )
    {
    defaultTitle = data.title;
    document.title = defaultTitle;
    }
    if ( data.logoLink && data.logoLink!="" )
    $("#intro a").attr("href", data.logoLink);
    if ( data.introMsg )
    $("#intro .msg").html(data.introMsg.replace(/<\/?script>/i,"noscripttags"));
    if ( data.usernameFld ) {
    if ( typeof(data.usernameFld.label) === "string" )
    $(".usernameLabel").text( data.usernameFld.label );
    if ( typeof(data.usernameFld.placeholder) === "string" )
    $("#authUID").attr( "placeholder", data.usernameFld.placeholder );
    }
    if ( data.passwordFld ) {
    if ( typeof(data.passwordFld.label) === "string" )
    $(".passwordLabel").text( data.passwordFld.label );
    if ( typeof(data.passwordFld.placeholder) === "string" )
    $("#authPWD").attr( "placeholder", data.passwordFld.placeholder );
    }
    if ( data.useridHelp )
    $("#formContainer .usernameLabel span.small").text(data.useridHelp);
    if ( data.passwordHelp )
    $("#formContainer .passwordLabel span.small").text(data.passwordHelp);
    if ( data.links ) {
    var link;
    for ( value in data.links )
    {
    link = data.links[value];
    // Do we have a relative link?
    if ( link.indexOf( "http" ) === -1 )
    link = path + link;
    $("<li><a href='"+link+"'>"+value+"</a></li>").appendTo("#links ul");
    }
    }
    if ( data.extraDiv1 )
    $("#extraDiv1").html(data.extraDiv1.replace(/<\/?script/gi,"noscripttags"));
    if ( data.extraDiv2 )
    $("#extraDiv2").html(data.extraDiv2.replace(/<\/?script/gi,"noscripttags"));
    if ( data.extraDiv3 )
    $("#extraDiv3").html(data.extraDiv3.replace(/<\/?script/gi,"noscripttags"));
    if ( data.extraDiv4 )
    $("#extraDiv4").html(data.extraDiv4.replace(/<\/?script/gi,"noscripttags"));
    },
    complete:
    function(){
    if ( !bWaitForStyles ){
    DisplayPage();
    }
    else
    {
    setTimeout( DisplayPage, 500 );
    }
    }
    });
    });

    function doSubmit()
    {
    SetSecureCookie("ttloggedoff","f");

    try
    {
    if (window.parent && window.parent.opener && window.parent.opener.document && window.parent.opener.document.lf && window.parent.opener.document.lf.ttAuthUID)
    {
    window.parent.opener.document.lf.ttAuthUID.value = document.lf.ttAuthUID.value;
    window.parent.opener.document.lf.ttAuthPWD.value = document.lf.ttAuthPWD.value;
    document.lf.RequestURL.value = "StdPage&Template=loginformcln";
    }
    }
    catch( er )
    {
    // Catch an error that's thrown when opening in a window that's hijacked by Outlook Express
    }
    return true;
    }
    function DisplayPage() {
    setTimeout(function(){
    $("body").removeClass("white");
    $("#container").show();
    $("#loading").hide();
    document.title = defaultTitle;
    // Set initial focus
    $("#authUID").focus();
    },500
    );
    }
    </script>
    <style type="text/css">
    html {
    overflow: auto;
    }
    BODY{
    background-color:#E7E3D6;
    font-family:Tahoma,Verdana, Arial, Helvetica, sans-serif;
    color:#2c2e2b;
    }
    #container {
    overflow: hidden;
    }
    A{
    color:#333333;
    text-decoration:none;
    }
    A:hover{
    color:#333333;
    text-decoration:none;
    border-bottom:1px dotted #333333;
    }


    #formContainer p, #formContainer h1, #formContainer form, #formContainer button{
    border:0;
    margin:0;
    padding:0;
    }
    #formContainer{
    margin:0 auto;
    width:500px;
    padding:14px;
    background-color:#F7F7EF;
    border:2px solid #63614A;
    }
    #formContainer h1 {
    font-size: larger;
    font-weight:bold;
    margin-bottom:8px;
    }
    #formContainer p{
    font-size: smaller;
    color:#666666;
    margin-bottom:20px;
    border-bottom:solid 1px #2c2e2b;
    padding-bottom:10px;
    }
    #formContainer label{
    display:block;
    font-weight:bold;
    text-align:right;
    width:140px;
    float:left;
    }
    #formContainer .small{
    color:#666666;
    display:block;
    font-size: smaller;
    font-weight:normal;
    text-align:right;
    width:140px;
    }
    #formContainer input{
    float:left;
    padding:4px 2px;
    border:solid 1px #2c2e2b;
    width:200px;
    margin:2px 0 20px 10px;
    }
    #formContainer button{
    clear:both;
    margin-left:150px;
    height:31px;
    text-align:center;
    line-height:31px;
    color:#2C2E2B;
    font-size: smaller;
    font-weight: bold;
    }
    #formContainer button.roundedbutton
    {
    background-color:#B5B095;
    background-image:url("images/$THEME()/buttonback.png");
    padding-left: 5px;
    padding-right: 5px;
    }
    #formContainer button.roundedbuttonHover
    {
    background-image:url("images/$THEME()/buttonbackhover.png");
    padding-left: 5px;
    padding-right: 5px;
    }
    #formContainer button.smartcard {
    margin-left: 5px;
    }
    #formContainer .errormsg
    {
    color: #A83838;
    font-weight: bold;
    text-decoration: none;
    width:100%;
    }

    #intro .msg
    {
    font-weight: bold;
    text-decoration: none;
    width:100%;
    text-align: center;
    padding-top: 20px;
    padding-bottom: 20px;
    }
    #links
    {
    margin:0 auto;
    width:400px;
    padding:14px;
    }
    #links ul {
    padding: 0;
    text-align: center;
    }
    #links li
    {
    list-style: none;
    }

    #loading {
    background-color: white;
    background-image: url("images/$THEME()/loading.gif");
    background-repeat: no-repeat;
    background-position: left;
    width: 200px;
    height: 100px;
    margin: auto;
    border: 1px solid #2c2e2b;
    }
    #loading .text {
    padding-left: 60px;
    line-height: 100px;
    }

    .white {
    background-color: white;
    }
    .logo {
    background-image: url("images/$THEME()/shell_logo.png");
    height: 50px;
    width: 108px;
    margin: 15px;
    background-repeat: no-repeat;
    background-size: contain;
    }
    </style>
    </head>
    <body class="white">
    <div id="container" style="display:none">
    <div id="intro">
    <a href="$STRING(IDS_ABOUT_SERENAHOMEPAGEURL)" title="$STRING(IDS_ABOUT_SERENAHOMEPAGEURL)" target="_tab"><div class="logo logo-default" title=""></div></a>
    <div class="msg"></div>
    </div>
    <div id="formContainer" class="myform">
    <form autocomplete="off" id="LoginForm" name="lf" method="POST" action="$DLL()LoginPage" onsubmit="doSubmit()">
    <h1 class="formtitle">$STRING(IDS_LOGIN_PLEASESIGNIN)</h1>
    <p class="formmessage">$STRING(IDS_LOGIN_TOACCESS)</p>

    <label class="usernameLabel">$STRING(IDS_LOGIN_USERID):
    <span class="small"></span>
    </label>
    <input type="text" id="authUID" name="ttAuthUID" title="$STRING(IDS_LOGIN_USERID)"/>

    <label class="passwordLabel">$STRING(IDS_LOGIN_PASSWORD):
    <span class="small"></span>
    </label>
    <input type="password" id="authPWD" name="ttAuthPWD" title="$STRING(IDS_LOGIN_PASSWORD)" />

    <button
    name="logonButton"
    id="logonButton"
    class="roundedbutton"
    title="$STRING(IDS_BTN_LOGIN)"
    type="submit">$STRING(IDS_BTN_LOGIN)</button>

    <input type="hidden" name="RequestURL" value="$REQUESTURL()" ID="Hidden1">
    <input type="hidden" name="Action" value="login" ID="Hidden2">

    </form>
    </div>
    <div id="links">
    <ul>
    <li></li>
    </ul>
    </div>
    <!-- Here is a block of empty containers to drop additional content into -->
    <div id="extraDiv1"><div class="text">$STRING(IDS_CALENDAR_OVERRIDEVALIDATION)</div></div>
    <div id="extraDiv2"></div>
    <div id="extraDiv3"></div>
    <div id="extraDiv4"></div>
    </div>
    <div id="loading"><div class="text">$STRING(IDS_LOADING)</div></div>
    </body>
    </html>

  • 0   in reply to 

    It could be that the browser is caching your login html file.  You should make sure to clear your browser cache, and reload your browser.

    I would suggest that you switch over to Single Sign On browser sessions and modify the SSO login page instead.

  • 0 in reply to   

    I did clear and used Incognito mode of browser also before posting. I should have mentioned that. but no change.

    I tried adding some extra div with some sample text, no use. Its not in my hand to take up a project of moving to SSO yet. So I need to fix this page.

    One thing I tried is updating data displayed by a variable named "IDS_LOGIN_TOACCESS". It did change text on UI but I could not add any extra text on UI.

  • 0 in reply to 

    Does it take couple of hours to take effect? I used an existing variable and added it to loginform. It did not come up after few minutes but it came up on page after few hours.