Problème avec la mention taguer dans les sujets.

Voir le sujet précédent Voir le sujet suivant Aller en bas

Résolu Problème avec la mention taguer dans les sujets.

Message par .bloodstream Dim 19 Jan 2020 - 2:46

Détails techniques

Version du forum : phpBB2
Poste occupé : Fondateur
Navigateur(s) concerné(s) : Mozilla Firefox
Capture d'écran du problème :
Voir l'image:

Personnes concernées par le problème : Tous les utilisateurs
Problème apparu depuis : 18 janvier
Lien du forum : http://forumtest-wits.forumactif.com/

Description du problème

Bonjour I love you

J'ai un petit problème de code suite à un tuto que j'utilise pour la mention tag dans les messages. J'ai utilisé ce tuto la partie 0.3 Bouton mentionner dans les options de message.

01. Je voulais mettre les images centré, mais l'image pour ma mention ne se centre pas, j'ai mis une capture d'écran pour voir le problème et j'avoue ne pas y connaitre grand chose en javascript. :O:

02. Je me retrouve aussi avec un deuxième problème, celui du tag. Quand je clique il devrait s'afficher @"nomdumembre" alors que le résultat avec mon code donne ceci :  @"" scratch

Template viewtopic_body
Code:
   
    <script type="text/javascript">
    //<![CDATA[
    var multiquote_img_off = '{JS_MULTIQUOTE_IMG_OFF}', multiquote_img_on = '{JS_MULTIQUOTE_IMG_ON}', _atr = '{JS_DIR}addthis/', _ati = '{PATH_IMG_FA}addthis/'{ADDTHIS_LANG}, addthis_localize = { share_caption: "{L_SHARE_CAPTION}", email: "{L_EMAIL}", email_caption: "{L_EMAIL_CAPTION}", favorites: "{L_SHARE_BOOKMARKS}", print: "{L_PRINT}", more: "{L_MORE}" };
    $(function(){

        if(typeof(_atc) == "undefined") {
            _atc = { };
        }
      
        _atc.cwait = 0;
        $('.addthis_button').mouseup(function(){
            if ($('#at15s').css('display') == 'block') {
                addthis_close();
            }
        });
    });

    var hiddenMsgLabel = { visible:'{JS_HIDE_HIDDEN_MESSAGE}', hidden:'{JS_SHOW_HIDDEN_MESSAGE}' };
    showHiddenMessage = function(id)
    {
        try
        {
            var regId = parseInt(id, 10);
            if( isNaN(regId) ) { regId = 0; }
          
            if( regId > 0)
            {
                $('.post--' + id).toggle(0, function()
             {
                if( $(this).is(":visible") )
                {
                   $('#hidden-title--' + id).html(hiddenMsgLabel.visible);
                }
                else
                {
                   $('#hidden-title--' + id).html(hiddenMsgLabel.hidden);
                }
             });
            }
        }
        catch(e) { }
      
       return false;
    };

    //]]>
    </script>

    <table width="100%" border="0" cellspacing="2" cellpadding="0">
       <tr>
          <td align="left" valign="middle" nowrap="nowrap">
             <span class="nav">
             <!-- BEGIN switch_user_authpost -->
             <a href="{U_POST_NEW_TOPIC}" rel="nofollow"><img src="{POST_IMG}" id="{POST_IMG_ID}one" alt="{L_POST_NEW_TOPIC}" align="middle" border="0" /></a>  
             <!-- END switch_user_authpost -->
             <!-- BEGIN switch_user_authreply -->
             <a href="{U_POST_REPLY_TOPIC}"><img src="{REPLY_IMG}" id="i_reply" alt="{L_POST_REPLY_TOPIC}" align="middle" border="0" /></a>
             <!-- END switch_user_authreply -->
             </span>
          </td>      
          <td class="nav" valign="middle" width="100%">
             <span class="nav"><a class="nav" href="{U_INDEX}">{L_INDEX}</a>{NAV_SEP}<a class="nav" href="{U_ALBUM}">{L_ALBUM}</a>{NAV_CAT_DESC_SECOND}</span>        
          </td>      
          <td align="right" valign="bottom" nowrap="nowrap" width="100%">
             <!-- BEGIN switch_twitter_btn -->
             <span id="twitter_btn" style="margin-left: 6px; ">
             <a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal">Tweet</a>
             <script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
             </span>
             <!-- END switch_twitter_btn -->
             <!-- BEGIN switch_fb_likebtn -->
             <span id="fb_likebtn" style="margin-left: 6px; ">
                <iframe src="https://www.facebook.com/plugins/like.php?href={FORUM_URL}{TOPIC_URL}&layout=button_count&show_faces=false&width=100&action=like&colorscheme=light&height=21" scrolling="no" frameborder="0" style="position:relative; top:1px; border:none; overflow:hidden; width:110px; height:21px;" allowTransparency="true"></iframe>
             </span>
             <!-- END switch_fb_likebtn -->
             <span class="gensmall bold">
                <a class="addthis_button" href="http://www.addthis.com/bookmark.php?v=250&pub=forumotion">{L_SHARE}</a>
                <!-- BEGIN switch_plus_menu -->
                 |&nbsp;.
                <script type="text/javascript">//<![CDATA[
                   var url_favourite = '{U_FAVOURITE_JS_PLUS_MENU}';
                   var url_newposts = '{U_NEWPOSTS_JS_PLUS_MENU}';
                   var url_egosearch = '{U_EGOSEARCH_JS_PLUS_MENU}';
                   var url_unanswered = '{U_UNANSWERED_JS_PLUS_MENU}';
                   var url_watchsearch = '{U_WATCHSEARCH_JS_PLUS_MENU}';
                   var url_tellfriend = '{U_TELLFRIEND_JS_PLUS_MENU}';
                   insert_plus_menu('f{FORUM_ID}&t={TOPIC_ID}','{JS_SESSION_ID}', {JS_AUTH_FAVOURITES});
                //]]>
                </script>
                <!-- END switch_plus_menu -->
             </span>
          </td>
       </tr>
    </table>

    <table class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0">
      <tr align="right">
          <td class="catHead" colspan="3" height="28">
            <link href='http://fonts.googleapis.com/css?family=Shadows Into Light Two' rel='stylesheet' type='text/css'>
              <link href="https://fonts.googleapis.com/css?family=Qwigley&display=swap" rel="stylesheet">
            <link href="https://fonts.googleapis.com/css?family=Old Standard TT" rel="stylesheet">
                <link href='http://fonts.googleapis.com/css?family=Lobster' rel='stylesheet' type='text/css'>
                <link href='http://fonts.googleapis.com/css?family=Special Elite' rel='stylesheet' type='text/css'>
            <table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                <td width="9%" class="noprint"> </td>
                  <td align="center" nowrap="nowrap" class="t-title"><h1 class="cattitle"><titreprof>{TOPIC_TITLE}</titreprof></h1></td>
                  <td align="right" nowrap="nowrap" width="9%" class="browse-arrows"><a href="{U_VIEW_OLDER_TOPIC}">{L_VIEW_PREVIOUS_TOPIC}</a> <a href="{U_VIEW_NEWER_TOPIC}">{L_VIEW_NEXT_TOPIC}</a> <a href="#bottom">{L_GOTO_DOWN}</a> </td>
                </tr>
            </table>
          </td>
      </tr>
      <!-- BEGIN topicpagination -->
      <tr>
          <td class="row1 pagination" colspan="2" align="right" valign="top"><span class="gensmall">{PAGINATION}</span></td>
      </tr>
      <!-- END topicpagination -->
      {POLL_DISPLAY}
      <!-- BEGIN postrow -->
      <!-- BEGIN displayed -->
      <tr class="post">
        <td class="{postrow.displayed.ROW_CLASS}"{postrow.displayed.THANK_BGCOLOR} valign="top" width="240"><div class="profilentour"><div class="profilentourfond"><center><a name="{postrow.displayed.U_POST_ID}"></a><span class="icon_online">{postrow.displayed.ONLINE_IMG}</span><div class="blackwhite"><span class="postdetails poster-profile">{postrow.displayed.POSTER_AVATAR}</span></div><link href='http://fonts.googleapis.com/css?family=Stalemate' rel='stylesheet' type='text/css'><div class="textpseudo">{postrow.displayed.POSTER_NAME}</div><div class="separatorprofil"></div><br><div class="fondprof"><div class="intrpg"><center><wny>welcome to philly.</wny><div class="lignetitrewny"></div><div class="rang">{postrow.displayed.POSTER_RANK}</div></center><br><br> <!-- BEGIN profile_field --><div style="padding-left:3px;padding-right:3px;"><labeltitre>{postrow.displayed.profile_field.LABEL}</labeltitre> {postrow.displayed.profile_field.CONTENT} {postrow.displayed.profile_field.SEPARATOR}</div>
              <!-- END profile_field -->  {postrow.displayed.POSTER_RPG}</div></div>
          <div class="profilmp">{postrow.displayed.PROFILE_IMG}  {postrow.displayed.PM_IMG}</div></div></div>
              </td>
            <td class="{postrow.displayed.ROW_CLASS}"{postrow.displayed.THANK_BGCOLOR} valign="top" width="100%" height="18" colspan="2">
          <table align="center" width="97%" border="0" cellspacing="0" cellpadding="0">
            <tr><td align="center" class="enteteprof"><span class="postdetails"><img src="{postrow.displayed.MINI_POST_IMG}" alt="{postrow.displayed.L_MINI_POST_ALT}" title="{postrow.displayed.L_MINI_POST_ALT}" border="0" />{L_POST_SUBJECT}: {postrow.displayed.POST_SUBJECT}<br><img src="{postrow.displayed.MINI_TIME_IMG}" alt="" border="0" />{postrow.displayed.POST_DATE}</span></td></tr>
              <tr><td align="center" class="post-options" valign="top" nowrap="nowrap"><center>{postrow.displayed.THANK_IMG} {postrow.displayed.MULTIQUOTE_IMG} {postrow.displayed.QUOTE_IMG} {postrow.displayed.EDIT_IMG} {postrow.displayed.DELETE_IMG} {postrow.displayed.IP_IMG} {postrow.displayed.REPORT_IMG}</center></td><br>
                </tr>
                <tr>
                
                </tr>
                <tr>
                  <td colspan="2">
                      <!-- BEGIN switch_vote_active -->
                      <div class="vote gensmall">
                        <!-- BEGIN switch_vote -->
                        <div class="vote-button"><a href="{postrow.displayed.switch_vote_active.switch_vote.U_VOTE_PLUS}">+</a></div>
                        <!-- END switch_vote -->

                        <!-- BEGIN switch_bar -->
                        <div class="vote-bar" title="{postrow.displayed.switch_vote_active.L_VOTE_TITLE}">
                            <!-- BEGIN switch_vote_plus -->
                            <div class="vote-bar-plus" style="height:{postrow.displayed.switch_vote_active.switch_bar.switch_vote_plus.HEIGHT_PLUS}px;"></div>
                            <!-- END switch_vote_plus -->

                            <!-- BEGIN switch_vote_minus -->
                            <div class="vote-bar-minus" style="height:{postrow.displayed.switch_vote_active.switch_bar.switch_vote_minus.HEIGHT_MINUS}px;"></div>
                            <!-- END switch_vote_minus -->
                        </div>
                        <!-- END switch_bar -->

                        <!-- BEGIN switch_no_bar -->
                        <div title="{postrow.displayed.switch_vote_active.L_VOTE_TITLE}" class="vote-no-bar">----</div>
                        <!-- END switch_no_bar -->

                        <!-- BEGIN switch_vote -->
                        <div class="vote-button"><a href="{postrow.displayed.switch_vote_active.switch_vote.U_VOTE_MINUS}">-</a></div>
                        <!-- END switch_vote -->
                      </div>
                      <!-- END switch_vote_active -->

                    <div class="postbody">

                        {postrow.displayed.MESSAGE}

                        <div class="signature_div">
                            {postrow.displayed.SIGNATURE}
                        </div>
                      </div>
                      <span class="gensmall">{postrow.displayed.EDITED_MESSAGE}</span>
                  </td>
                </tr>
            </table>
          </td>
      </tr>
      <tr>
          <td class="{postrow.displayed.ROW_CLASS} browse-arrows"{postrow.displayed.THANK_BGCOLOR} align="center" valign="middle" width="150">
            <a href="#top">{L_BACK_TO_TOP}</a> <a href="#bottom">{L_GOTO_DOWN}</a>
          </td>
          <td class="{postrow.displayed.ROW_CLASS} messaging gensmall"{postrow.displayed.THANK_BGCOLOR} width="100%" height="28">
            <table border="0" cellspacing="0" cellpadding="0">
                <tr>
                
                </tr>
            </table>
          </td>
      </tr>
      <!-- BEGIN first_post_br -->
    </table>
    <br />
    <table class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0">
      <tr>
          <th class="thLeft" nowrap="nowrap" width="150px" height="26">{L_AUTHOR}</th>
          <th class="thRight" nowrap="nowrap" colspan="2">{L_MESSAGE}</th>
      </tr>
      <!-- END first_post_br -->
      <!-- END displayed -->
      <!-- BEGIN hidden -->
      <tr>
          <td class="postdetails {postrow.hidden.ROW_CLASS}" colspan="2" align="center">{postrow.hidden.MESSAGE}</td>
      </tr>
      <!-- END hidden -->
      <!-- END postrow -->
      <!-- BEGIN no_post -->
      <tr align="center">
          <td class="row1" colspan="3" height="28">
            <span class="genmed">{no_post.L_NO_POST}</span>
          </td>
      </tr>
      <!-- END no_post -->
      <tr align="right">
          <td class="catBottom" colspan="3" height="28">
            <table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                  <td width="9%" class="noprint"> </td>
                  <td align="center" nowrap="nowrap" class="t-title"><a name="bottomtitle"></a><h1 class="cattitle"><titreprof>{TOPIC_TITLE}</titreprof></h1></td>
                  <td align="right" nowrap="nowrap" width="9%" class="browse-arrows"><a href="{U_VIEW_OLDER_TOPIC}">{L_VIEW_PREVIOUS_TOPIC}</a> <a href="{U_VIEW_NEWER_TOPIC}">{L_VIEW_NEXT_TOPIC}</a> <a href="#top">{L_BACK_TO_TOP}</a> </td>
                </tr>
            </table>
          </td>
      </tr>
    </table>

    <table class="forumline noprint" width="100%" border="0" cellspacing="1" cellpadding="0">
      <tr>
          <td class="row2" valign="top" {COLSPAN_PAGINATION} width="150"><span class="gensmall">{PAGE_NUMBER}</span></td>
          <!-- BEGIN topicpagination -->
          <td class="row1" align="right" valign="top" ><span class="gensmall">{PAGINATION}</span></td>
          <!-- END topicpagination -->
      </tr>
      <!-- BEGIN switch_user_logged_in -->
      <!-- BEGIN watchtopic -->
      <tr>
          <td class="row2" colspan="2" align="right" valign="top"><span class="gensmall">{S_WATCH_TOPIC}</span></td>
      </tr>
      <!-- END watchtopic -->
      <!-- END switch_user_logged_in -->
      <tr>
          <td class="row2" colspan="2" align="center" style="padding:0px">
            <!-- BEGIN switch_user_logged_in -->
            <a name="quickreply"></a>
            {QUICK_REPLY_FORM}<br />
            <!-- END switch_user_logged_in -->
          </td>
      </tr>
      <tr>
          <td style="margin:0; padding: 0;" colspan="2">
            <table border="0" cellpadding="0" width="100%" cellspacing="0" id="info_open" style="display:''">
                <tbody>
          <!-- BEGIN show_permissions -->
          <tr>
            <td class="row2" valign="top" width="25%"><span class="gensmall">{L_TABS_PERMISSIONS}</span></td>
            <td class="row1" valign="top" width="75%"><span class="gensmall">{S_AUTH_LIST}</span></td>
          </tr>
          <!-- END show_permissions -->
          <tr>
            <td class="catBottom" colspan="2" height="28">
                <table width="100%" border="0" cellspacing="0" cellpadding="0">
                  <tr>
                      <td valign="middle" width="100%"><span class="nav"><a class="nav" href="{U_INDEX}">{L_INDEX}</a>{NAV_SEP}<a class="nav" href="{U_ALBUM}">{L_ALBUM}</a>{NAV_CAT_DESC_SECOND}</span></td>
                      <!-- BEGIN show_permissions -->
                      <td align="right" valign="middle"><span class="gensmall"><a href="javascript:ShowHideLayer('info_open','info_close');"><img src="{TABS_LESS_IMG}" alt="-" align="middle" border="0" /></a></span></td>
                      <!-- END show_permissions -->
                  </tr>
                </table>
            </td>
          </tr>
      </tbody>
            </table>
          </td>
      </tr>
      <tr>
          <td style="margin:0; padding: 0;" colspan="2">
            <table border="0" cellpadding="0" cellspacing="0" width="100%" id="info_close" style="display:none;">
                <tbody>
          <tr>
            <td class="catBottom" colspan="2" height="28">
                <table width="100%" border="0" cellspacing="0" cellpadding="0">
                  <tr>
                      <td valign="middle" width="100%"><span class="nav"><a class="nav" href="{U_INDEX}">{L_INDEX}</a>{NAV_SEP}<a class="nav" href="{U_ALBUM}">{L_ALBUM}</a>{NAV_CAT_DESC_SECOND}</span></td>
                      <td align="right" valign="middle"><span class="gensmall"><a href="javascript:ShowHideLayer('info_open','info_close');"><img src="{TABS_MORE_IMG}" alt="+" align="middle" border="0" /></a></span></td>
                  </tr>
                </table>
            </td>
          </tr>
      </tbody>
            </table>
          </td>
      </tr>
    </table>

    <form action="{S_JUMPBOX_ACTION}" method="get" name="jumpbox" onsubmit="if(document.jumpbox.f.value == -1){return false;}">
    <table class="noprint" width="100%" border="0" cellspacing="2" cellpadding="0" align="center">
      <tr>
          <td align="left" valign="middle" nowrap="nowrap" {WIDTH_GALLERY}>
            <span class="nav">
                <!-- BEGIN switch_user_authpost -->
                <a href="{U_POST_NEW_TOPIC}" rel="nofollow"><img src="{POST_IMG}" id="{POST_IMG_ID}Newtopic" alt="{L_POST_NEW_TOPIC}" align="middle" border="0" /></a>
                <!-- END switch_user_authpost -->
                <!-- BEGIN switch_user_authreply -->
                <a href="{U_POST_REPLY_TOPIC}"><img src="{REPLY_IMG}" alt="{L_POST_REPLY_TOPIC}" align="middle" border="0" /></a>
                <!-- END switch_user_authreply -->
            </span>
          </td>
          <!-- BEGIN viewtopic_bottom -->
          <td align="right" nowrap="nowrap"><span class="gensmall">{L_JUMP_TO}: {S_JUMPBOX_SELECT} <input class="liteoption" type="submit" value="{L_GO}" /></span></td>
          <!-- END viewtopic_bottom -->
          <!-- BEGIN moderation_panel -->
          <td align="center">
            <span class="gensmall">{moderation_panel.U_YOUR_PERSONAL_MODERATE}</span>
          </td>
          <td align="center" width="250">
            <span class="gensmall"> </span>
          </td>
          <!-- END moderation_panel -->
      </tr>
    </table>
    </form>

    <!-- BEGIN viewtopic_bottom -->
    <table class="noprint" width="100%" border="0" cellspacing="2" cellpadding="0" align="center">
      <tr>
          <td colspan="2" align="left" valign="top" nowrap="nowrap"><br />{S_TOPIC_ADMIN}<br />
            <form name="action" method="get" action="{S_FORM_MOD_ACTION}">
                <input type="hidden" name="t" value="{TOPIC_ID}" />
                <input type="hidden" name="sid" value="{S_SID}" />
                <span class="gen">{L_MOD_TOOLS}<br />{S_SELECT_MOD} <input class="liteoption" type="submit" value="{L_GO}" /></span>
            </form>
          </td>
      </tr>
    </table>
    <!-- END viewtopic_bottom -->

    <!-- BEGIN switch_image_resize -->
    <script type="text/javascript">
    //<![CDATA[
    $(resize_images({ 'selector' : '.postbody', 'max_width' : {switch_image_resize.IMG_RESIZE_WIDTH}, 'max_height' : {switch_image_resize.IMG_RESIZE_HEIGHT} }));
    //]]>
    </script>
    <!-- END switch_image_resize -->

    <script type="text/javascript" src="{JS_DIR}addthis/addthis_widget.js?pub=forumotion"></script>


