xenForo - TaigaChat BOT Activity shoutbox

Discussion in 'Web Development' started by RLZ, Dec 8, 2016.

Tags:
  1. RLZ

    RLZ C Sharp Programmer

    218
    275
    348
    Credits:
    1,735
    Hello :smile:

    Following several requests I finally decided explained to you how to speak the BOT or other member during an activity on the forum, in other a thread to create or an answer is to choose.

    Here is the final rendering:
    HrX2JiQ.png
    You will then unlock the activities on the shoutbox.

    Part template:

    For taigachat Pro in higher version 1.3X go to the templates: dark_taigachat_message

    Replace your entire template with the code below:

    Code:
    <Data-userid = "{$ message.user_id}" data-messageid = "{$ message.id}">
    
    <Xen: if is = "{$ taigachat.editside} OR! {$ Taigachat.sidebar}">
      <Xen: if is = "{$ message.canModify} OR {$ taigachat.canBan} OR {$ taigachat.publichtml}">
       <Div class = "Popup" {xen: if $ taigachat.publichtml, 'style = "display: none"'}>
        <a rel="Menu"> </a>
        <Div class = "Menu">
         <Div class = "primaryContent menuHeader"> <h3> {xen: sentence dark_message_tools} </ h3> </ div>
         <Ul class = "secondaryContent blockLinksList">
          <Li> <a href="{xen:link'taigachat/edit', $message}" class="OverlayTrigger" data-cacheOverlay="false" id="taigachat_edit_{$message.id}"> {xen: phrase Edit} </a> </ li>
          <Li> <a href="{xen:link'taigachat/delete', $message}" class="taigachat_delete" data-messageid="{$message.id}"> {xen: phrase delete} </a> </ Li>
          <Xen: if is = "{$ message.user_id}> 0">
           <Li id = "taigachat_canban_ {$ message.id}" taigachat_banban "> <a data-link =" {xen: link 'taigachat / > {Xen: phrase dark_ban_from_shoutbox} </a> </ li>
          </ Xen: if>
         </ Ul>
        </ Div>
       </ Div>
      </ Xen: if>
    </ Xen: if>
    
    <Xen: if is = "{$ taigachat.miniavatar}">
      <Xen: avatar user = "$ message" size = "s" img = "true" class = "_ plainImage taigachat_avatar" />
    </ Xen: if>
    
    Absolute '|| ({$ taigachat.timedisplay} ==' AbsoluteTime '&&! {$ Message.today}) "
      Data-timestamp = "{$ message.date}" data-today = "0"> {xen: datetime $ message.date, 'absolute'} - <span class = 'DateTime muted taigachat_absolute_timestamp'
    <Xen: elseif is = "{$ taigachat.timedisplay} == 'Time' || ({$ taigachat.timedisplay} == 'AbsoluteTime' && {$ message.today}
      <Span class = 'DateTime muted taigachat_absolute_timestamp' data-timestamp = "{$ message.date}" data-today = "1"> {xen: time $ message.date,
    <Xen: elseif is = "{$ taigachat.timedisplay} == 'Relative'" />
      <Span class = 'DateTime muted'> <xen: datetime time = "$ message.date" /> - </ span>
    <Xen: else />
    </ Xen: if>
    
    <Span class = "{xen: if {$ message.me}, 'taigachat_me'} {xen: if {$ message.activity}, 'taigachat_activity'
    <Span class = "tagShoutbox" onclick = "var memberATagger = $ (this) .siblings ('a.username') text () $ ('# taigachat_message'). () .val () .val () + '=>' + memberATagger + ':');
         <A class = "OverlayTrigger username" style = "color: red;" Href = "members / bot.771 /"> <b> BOT </a> </ b>:
         <Xen: else />
         </ Xen: if>
      <a {xen:if $message.user_id,'href="{xen:link members, $ message}"'}class="username" itemprop="name"> <xen: if is = "{$ message.usernameHtml } {Xen: raw $ message.usernameHtml} <xen: else {xen: helper richUserName, $ message} </ xen: if> </a> } &&! {$ Message.activity} ">: </ xen: if>
     
      <Div class = 'taigachat_messagetext ugc'> {xen: raw $ message.messageHtml} </ div>
    
    </ Span>
    </ Li>
    For taigachat lower than 1.3X or equal copy this code into the template: dark_taigachat_list

    Code:
    <Xen: if is = "{$ taigachat.publichtml}">
        <Meta name = 'robots' content = 'noindex, nofollow, noimageindex, noarchive'>
    </ Xen: if>
    
    <Xen: foreach loop = "$ taigachat.messages" value = "$ message">
        <Data-userid = "{$ message.user_id}" data-messageid = "{$ message.id}">
    
            <Xen: if is = "{$ taigachat.editside} OR! {$ Taigachat.sidebar}">
                <Xen: if is = "{$ message.canModify} OR {$ taigachat.canBan} OR {$ taigachat.publichtml}">
                    <Div class = "Popup" {xen: if $ taigachat.publichtml, 'style = "display: none"'}>
                        <a rel="Menu"> </a>
                        <Div class = "Menu">
                            <Div class = "primaryContent menuHeader"> <h3> {xen: sentence dark_message_tools} </ h3> </ div>
                            <Ul class = "secondaryContent blockLinksList">
                                <Li> <a href="{xen:link'taigachat/edit', $message}" class="OverlayTrigger" data-cacheOverlay="false" id="taigachat_edit_{$message.id}"> {xen: phrase Edit} </a> </ li>
                                <Li> <a href="{xen:link'taigachat/delete', $message}" class="taigachat_delete" data-messageid="{$message.id}"> {xen: phrase delete} </a> </ Li>
                                <Xen: if is = "{$ message.user_id}> 0">
                                    <Li id = "taigachat_canban_ {$ message.id}" taigachat_banban "> <a data-link =" {xen: link 'taigachat / > {Xen: phrase dark_ban_from_shoutbox} </a> </ li>
                                </ Xen: if>
                            </ Ul>
                        </ Div>
                    </ Div>
                </ Xen: if>
            </ Xen: if>
    
            <Xen: if is = "{$ taigachat.miniavatar}">
                <Xen: avatar user = "$ message" size = "s" img = "true" class = "_ plainImage taigachat_avatar" />
            </ Xen: if>
          
            Absolute '|| ({$ taigachat.timedisplay} ==' AbsoluteTime '&&! {$ Message.today}) "
                Data-timestamp = "{$ message.date}" data-today = "0"> {xen: datetime $ message.date, 'absolute'} - <span class = 'DateTime muted taigachat_absolute_timestamp'
            <Xen: elseif is = "{$ taigachat.timedisplay} == 'Time' || ({$ taigachat.timedisplay} == 'AbsoluteTime' && {$ message.today}
                <Span class = 'DateTime muted taigachat_absolute_timestamp' data-timestamp = "{$ message.date}" data-today = "1"> {xen: time $ message.date,
            <Xen: elseif is = "{$ taigachat.timedisplay} == 'Relative'" />
                <Span class = 'DateTime muted'> <xen: datetime time = "$ message.date" /> - </ span>
            <Xen: else />
            </ Xen: if>
    
            <Span class = "{xen: if {$ message.me}, 'taigachat_me'} {xen: if {$ message.activity}, 'taigachat_activity'
    <Xen: if is = "{$ message.activity}">
         <A class = "OverlayTrigger username" style = "color: red;" Href = "members / bot.5 /"> <b> BOT </a> </ b>:
         <Xen: else />
         </ Xen: if>
                <a {xen:if $message.user_id,'href="{xen:link members, $ message}"'}class="username" itemprop="name"> <xen: if is = "{$ message.usernameHtml } {Xen: raw $ message.usernameHtml} <xen: else {xen: helper richUserName, $ message} </ xen: if> </a> } &&! {$ Message.activity} ">: </ xen: if>
                
                <Div class = 'taigachat_messagetext ugc'> {xen: raw $ message.messageHtml} </ div>
    
            </ Span>
        </ Li>
    </ Xen: foreach>
    
    <Div class = 'taigachat_list_online_users' style = 'display: none'>
    <Xen: if is = "{$ taigachat.online}">
        <Xen: include template = "dark_taigachat_online_users">
            <Xen: map from = "$ taigachat" to = "$ taigachat" />
        </ Xen: include>
    </ Xen: if>
    </ Div>
    I remind you that the code the shoutbox tag is integrate I have not bothered to remove it so I put the template dark_taigachat_css complete the tag.png as an attachment.

    Code:
    /* Darkimmortal's TaigaChat */
    
    #taigachat_box { height: 300px; border: 1px solid @primaryLighter; padding: 5px; margin: 5px -2px 0 -2px; overflow: auto; overflow-y: scroll; font-size: 11px; background: @primaryLightest; -webkit-text-size-adjust: none; }
    .taigachat_reverse #taigachat_box { margin-bottom: 5px; margin-top: 0; }
    #taigachat_box li { /*background: @primaryLightest;*/ margin-bottom: 6px; }
    #taigachat_controls { text-align: left; padding: 0 0 8px 0; display: table; width: 100%; }
    #taigachat_toolbar, #taigachat_toolbar > * { vertical-align: top; }
    #taigachat_message { width: 100%; box-sizing: border-box; -ms-box-sizing: border-box; }
    #taigachat_message_holder { overflow: auto; padding-right: 5px; }
    
    .taigachat_avatar img { width: 16px; height: 16px; padding: 0; vertical-align: bottom; }
    
    .taigachat_reverse #taigachat_controls { margin: 0; }
    #taigachat_send { vertical-align: top; float: right; }
    #taigachat_box .username { font-size: 11px; display: inline; }
    #taigachat_box .Popup { display: inline-block; }
    #taigachat_box.taigachat_thumbzoom .bbCodeImage { max-width: 203px; }
    .taigachat_messagetext { display: inline; word-wrap: break-word; max-width: 100%; }
    #taigachat_toolbar { margin-bottom: 5px; }
    #taigachat_sidebar #taigachat_toolbar/*, #taigachat_full.taigachat_alt #taigachat_toolbar*/ { display: none }
    .taigachat_credit { text-align: right; color: @primaryLighter; font-size: 10px; margin-top: 5px; }
    
    #taigachat_sidebar #taigachat_message { font-size: 11px; }
    #taigachat_sidebar #taigachat_send { height: 21px; }
    #taigachat_sidebar #taigachat_toolbar { padding-top: 5px; padding-bottom: 5px; }
    #taigachat_sidebar #taigachat_controls { padding: 5px 0 0; }
    #taigachat_sidebar.taigachat_reverse #taigachat_controls { margin: 0; }
    #taigachat_sidebar h3 blockquote { font-size: 11px; color: @contentText; font-weight: normal; }
    
    #taigachat_full #taigachat_box { height: 600px; margin: 0 auto 10px auto; font-size: 13px; }
    #taigachat_full #taigachat_message { width: 100%; }
    #taigachat_full #taigachat_input { display: table-cell; white-space: nowrap; padding-right: 15px; }
    #taigachat_full #taigachat_toolbar { display: table-cell; width: 5%; white-space: nowrap; }
    #taigachat_full .DateTime { font-size: 11px; }
    #taigachat_full #taigachat_box .username { font-size: 13px; }
    #taigachat_full .taigachat_messagetext { display: inline; }
    
    #taigachat_full.taigachat_alt #taigachat_box { font-size: 12px; margin: 0 auto 5px auto;  }
    #taigachat_full.taigachat_alt.taigachat_reverse #taigachat_box { margin: 10px auto; }
    #taigachat_full.taigachat_alt #taigachat_box .username { font-size: 12px; }
    #taigachat_full.taigachat_alt.taigachat_normal #taigachat_controls { margin-top: 10px; }
    
    .taigachat_motd { border: 1px solid @primaryLighterStill; padding: 2px; }
    .dark_taigachat_full .taigachat_motd { margin: 0 10px; padding: 4px; }
    #taigachat_inchat { font-style: italic; color: @dimmedTextColor }
    
    /*.taigachat_popup_body { height: 100%; }*/
    .taigachat_popup { padding: 0; height: 100%; margin: 0; position: absolute; top: 0; left: 0; bottom: 0; right: 0;  }
    .taigachat_popup > div { height: 100%; margin: -20px 0 0 0; padding: 10px 0; border-bottom: 0;  }
    .taigachat_popup #taigachat_box { height: auto !important; position: absolute; top: 40px; left: 10px; right: 10px; bottom: 10px; width: auto !important; }
    .taigachat_popup #taigachat_controls { position: absolute; left: 10px; right: 10px; top: 25px; width: 97% }
    .taigachat_popup.taigachat_reverse #taigachat_box { top: 10px; left: 10px; right: 10px; bottom: 20px; }
    .taigachat_popup.taigachat_reverse #taigachat_controls { left: 10px; right: 10px; bottom: 5px; top: auto; }
    /*.taigachat_toolbar_enabled*/ .taigachat_popup #taigachat_box { top: 60px; }
    /*.taigachat_toolbar_enabled*/ .taigachat_popup.taigachat_reverse #taigachat_box { bottom: 40px; top: 22px; }
    .taigachat_popup .taigachat_motd { margin: 10px 0 0 10px; border: none; }
    .taigachat_popup .taigachat_credit { display: none }
    .taigachat_popuphtml { min-width: 0 !important; }
    .taigachat_canban { display: none }
    
    .taigachat_smilies_list { max-width: 250px; max-height: 225px !important; }
    .taigachat_smilies_list li { display: inline; }
    .taigachat_smilie { padding: 4px 6px; color: #FF2807; display: inline-block !important; }
    .taigachat_bbcode { padding: 0; }
    .xenForoSkin .taigachat_bbcode_color { display: block; width: 20px; height: 20px; background:url(styles/dark/color_swatch.png) no-repeat center; cursor: pointer !important; }
    .taigachat_bbcode_smilie { display: block; width: 20px; height: 20px; background:url(styles/dark/smilie.png) no-repeat center; cursor: pointer !important; }
    
    .taigachat_ignored { opacity: 0.4; }
    .taigachat_me { font-style: italic; }
    .taigachat_activity { color: @primaryLightish; font-style: italic; }
    .taigachat_ignorehide { display: none !important; }
    
    /* TinyMCE XF 1.2 compatibility */
    
    .taigachat_bbcode span.mceIcon, .taigachat_bbcode img.mceIcon {display:block; width:20px; height:20px}
    .taigachat_bbcode .mceIcon {background:url(styles/dark/icons.png) no-repeat 20px 20px}
    .taigachat_bbcode span.mce_bold {background-position:0 0}
    .taigachat_bbcode span.mce_italic {background-position:-60px 0}
    .taigachat_bbcode span.mce_underline {background-position:-140px 0}
    .taigachat_bbcode span.mce_strikethrough {background-position:-120px 0}
    .taigachat_bbcode span.mce_link {background-position:-500px 0}
    .taigachat_bbcode span.mce_image {background-position:-380px 0}
    
    #taigachat_smilies_box { margin: 9px; overflow: hidden; display: none; *zoom: 1; }
    .taigachat_popup #taigachat_smilies_box { top: 200px; position: absolute; z-index: 10000; padding: 5px; background: @contentBackground; border: 1px solid @primaryLightish; }
    .taigachat_popup.taigachat_reverse #taigachat_smilies_box { top: 0px; }
    #taigachat_smilies_box .tabs { min-height: 0; }
    #taigachat_smilies_box .smilieContainer { max-height: 150px; overflow: auto; }
    #taigachat_smilies_box .primaryContent, #taigachat_smilies_box .secondaryContent { border-bottom: none; }
    #taigachat_smilies_box .tabs a { height: 18px; line-height: 18px; font-size: 11px; }
    #taigachat_smilies_box .smilieCategory li { display: inline-block; margin: 0; padding: 2px; cursor: pointer; line-height: 1.6; }
     
    
    @media (max-width:@maxResponsiveNarrowWidth)
    {
        #taigachat_controls { display: block; !important; }
        #taigachat_toolbar { padding-top: 5px; padding-bottom: 5px; }
        #taigachat_input { display: block !important; }
        .taigachat_popup.taigachat_reverse #taigachat_box { bottom: 70px !important; }
        .taigachat_popup:not(.taigachat_reverse) #taigachat_box { top: 85px !important; }
    }
    .tagShoutbox {
    background: url("VOTRE LIEN DE VOTRE TAG") no-repeat left center transparent;
    height: 14px;
    width: 0px;
    padding-left: 18px;
    opacity:0.5;
    display: inline-block;
    }
    .tagShoutbox:hover {
    cursor: pointer;
    opacity: 1;
    transition:all 0.52s;
    display:inline-block;
    -webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);-o-transform:rotate(360deg);-ms-transform:rotate(360deg);-webkit-transform: rotate(360deg); -moz-transform: rotate(360deg); -o-transform: rotate(360deg); -ms-transform: rotate(360deg);transform:rotate(720deg);-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);-ms-transform:rotate(360deg);-o-transform:rotate(360deg);
    }
     
    iHax_dani likes this.
  2. Tusta

    Tusta Head Member Donator

    20
    10
    14
    Credits:
    3,249
    nice Post :smile:
     
    iHax_dani likes this.
  3. RLZ

    RLZ C Sharp Programmer

    218
    275
    348
    Credits:
    1,735
    Thanks Mr.VerTical!
     
    iHax_dani and Tusta like this.
  4. Tusta

    Tusta Head Member Donator

    20
    10
    14
    Credits:
    3,249
    np :smile:
     

Share This Page