1. Kayako Download customers: we will continue to develop and support Kayako Download beyond July 2017, alongside the new Kayako for existing customers.

    Find out more.

  2. The forum you are viewing relates to Kayako Classic. If you signed up or upgraded to the new Kayako (after the 4th July 2016), the information in this thread may not apply to you. You can visit the forums for the new Kayako here.

Show subscribe via email only for registered users

Discussion in 'Developing, APIs and extending' started by icewarp_brasil, Jul 13, 2011.

  1. Hi, everyone

    Wondering if someone can please help.

    I want to display Subscribe (to receive emails in main portal page of kayako) option only for registered users, I was told I need to do modification in header template of your own.

    There's a feature request already on this:

  2. masterctrl1

    masterctrl1 Kayako Guru

    Anyone ever figure this out?
    It appears you need to edit the maincoreleft section, but I'm not sure about what conditional statement to add.
    We only want the Subscribe tab to appear if a visitor has registered and logged in.
  3. masterctrl1

    masterctrl1 Kayako Guru

    Additional information --
    You can enable Subscribe to News by User Group Permissions in Admin CP, but this doesn't work correctly.
    The SWIFT report about says this function is broken. If that is the case, how can it still be broken 8 months later? :(
    Example, if you have Guest (Guest), Group A (Registered), and Group B (Registered) defined, and only Group A and B are enabled for subscribing, the Subscribe tab remains invisible to logged in users.
    The only way the Subscribe tab displays at all is if Guest is enabled which is the opposite of what we want.
    If you enable this option for registered users, the form tabs should display as Account/Subscribe not Account/[Blank].
    Is there any way around this bug by editing the header template?
  4. masterctrl1

    masterctrl1 Kayako Guru

    Please move this thread to the Using or Installation topic.
  5. cxtsupport

    cxtsupport Established Member

    We were able to find a solution to this by modifying the header template.

    You need to add the sections highlighted in red. They'll be about three quarters of the way down the list.

    <{if $_userIsLoggedIn == true}>
    <div class="tabrow" id="leftloginsubscribeboxtabs">
    <a id="leftloginsubscribeboxlogintab" href="#" onclick="javascript: ActivateLoginTab();" class="atab"><span class="tableftgap">&nbsp;</span><span class="tabbulk"><span class="tabtext"><{$_language[myaccount]}></span></span></a>
    <{if $_canSubscribeNews == true}>
    <a id="leftloginsubscribeboxsubscribetab" href="#" onclick="javascript: ActivateSubscribeTab();" class="atab inactive"><span class="tableftgap">&nbsp;</span><span class="tabbulk"><span class="tabtext"><{$_language[subscribe]}></span></span></a>
    <div id="leftloginbox" class="switchingpanel active">
    <div class="maitem maprofile" onclick="javascript: Redirect('<{$_baseName}><{$_templateGroupPrefix}>/Base/UserAccount/Profile');">
    <{if ($_settings[user_orgprofileupdate] == 'allusers' && $_user[userorganizationid] != '0') || ($_user[userrole] == 2 && $_settings[user_orgprofileupdate] == 'managersonly' && $_user[userorganizationid] != '0')}>
    <div class="maitem maorganization" onclick="javascript: Redirect('<{$_baseName}><{$_templateGroupPrefix}>/Base/UserAccount/MyOrganization');">
    <{foreach key=_itemID item=_navbarMenuItem from=$_navbarMenuItemContainer}>
    <div class="maitem<{if $_navbarMenuItem[class] != ''}> <{$_navbarMenuItem[class]}><{/if}>" onclick="javascript: Redirect('<{$_navbarMenuItem[link]}>');">
    <div class="maitem mapreferences" onclick="javascript: Redirect('<{$_baseName}><{$_templateGroupPrefix}>/Base/UserAccount/Preferences');">
    <div class="maitem machangepassword" onclick="javascript: Redirect('<{$_baseName}><{$_templateGroupPrefix}>/Base/UserAccount/ChangePassword');">
    <div class="maitem malogout" onclick="javascript: Redirect('<{$_baseName}><{$_templateGroupPrefix}>/Base/User/Logout');">
    <{if $_canSubscribeNews == true}>
    <form method="post" action="<{$_baseName}><{$_templateGroupPrefix}>/News/Subscriber/Subscribe" name="SubscribeForm">
    <div id="leftsubscribebox" class="switchingpanel">
    <div class="inputframe zebraeven">
    <input class="emailstyledlabel" value="<{$_language[loginenteremail]}>" onfocus="javascript: ResetLabel(this, '<{$_language[loginenteremail]}>', 'emailstyled');" name="subscribeemail" type="text">
    <hr class="vdivider">
    <div id="logintext">&nbsp;</div>
    <div id="loginsubscribebuttons">
    <input class="rebutton" value="<{$_language[buttonsubmit]}>" type="submit">

  6. cxtsupport

    cxtsupport Established Member

    Here is a screen shot.


    Added a tool tip to inform the customer what this tab does.

  7. masterctrl1

    masterctrl1 Kayako Guru

    Forgot to ask how to add the tool tip. :) That would really help explain things to vistors.

Share This Page