CSS
Code:
   
    td.cat,td.catHead,td.catSides,td.catLeft,td.catRight, td.catBottom, .thHead,.catLeft {
      background-image: url("https://2img.net/i/fa/empty.gif");
      background-color: #BDB0B0;
        border:#BDB0B0;
        border-style: solid;
        height: 25px;
      }


    titreprof{
      color:white;
      text-shadow: 0px 0px 1px;
      font-size:17px;
      letter-spacing:-1px;
      text-transform: uppercase;
      font-family:Shadows Into Light Two, Cursive;
      font-weight:normal;
      position:relative;top:0px;
      }

    .enteteprof{
    padding:7px;
      background-color:#E6E6E8;
        border-bottom:2px solid #7a728b;
      border-top:2px solid #7a728b;
      border-radius:10px;
      position:relative;top:-10px;
      font-family:Courier New;
      text-transform:uppercase;
      font-size:17px;
    }

.post-options{
  background-color:#CCCCCE;
  border-top:1px dashed #7a728b;
  border-bottom:2px solid #7a728b;
  position:relative;top:-15px;
  margin-left:auto !important;
  margin-right:auto!important;
  }

javascript
Code:
   
    /* FORUM VERSIONS
     * 0 = PHPBB2
     * 1 = PHPBB3
     * 2 = PUNBB
     * 3 = INVISION
     * 4 = MODERNBB
     */
    $(function() {
      var version = 0,
          image = 'https://i.servimg.com/u/f13/20/12/55/73/taguer10.png';
    
      if (/mode=reply/.test(window.location.search) && my_getcookie('fa_mention')) {
        document.post.message.value += '@"' + my_getcookie('fa_mention') + '" ';
        my_setcookie('fa_mention','');
      } if (!/\/t\d+/.test(window.location.pathname)) return;
    
      for (var a = $(['.post-options', '.profile-icons', '.post-options', '.posting-icons', '.profile-icons'][version]), b, c, d = ['.name strong a', '.author a', '.username a', '.author a', '.postprofile-name a'][version], e, i = 0, j = a.length, t = document.getElementById('text_editor_textarea'), l = version == 1 || version == 3 || version == 4; i<j; i++) {
        b = document.createElement('IMG');
        b.src = image;
        b.alt = 'Mentionner';
        b.title = 'Mentionner ' + $(a[i]).closest('.post').find(d + ':not(.fa-mention)').text();
        b.className = 'i_icon_mention';
        b.onclick = function() {
          var n = this.title.replace(/^.*?\s/,'');
        
          if ($.sceditor) t.insertText('@"' + n + '" ');
          else {
            my_setcookie('fa_mention', n);
            window.location.href = '/post?t=' + window.location.pathname.replace(/\/t(\d+)-.*/,'$1') + '&mode=reply';
          }
        };
    
        if (l) {
          c = document.createElement('LI');
          c.appendChild(b);
        }
      
        a[i].insertBefore(l ? c : b, a[i].firstChild);
      }
    
      $(function(){
        if (!$.sceditor) return;
        t=$(t).sceditor('instance');
      });
    });

Merci d'avance I love you
.bloodstream

.bloodstream
*

Messages : 33
Inscrit(e) le : 24/10/2019

http://forumtest-wits.forumactif.com/
.bloodstream a été remercié(e) par l'auteur de ce sujet.

Résolu Re: Problème avec la mention taguer dans les sujets.

Message par Invité Dim 19 Jan 2020 - 5:59

Hello .bloodstream,

alors vu que ton template a été légèrement beaucoup modifié Very Happy  ,
il est logique rien ne fonctionne car le script ne trouve pas le membre...
Bref, on va remédier au placement des boutons car la balise center que tu as déposé
centre automatiquement tout ce qui arrive dedans, ce qui est logique non ?
Bref, dans ton template, recherches ceci:

Code:
<div class="textpseudo">{postrow.displayed.POSTER_NAME}</div>

Supprimes et remplaces par:
Code:
<div class="textpseudo name">{postrow.displayed.POSTER_NAME}</div>

Puis cette ligne:
Code:

<center>{postrow.displayed.THANK_IMG} {postrow.displayed.MULTIQUOTE_IMG} {postrow.displayed.QUOTE_IMG} {postrow.displayed.EDIT_IMG} {postrow.displayed.DELETE_IMG} {postrow.displayed.IP_IMG} {postrow.displayed.REPORT_IMG}
</center>

Supprimes et remplaces par:
Code:

{postrow.displayed.THANK_IMG} {postrow.displayed.MULTIQUOTE_IMG} {postrow.displayed.QUOTE_IMG} {postrow.displayed.EDIT_IMG} {postrow.displayed.DELETE_IMG} {postrow.displayed.IP_IMG} {postrow.displayed.REPORT_IMG}


On déposera un style dans la feuille de style afin de forcer l’alignement au centre.

Au passage et afin de corriger les sauts de lignes, les balises s'écrivent ainsi:
Code:
<br />

Penses a enregistrer puis à valider en cliquant respectivement sur Problème avec la mention taguer dans les sujets. Imgrr10

Dans la feuille de style:
Affichage/Images et Couleurs/Couleurs/Feuille de style

Ajoutes ceci:

Code:

.post .post-options{text-align:center!important;}

Penses à cliquer sur le bouton Problème avec la mention taguer dans les sujets. Sans_t10


Puis le script à modifier:
Code:
/* FORUM VERSIONS
 * 0 = PHPBB2
 * 1 = PHPBB3
 * 2 = PUNBB
 * 3 = INVISION
 * 4 = MODERNBB
 */
$(function() {
  var version = 0,
      image = 'https://i.servimg.com/u/f19/18/21/60/73/mentio10.png';
  
  if (/mode=reply/.test(window.location.search) && my_getcookie('fa_mention')) {
    document.post.message.value += '@"' + my_getcookie('fa_mention') + '" ';
    my_setcookie('fa_mention','');  
  } if (!/\/t\d+/.test(window.location.pathname)) return;
  
  for (var a = $(['.post-options', '.profile-icons', '.post-options', '.posting-icons', '.profile-icons'][version]), b, c, d = ['.name a', '.author a', '.username a', '.author a', '.postprofile-name a'][version], e, i = 0, j = a.length, t = document.getElementById('text_editor_textarea'), l = version == 1 || version == 3 || version == 4; i<j; i++) {
    b = document.createElement('IMG');
    b.src = image;
    b.alt = 'Mentionner';
    b.title = 'Mentionner ' + $(a[i]).closest('.post').find(d + ':not(.fa-mention)').text();
    b.className = 'i_icon_mention';
    b.onclick = function() {
      var n = this.title.replace(/^.*?\s/,'');
      
      if ($.sceditor) t.insertText('@"' + n + '" ');
      else {
        my_setcookie('fa_mention', n);
        window.location.href = '/post?t=' + window.location.pathname.replace(/\/t(\d+)-.*/,'$1') + '&mode=reply';
      }
    };
 
    if (l) {
      c = document.createElement('LI');
      c.appendChild(b);
    }
    
    a[i].insertBefore(l ? c : b, a[i].firstChild);
  }
  
  $(function(){
    if (!$.sceditor) return;
    t=$(t).sceditor('instance');
  });
});

Et voilou Very Happy .

a++
Anonymous

Invité
Invité


Invité a été remercié(e) par l'auteur de ce sujet.
  • 0

Résolu Re: Problème avec la mention taguer dans les sujets.

Message par .bloodstream Dim 19 Jan 2020 - 16:35

Oh super ça fonctionne, parfaitement. tongue  I love you
Merci beaucoup pour ton aide Milouze14. I love you
.bloodstream

.bloodstream
*

Messages : 33
Inscrit(e) le : 24/10/2019

http://forumtest-wits.forumactif.com/
.bloodstream a été remercié(e) par l'auteur de ce sujet.

Voir le sujet précédent Voir le sujet suivant Revenir en haut

- Sujets similaires

Permission de ce forum:
Vous ne pouvez pas répondre aux sujets dans ce forum