Problème de script d'alertes pour AwesomeBB?
Forum gratuit : Le forum des forums actifs :: Entraide & Support... :: Problème avec un script, un code :: Archives des problèmes avec un code
Page 1 sur 1 • Partagez
Problème de script d'alertes pour AwesomeBB?
Détails techniques
Version du forum : AwesomeBB
Poste occupé : Fondateur
Navigateur(s) concerné(s) : Google Chrome
Personnes concernées par le problème : Tous les utilisateurs
Lien du forum :
Description du problème
HelloJe reviens de nouveau vers vous afin de vous faire part d'un nouveau problème: je cherche à installer ce tutoriel sur mon forum (AwesomeBB):
https://forum.forumactif.com/t377672-systeme-d-alerte-en-temps-reel#3185771
Mais le tutoriel ne semble pas fonctionner – y-a-t-il une ligne de code manquante pour rendre le script compatible avec AwesomeBB?
Merci d'avance pour votre aide
Feu Ardent- ***
-
Messages : 156
Inscrit(e) le : 29/08/2010
Re: Problème de script d'alertes pour AwesomeBB?
Hello Feu Ardent,
cette version diffère un peu des autres car cette partie du script:
N'existe pas sur cette version, il faudrait remplacer par:
Cela fonctionne en insérant mais il y a une légère latence....
En tenant compte des ajouts concernant la version awesomeBB:
Je vais te donner deux scripts dont le premier n'a pas besoin d'intervention dans le template et l'autre qui pour moi est plus adapté car on recherche dans la page html le lien de déconnexion, mais impose un ajout dans le template overall_header afin de déposer la variable qui gère les liens de la barre de navigation dont la déconnexion.
Le premier sans intervention dans le template:
Remplaces l'id du topic 410 par celui concerné sur ton fofo:
L'autre script avec intervention dans le template overall_header:
Affichage/Templates/Général/ overall_header
Recherches ceci:
Juste après déposes ceci:
Penses a enregistrer puis à valider en cliquant respectivement sur puis
Puis le script:
Dans la feuille de style, trouves ceci:
remplaces par:
J'ai juste ajouté un
Bon choix .
a++
cette version diffère un peu des autres car cette partie du script:
- Code:
if($("#logout").length)
N'existe pas sur cette version, il faudrait remplacer par:
- Code:
$(function(){$(function(){
if($('a[href^="/login?logout"]').length) {
realTime_alert();
setInterval('realTime_alert();', 30000); // Reactualisation toutes les 30s
}
})});
Cela fonctionne en insérant mais il y a une légère latence....
En tenant compte des ajouts concernant la version awesomeBB:
- Code:
if (version=="awesomeBB") {
var alertBody= html.find("div.post-wrap .post-content .codebox code").eq(-1).text();
var id = html.find("div.post-header").eq(-1).attr("id");
}
Je vais te donner deux scripts dont le premier n'a pas besoin d'intervention dans le template et l'autre qui pour moi est plus adapté car on recherche dans la page html le lien de déconnexion, mais impose un ajout dans le template overall_header afin de déposer la variable qui gère les liens de la barre de navigation dont la déconnexion.
Le premier sans intervention dans le template:
- Code:
function realTime_alert() {
var version="awesomeBB";
var topicAlertId="410";
jQuery.ajax({
url: "/t"+topicAlertId+"-?view=newest",
success: function(result) {
var html = jQuery(result);
if (version=="phpbb3") {
var alertBody= html.find("div.post .content .codebox code").eq(-1).text();
var id = html.find("div.post").eq(-1).attr("id");
}
if (version=="phpbb2") {
var alertBody= html.find("tr.post .postbody .codebox .cont_code").eq(-1).text();
var id = html.find("tr.post").eq(-1).attr("id");
}
if (version=="punbb") {
var alertBody= html.find("div.post .postbody .entry-content .codebox .cont_code code").eq(-1).text();
var id = html.find("div.post .postmain .posthead").eq(-1).attr("id");
}
if (version=="invision") {
var alertBody= html.find("div.post .post-entry .codebox.contcode dd code").eq(-1).text();
var id = html.find("div.post").eq(-1).attr("id");
}
if (version=="awesomeBB") {
var alertBody= html.find("div.post-wrap .post-content .codebox code").eq(-1).text();
var id = html.find("div.post-header").eq(-1).attr("id");
}
if(localStorage.getItem(id)!='read' && sessionStorage.getItem(id)!=location.pathname) {
$('body').append(alertBody);
$('.realTime_alert .close').click(function() {
$(this).closest('.realTime_alert').fadeOut();
localStorage.setItem(id,"read");
});
}
if(sessionStorage.getItem(id)!=location.pathname) {
sessionStorage.setItem(id, location.pathname);
} else {
sessionStorage.setItem(id, location.pathname);
}
},
});
return topicAlertId;
}
$(function(){$(function(){
if($('a[href^="/login?logout"]').length) {
realTime_alert();
setInterval('realTime_alert();', 30000); // Reactualisation toutes les 30s
}
})});
Remplaces l'id du topic 410 par celui concerné sur ton fofo:
- Code:
var topicAlertId="410";
L'autre script avec intervention dans le template overall_header:
Affichage/Templates/Général/ overall_header
Recherches ceci:
- Code:
<div class="wrap">
Juste après déposes ceci:
- Code:
<!-- BEGIN switch_user_logged_in -->
<div id="M14_nav_bar"style="display:none;">{GENERATED_NAV_BAR}</div>
<!-- END switch_user_logged_in -->
Penses a enregistrer puis à valider en cliquant respectivement sur puis
Puis le script:
- Code:
function realTime_alert() {
var version="awesomeBB";
var topicAlertId="410";
jQuery.ajax({
url: "/t"+topicAlertId+"-?view=newest",
success: function(result) {
var html = jQuery(result);
if (version=="phpbb3") {
var alertBody= html.find("div.post .content .codebox code").eq(-1).text();
var id = html.find("div.post").eq(-1).attr("id");
}
if (version=="phpbb2") {
var alertBody= html.find("tr.post .postbody .codebox .cont_code").eq(-1).text();
var id = html.find("tr.post").eq(-1).attr("id");
}
if (version=="punbb") {
var alertBody= html.find("div.post .postbody .entry-content .codebox .cont_code code").eq(-1).text();
var id = html.find("div.post .postmain .posthead").eq(-1).attr("id");
}
if (version=="invision") {
var alertBody= html.find("div.post .post-entry .codebox.contcode dd code").eq(-1).text();
var id = html.find("div.post").eq(-1).attr("id");
}
if (version=="awesomeBB") {
var alertBody= html.find("div.post-wrap .post-content .codebox code").eq(-1).text();
var id = html.find("div.post-header").eq(-1).attr("id");
}
if(localStorage.getItem(id)!='read' && sessionStorage.getItem(id)!=location.pathname) {
$('body').append(alertBody);
$('.realTime_alert .close').click(function() {
$(this).closest('.realTime_alert').fadeOut();
localStorage.setItem(id,"read");
});
}
if(sessionStorage.getItem(id)!=location.pathname) {
sessionStorage.setItem(id, location.pathname);
} else {
sessionStorage.setItem(id, location.pathname);
}
},
});
return topicAlertId;
}
$(function(){
if($("#logout").length) {
realTime_alert();
setInterval('realTime_alert();', 30000); // Reactualisation toutes les 30s
}
});
Dans la feuille de style, trouves ceci:
- Code:
.realTime_alert{
background:#FDFDFD no-repeat 10px center;
-webkit-background-size:50px;
-moz-background-size:50px;
-o-background-size:50px;
background-size:50px;
-webkit-box-shadow:0 0 4px rgba(0,0,0,.6);
-moz-box-shadow:0 0 4px rgba(0,0,0,.6);
box-shadow:0 0 4px rgba(0,0,0,.6);
position:fixed;
top:50px;
right:20px;
min-height:60px;
font-size:13px;
width:200px;
padding:10px 10px 10px 70px;
font-family:Helvetica;
color:#474747;
}
remplaces par:
- Code:
.realTime_alert{
background:#FDFDFD no-repeat 10px center;
-webkit-background-size:50px;
-moz-background-size:50px;
-o-background-size:50px;
background-size:50px;
-webkit-box-shadow:0 0 4px rgba(0,0,0,.6);
-moz-box-shadow:0 0 4px rgba(0,0,0,.6);
box-shadow:0 0 4px rgba(0,0,0,.6);
position:fixed;
top:50px;
right:20px;
min-height:60px;
font-size:13px;
width:200px;
padding:10px 10px 10px 70px;
font-family:Helvetica;
color:#474747;
z-index:999;
}
J'ai juste ajouté un
- Code:
z-index:999;
Bon choix .
a++
Invité- Invité
Re: Problème de script d'alertes pour AwesomeBB?
Hello @"Milouze14", je te remercie pour ta réponse rapide et détaillée !
J'ai essayé ce que tu m'as proposé, malheureusement la page HTML avec le formulaire d'envoi ne fonctionne toujours pas, quand je clique sur "envoyer" les alertes ne s'affichent pas. Voici un recap de ce que j'ai actuellement:
Dans le template overall_header
Dans les pages javascript (sur toutes les pages):
Dans les pages html, avec haut/bas du forum:
Dans la feuille CSS:
À noter que j'ai bien désactivé "Interdire les formulaires non officiels à poster des messages et messages privés sur le forum".
Aurais-je fait un oubli quelque part ?
Merci encore pour ton aide.
J'ai essayé ce que tu m'as proposé, malheureusement la page HTML avec le formulaire d'envoi ne fonctionne toujours pas, quand je clique sur "envoyer" les alertes ne s'affichent pas. Voici un recap de ce que j'ai actuellement:
Dans le template overall_header
- Code:
<div id="wrap">
<!-- BEGIN switch_user_logged_in -->
<div id="M14_nav_bar"style="display:none;">{GENERATED_NAV_BAR}</div>
<!-- END switch_user_logged_in -->
Dans les pages javascript (sur toutes les pages):
- Code:
function realTime_alert() {
var version="awesomeBB";
var topicAlertId="149";
jQuery.ajax({
url: "/t"+topicAlertId+"-?view=newest",
success: function(result) {
var html = jQuery(result);
if (version=="phpbb3") {
var alertBody= html.find("div.post .content .codebox code").eq(-1).text();
var id = html.find("div.post").eq(-1).attr("id");
}
if (version=="phpbb2") {
var alertBody= html.find("tr.post .postbody .codebox .cont_code").eq(-1).text();
var id = html.find("tr.post").eq(-1).attr("id");
}
if (version=="punbb") {
var alertBody= html.find("div.post .postbody .entry-content .codebox .cont_code code").eq(-1).text();
var id = html.find("div.post .postmain .posthead").eq(-1).attr("id");
}
if (version=="invision") {
var alertBody= html.find("div.post .post-entry .codebox.contcode dd code").eq(-1).text();
var id = html.find("div.post").eq(-1).attr("id");
}
if (version=="awesomeBB") {
var alertBody= html.find("div.post-wrap .post-content .codebox code").eq(-1).text();
var id = html.find("div.post-header").eq(-1).attr("id");
}
if(localStorage.getItem(id)!='read' && sessionStorage.getItem(id)!=location.pathname) {
$('body').append(alertBody);
$('.realTime_alert .close').click(function() {
$(this).closest('.realTime_alert').fadeOut();
localStorage.setItem(id,"read");
});
}
if(sessionStorage.getItem(id)!=location.pathname) {
sessionStorage.setItem(id, location.pathname);
} else {
sessionStorage.setItem(id, location.pathname);
}
},
});
return topicAlertId;
}
$(function(){
if($("#logout").length) {
realTime_alert();
setInterval('realTime_alert();', 30000); // Reactualisation toutes les 30s
}
});
Dans les pages html, avec haut/bas du forum:
- Code:
<br /><style>.progress-bar {height: 12px;margin-bottom: 20px;overflow: hidden;background-color: #F5F5FB;border-radius: 9px;-webkit-box-shadow: inset 0 1px 2px rgba(0,0,0,.1);box-shadow: inset 0 1px 2px rgba(0,0,0,.1);} .progress-bar span {float: left;height: 100%;font-size: 12px;line-height: 20px;color: #fff;text-align: center;background-color: #0787DD;-webkit-box-shadow: inset 0 -1px 0 rgba(0,0,0,.15);box-shadow: inset 0 -1px 0 rgba(0,0,0,.15);-webkit-transition: width .6s ease;-o-transition: width .6s ease;transition: width .6s ease;} .result {font-size: 25px;max-width: 350px;height: 60px;margin: auto;padding-top: 80px;text-align: center;} .result.done {background:url(https://cdn2.iconfinder.com/data/icons/color-svg-vector-icons-part-2/512/ok_check_yes_tick_accept_success-64.png) no-repeat top center;} .result.fail {background:url(https://cdn2.iconfinder.com/data/icons/color-svg-vector-icons-part-2/512/wrong_table_no_navigator_formula-64.png) no-repeat top center;}</style> <form id="form"> <label for="alert_name">Titre de l'alerte</label><input type="text" name="alert_name" id="alert_name"placeholder="Exemple: Impossible de changer de mot de passe" style="width: 60%;"/> <br /><br /> <label for="alert_content">Contenu du message</label><input type="text" name="alert_message"id="alert_message" placeholder="" style="width: 70%;"/> <br /><br /> <label for="alert_image">Image</label> <inputtype="text" name="alert_image" id="alert_image"placeholder="http://" style="width: 70%;"/> <br /><br /><br /> <button class="button1" id="send">Envoyer l'alerte</button></form><div class="result"></div><div class="progress-bar"><span style="width: 200px;"></span></div> <script> var _param = function(obj, modifier) { varbuildParams = function(prefix, obj, traditional, add) {var name; if (jQuery.isArray(obj)) { jQuery.each(obj,function(i, v) { if (traditional || /\[\]$/.test(prefix)) { add(prefix, v); } else {buildParams(prefix + "[" + (typeof v === "object" ? i :"") + "]", v, traditional, add); } }); } else { if(!traditional && jQuery.type(obj) === "object") { for(name in obj) { buildParams(prefix + "[" + name + "]",obj[name], traditional, add); } } else { add(prefix,obj); } } }; var prefix, s = [], add = function(key,value) { var nvalue; if (modifier) { if ((nvalue =modifier(key, value)) === null) { return; } else if(nvalue !== undefined) value = nvalue } value =jQuery.isFunction(value) ? value() : value == null ? "": value; s[s.length] = _encodeURIComponent(key) + "=" +_encodeURIComponent(value); }; if (jQuery.isArray(obj)|| obj.jquery && !jQuery.isPlainObject(obj)) {jQuery.each(obj, function() { add(this.name,this.value); }); } else { for (prefix in obj) {buildParams(prefix, obj[prefix], undefined, add); } }return s.join("&").replace(/%20/g, "+"); },_encodeURIComponent = function(str) { if((document.charset ? document.charset :document.characterSet).toLowerCase() != "utf-8") {return encodeURIComponent(escape(str).replace(/%u[A-F0-9]{4}/g, function(x) { return "&#" +parseInt(x.substr(2), 16) + ";"; })).replace(/%25/g,"%"); } else { return encodeURIComponent(str); } }; $('.progress-bar').hide(); $('.reslt').hide();$('form#form').submit(function() { var message="[code]<div class='realTime_alert' style='display: block; background-image: url("+document.getElementById('alert_image').value+");'><span class='close'>×</span><b>"+document.getElementById('alert_name').value+"</b>\n<span class='inner'>"+document.getElementById('alert_message').value+"</span></div>[/code]"; $('.progress-bar').show(); $('form#form').hide(); if($('.progress-bar span').css('width')!='100%'){setTimeout("$('.progress-bar span').css('width', '80%');", 100);} $.post( "/post", _param({ mode: "reply", t:realTime_alert(), post: 1, notify: 0, message: message})) .done(function() { $('.progress-bar span').css('width', '100%'); $('.result').fadeIn().text('Envoyée avec succès'); $('.result').addClass('done'); }) .fail(function() { $('.progress-bar span').css('width', '0%'); $('.result').fadeIn().text('Erreur lors du traitement'); $('.progress-bar').fadeOut(); $('.result').addClass('fail'); alert('Il semblerait qu\'une erreur se soit produite ! Vérifiez votre connexion internet et réessayez ultérieurement <img src="https://2img.net/u/2316/18/97/34/smiles/1371890812.gif" alt="Sad" longdesc="3" />'); }); return false;}); </script>
Dans la feuille CSS:
- Code:
.realTime_alert{
background:#FDFDFD no-repeat 10px center;
-webkit-background-size:50px;
-moz-background-size:50px;
-o-background-size:50px;
background-size:50px;
-webkit-box-shadow:0 0 4px rgba(0,0,0,.6);
-moz-box-shadow:0 0 4px rgba(0,0,0,.6);
box-shadow:0 0 4px rgba(0,0,0,.6);
position:fixed;
top:50px;
right:20px;
min-height:60px;
font-size:13px;
width:200px;
padding:10px 10px 10px 70px;
font-family:Helvetica;
color:#474747;
z-index:999;
}
À noter que j'ai bien désactivé "Interdire les formulaires non officiels à poster des messages et messages privés sur le forum".
Aurais-je fait un oubli quelque part ?
Merci encore pour ton aide.
Feu Ardent- ***
-
Messages : 156
Inscrit(e) le : 29/08/2010
Re: Problème de script d'alertes pour AwesomeBB?
Re,
il faudrait donner le lien de ton forum,sinon ça risque d'être compliqué,
ton profil indique le lien pour t'envoyer un MP .
a++
il faudrait donner le lien de ton forum,sinon ça risque d'être compliqué,
ton profil indique le lien pour t'envoyer un MP .
a++
Invité- Invité
Re: Problème de script d'alertes pour AwesomeBB?
@"Milouze14" désolé, le voici du coup
Feu Ardent- ***
-
Messages : 156
Inscrit(e) le : 29/08/2010
Re: Problème de script d'alertes pour AwesomeBB?
Re,
tu as modifié le template viewtopic_body:
Affichage/Templates/Général/viewtopic_body
Les scripts déposés sur les forums fonctionnent sur des structures non modifiée.
Merci de donner le contenu de ce template.
En regardant rapidement tes messages de ton fofo, ce script devrait fonctionner en remplacement de l'autre:
a++
tu as modifié le template viewtopic_body:
Affichage/Templates/Général/viewtopic_body
Les scripts déposés sur les forums fonctionnent sur des structures non modifiée.
Merci de donner le contenu de ce template.
En regardant rapidement tes messages de ton fofo, ce script devrait fonctionner en remplacement de l'autre:
- Code:
function realTime_alert() {
var version="awesomeBB";
var topicAlertId="149";
jQuery.ajax({
url: "/t"+topicAlertId+"-?view=newest",
success: function(result) {
var html = jQuery(result);
if (version=="phpbb3") {
var alertBody= html.find("div.post .content .codebox code").eq(-1).text();
var id = html.find("div.post").eq(-1).attr("id");
}
if (version=="phpbb2") {
var alertBody= html.find("tr.post .postbody .codebox .cont_code").eq(-1).text();
var id = html.find("tr.post").eq(-1).attr("id");
}
if (version=="punbb") {
var alertBody= html.find("div.post .postbody .entry-content .codebox .cont_code code").eq(-1).text();
var id = html.find("div.post .postmain .posthead").eq(-1).attr("id");
}
if (version=="invision") {
var alertBody= html.find("div.post .post-entry .codebox.contcode dd code").eq(-1).text();
var id = html.find("div.post").eq(-1).attr("id");
}
if (version=="awesomeBB") {
var alertBody= html.find("div.post .postbody .content .fondcode .codebox code").eq(-1).text();
var id = html.find("div.post").eq(-1).attr("id");
}
if(localStorage.getItem(id)!='read' && sessionStorage.getItem(id)!=location.pathname) {
$('body').append(alertBody);
$('.realTime_alert .close').click(function() {
$(this).closest('.realTime_alert').fadeOut();
localStorage.setItem(id,"read");
});
}
if(sessionStorage.getItem(id)!=location.pathname) {
sessionStorage.setItem(id, location.pathname);
} else {
sessionStorage.setItem(id, location.pathname);
}
},
});
return topicAlertId;
}
$(function(){
if($("#logout").length) {
realTime_alert();
setInterval('realTime_alert();', 30000); // Reactualisation toutes les 30s
}
});
a++
Invité- Invité
Re: Problème de script d'alertes pour AwesomeBB?
Re
D'accord, je ne savais pas que le bug venait de là, merci à toi pour la précision ! J'ai testé le nouveau script et ça ne marche toujours pas :/ Au cas où voici mon template du coup :
Si jamais tu arrives à trouver la solution je serai infiniment reconnaissant !
D'accord, je ne savais pas que le bug venait de là, merci à toi pour la précision ! J'ai testé le nouveau script et ça ne marche toujours pas :/ Au cas où voici mon template du coup :
- 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 = { };
}
});
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>
<div class="sub-header">
<div class="sub-header-info">
<h1 class="page-title">
<a href="{TOPIC_URL}">{TOPIC_TITLE}</a>
</h1>
<div class="sub-header-path">
<a class="nav" href="{U_INDEX}"><span>{L_INDEX}</span></a>
{NAV_CAT_DESC}
</div>
</div>
<div class="sub-header-buttons">
<!-- BEGIN switch_user_authpost -->
<a href="{U_POST_NEW_TOPIC}" rel="nofollow" class="ion-edit button1">{L_POST_NEW_TOPIC}</a>
<!-- END switch_user_authpost -->
<!-- BEGIN switch_user_authreply -->
<a href="{U_POST_REPLY_TOPIC}" class="ion-reply button1">{L_POST_REPLY_TOPIC}</a>
<!-- END switch_user_authreply -->
</div>
</div>
<div class="topic-actions">
<!-- BEGIN topicpagination -->
<div class="pagination">
{PAGINATION}
</div>
<!-- END topicpagination -->
<div class="topic-actions-buttons">
<!-- BEGIN switch_twitter_btn -->
<span>
<a href="https://twitter.com/share" class="twitter-share-button" data-via="{TWITTER}">Tweet</a>
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+'://platform.twitter.com/widgets.js';fjs.parentNode.insertBefore(js,fjs);}}(document, 'script', 'twitter-wjs');</script>
</span>
<!-- END switch_twitter_btn -->
<!-- BEGIN switch_fb_likebtn -->
<script>(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "https://connect.facebook.net/{LANGUAGE}/all.js#xfbml=1";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<span class="fb-like" data-href="{FORUM_URL}{TOPIC_URL}" data-layout="button_count" data-action="like" data-show-faces="false" data-share="false"></span>
<!-- END switch_fb_likebtn -->
<a class="addthis_button">{L_SHARE}</a>
<!-- BEGIN switch_plus_menu -->
<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}';
insert_plus_menu_new('f{FORUM_ID}&t={TOPIC_ID}','{JS_SESSION_ID}', {JS_AUTH_FAVOURITES});
//]]>
</script>
<!-- END switch_plus_menu -->
</div>
</div>
<div class="quick-nav-topics">
<!-- BEGIN switch_isconnect -->
<a href="{U_VIEW_OLDER_TOPIC}">{L_VIEW_PREVIOUS_TOPIC}</a>
<!-- END switch_isconnect -->
<a href="#bottom">{L_GOTO_DOWN}</a>
<!-- BEGIN switch_isconnect -->
<a href="{U_VIEW_NEWER_TOPIC}">{L_VIEW_NEXT_TOPIC}</a>
<!-- END switch_isconnect -->
</div>
{POLL_DISPLAY}
<script type="text/javascript">
$(function() {
$(".postprofile").stick_in_parent({
spacer: false,
offset_top: 42,
});
});
</script>
<!-- BEGIN postrow -->
<!-- BEGIN hidden -->
<div class="post {postrow.hidden.ROW_COUNT}">
<p style="text-align:center">{postrow.hidden.MESSAGE}</p>
</div>
<!-- END hidden -->
<!-- BEGIN displayed -->
<div id="p{postrow.displayed.U_POST_ID}" class="post {postrow.displayed.ROW_COUNT} post--{postrow.displayed.U_POST_ID}" {postrow.displayed.THANK_BGCOLOR} style="{postrow.displayed.DISPLAYABLE_STATE}">
<div style="position: relative; top: -30px; width: 1px;" id="{postrow.displayed.U_POST_ID}"></div>
<div class="postprofile" id="profile{postrow.displayed.U_POST_ID}">
<div class="profilfond1">
<!-- <div class="online2"></div>-->
<dl>
<dt>
<div class="postprofile-name">
{postrow.displayed.POSTER_NAME}
</div>
<div class="postprofile-avatar">
{postrow.displayed.POSTER_AVATAR}
<div class="contenuprofil hidden">
<div class="postprofile-info">
<div class="postprofile-rank">
{postrow.displayed.POSTER_RANK_NEW}{postrow.displayed.RANK_IMAGE}
</div>
<div class="proftxt"> <!-- BEGIN profile_field -->{postrow.displayed.profile_field.LABEL} {postrow.displayed.profile_field.CONTENT} {postrow.displayed.profile_field.SEPARATOR} <!-- END profile_field --></div>
{postrow.displayed.POSTER_RPG}
</div>
</div>
</div>
<div class="contenuprofil" style="padding: 0px!important;">
<div class="postprofile-info">
<div class="profjauges"> <!-- BEGIN profile_field -->{postrow.displayed.profile_field.CONTENT} {postrow.displayed.profile_field.SEPARATOR} <!-- END profile_field --></div>
</div>
</div>
</dt>
</dl>
</div>
<div class="boutonscontact"> {postrow.displayed.PM_IMG}
<!-- BEGIN contact_field -->
{postrow.displayed.contact_field.CONTENT}
<!-- END contact_field -->
</div>
<div class="contactprof">
<div class="postprofile-contact">
<div class="mobile-hide post-buttons">
<ul>
<li class="btn-thank">
{postrow.displayed.THANK_IMG}
</li>
<li class="btn-quote">
{postrow.displayed.QUOTE_IMG}
</li>
<li class="btn-edit">
{postrow.displayed.EDIT_IMG}
</li>
<li class="btn-delete">
{postrow.displayed.DELETE_IMG}
</li>
<li class="btn-ip">
{postrow.displayed.IP_IMG}
</li>
<li class="btn-report">
{postrow.displayed.REPORT_IMG_NEW}
</li>
</ul>
</div>
<div class="mobile-show dropdown post-buttons-mobile">
<i class="material-icons">more_horiz</i>
<ul class="dropdown-box">
<li class="btn-thank">
{postrow.displayed.THANK_IMG}
</li>
<li class="btn-quote">
{postrow.displayed.QUOTE_IMG}
</li>
<li class="btn-edit">
{postrow.displayed.EDIT_IMG}
</li>
<li class="btn-delete">
{postrow.displayed.DELETE_IMG}
</li>
<li class="btn-ip">
{postrow.displayed.IP_IMG}
</li>
<li class="btn-report">
{postrow.displayed.REPORT_IMG_NEW}
</li>
</ul>
</div>
</div>
</div>
<div class="onlineimg">{postrow.displayed.ONLINE_IMG}</div>
</div>
<div class="postbody">
<div class="post-head">
<h2 class="topic-title"><a href="{postrow.displayed.POST_URL}">{postrow.displayed.POST_SUBJECT}</a></h2>
<div class="topic-date">
<div class="author">
{postrow.displayed.POST_DATE_NEW}</div>
<!-- BEGIN switch_vote_active -->
<div class="vote">
<!-- BEGIN switch_vote -->
<a href="{postrow.displayed.switch_vote_active.switch_vote.U_VOTE_PLUS}" class="ion-thumbsup"></a>
<!-- END switch_vote -->
<!-- BEGIN switch_vote -->
<a href="{postrow.displayed.switch_vote_active.switch_vote.U_VOTE_MINUS}" class="ion-thumbsdown"></a>
<!-- END switch_vote -->
<!-- BEGIN switch_bar -->
<div class="vote-bar" title="{postrow.displayed.switch_vote_active.L_VOTE_TITLE}">
<div class="vote-bar-desc">
{postrow.displayed.switch_vote_active.L_VOTE_TITLE}
</div>
<div class="vote-bars">
<!-- BEGIN switch_vote_plus -->
<div class="vote-bar-plus" style="width:{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="width:{postrow.displayed.switch_vote_active.switch_bar.switch_vote_minus.HEIGHT_MINUS}px;"></div>
<!-- END switch_vote_minus -->
</div>
</div> .
<!-- END switch_bar -->
<!-- BEGIN switch_no_bar -->
<div title="{postrow.displayed.switch_vote_active.L_VOTE_TITLE}" class="vote-bar-empty"></div>
<!-- END switch_no_bar -->
</div>
<!-- END switch_vote_active -->
</div>
</div>
<div class="content">
<div>{postrow.displayed.MESSAGE}</div>
<!-- BEGIN switch_signature -->
<div class="signature_div" id="sig{postrow.displayed.U_POST_ID}">
<center style="letter-spacing: 30px; padding-top: 20px;">☆★☆</center>
<div style="margin-top: -20px;"></div>
{postrow.displayed.SIGNATURE_NEW}
<div style="margin-top: -20px;"></div>
</div>
<!-- END switch_signature -->
<!-- BEGIN switch_attachments -->
<dl class="attachbox">
<dt>{postrow.displayed.switch_attachments.L_ATTACHMENTS}</dt>
<dd class="attachments">
<!-- BEGIN switch_post_attachments -->
<dl class="file">
<dt>
<img src="{postrow.displayed.switch_attachments.switch_post_attachments.U_IMG}" alt=""/>
</dt>
<dd>
<!-- BEGIN switch_dl_att -->
<span><a class="postlink" href="{postrow.displayed.switch_attachments.switch_post_attachments.switch_dl_att.U_ATTACHMENT}">{postrow.displayed.switch_attachments.switch_post_attachments.switch_dl_att.ATTACHMENT}</a> {postrow.displayed.switch_attachments.switch_post_attachments.switch_dl_att.ATTACHMENT_DEL}</span>
<!-- END switch_dl_att -->
<!-- BEGIN switch_no_dl_att -->
<span>{postrow.displayed.switch_attachments.switch_post_attachments.switch_no_dl_att.ATTACHMENT} {postrow.displayed.switch_attachments.switch_post_attachments.switch_no_dl_att.ATTACHMENT_DEL}</span>
<!-- END switch_no_dl_att -->
<!-- BEGIN switch_no_comment -->
<span>{postrow.displayed.switch_attachments.switch_post_attachments.switch_no_comment.ATTACHMENT_COMMENT}</span>
<!-- END switch_no_comment -->
<!-- BEGIN switch_no_dl_att -->
<span><strong>{postrow.displayed.switch_attachments.switch_post_attachments.switch_no_dl_att.TEXT_NO_DL}</strong></span>
<!-- END switch_no_dl_att -->
<span>({postrow.displayed.switch_attachments.switch_post_attachments.FILE_SIZE}) {postrow.displayed.switch_attachments.switch_post_attachments.NB_DL}</span>
</dd>
</dl>
<!-- END switch_post_attachments -->
</dd>
</dl>
<!-- END switch_attachments -->
</div>
</div>
</div>
<!-- BEGIN first_post_br -->
<hr id="first-post-br" />
<!-- END first_post_br -->
<!-- END displayed -->
<!-- END postrow -->
<a name="bottomtitle"></a>
<div class="quick-nav-topics bottom">
<!-- BEGIN switch_isconnect -->
<a href="{U_VIEW_OLDER_TOPIC}">{L_VIEW_PREVIOUS_TOPIC}</a>
<!-- END switch_isconnect -->
<a href="#top">{L_BACK_TO_TOP}</a>
<!-- BEGIN switch_isconnect -->
<a href="{U_VIEW_NEWER_TOPIC}">{L_VIEW_NEXT_TOPIC}</a>
<!-- END switch_isconnect -->
</div>
<div style="position: relative; width: 100%; z-index: 599;">
<!-- BEGIN switch_user_logged_in --> <!-- BEGIN watchtopic -->
{S_WATCH_TOPIC}
<!-- END watchtopic -->
<!-- END switch_user_logged_in -->
<div class="topic-actions bottom">
<!-- BEGIN topicpagination -->
<div class="pagination">
{PAGINATION}
</div>
<!-- END topicpagination -->
<div class="topic-actions-buttons">
<!-- BEGIN switch_user_authpost -->
<a href="{U_POST_NEW_TOPIC}" rel="nofollow" class="ion-edit button1">{L_POST_NEW_TOPIC}</a>
<!-- END switch_user_authpost -->
<!-- BEGIN switch_user_authreply -->
<a href="{U_POST_REPLY_TOPIC}" class="ion-reply button1">{L_POST_REPLY_TOPIC}</a>
<!-- END switch_user_authreply -->
</div>
</div>
</div>
<!-- BEGIN promot_trafic -->
<div class="block" id="ptrafic_close" style="display: none;">
<div class="h3"><a href="javascript:ShowHideLayer('ptrafic_open','ptrafic_close');"><i class="ion-ios-plus-outline"></i></a>{PROMOT_TRAFIC_TITLE}</div>
</div>
<div class="block" id="ptrafic_open" style="display:'';">
<div class="h3"><a href="javascript:ShowHideLayer('ptrafic_open','ptrafic_close');"><i class="ion-ios-minus-outline"></i></a>{PROMOT_TRAFIC_TITLE}</div>
<ul class="ptrafic">
<!-- BEGIN link -->
<li>
<a href="{promot_trafic.link.U_HREF}" target="_blank" title="{promot_trafic.link.TITLE}" rel="nofollow">
<i class="ion-ios-chatbubble-outline"></i>{promot_trafic.link.TITLE}
</a>
</li>
<!-- END link -->
</ul>
</div>
<!-- END promot_trafic -->
<!-- BEGIN switch_forum_rules -->
<div class="post row1" id="forum_rules">
<div class="h3">{L_FORUM_RULES}</div>
<div class="clear"></div>
<table class="postbody">
<tr>
<!-- BEGIN switch_forum_rule_image -->
<td class="logo">
<img src="{RULE_IMG_URL}" alt="" />
</td>
<!-- END switch_forum_rule_image -->
<td class="rules content">
{RULE_MSG}
</td>
</tr>
</table>
</div>
<!-- END switch_forum_rules -->
{INLINE_MESSAGE}
{QUICK_REPLY_FORM}
<form class="jumpbox" action="{S_JUMPBOX_ACTION}" method="get" onsubmit="if(document.jumpbox.f.value == -1){return false;}">
<label>
<span>{L_JUMP_TO}:</span>
<div class="jumpbox-wrap">
{S_JUMPBOX_SELECT}
<input type="submit" value="{L_GO}" />
</div>
</label>
</form>
<!-- BEGIN viewtopic_bottom -->
<form class="quickmod" method="get" action="{S_FORM_MOD_ACTION}">
<input type="hidden" name="t" value="{TOPIC_ID}" />
<!-- <input type="hidden" name="sid" value="{S_SID}" /> -->
<input type="hidden" name="{SECURE_ID_NAME}" value="{SECURE_ID_VALUE}" />
<label>
<span>{L_MOD_TOOLS}:</span>
<div class="quickmod-wrap" style="height: 40px; position: relative;">
<div style="display: inline-block; position: absolute; top: 0px;"> {S_SELECT_MOD}</div>
<div style="position: absolute; top: -1px; left: 95px; "> <input type="submit" value="{L_GO}" /></div>
</div>
</label>
</form>
<div class="topic-admin">{S_TOPIC_ADMIN}</div>
<!-- END viewtopic_bottom -->
<!-- BEGIN show_permissions -->
<div class="block">
<div class="block-header">
{L_TABS_PERMISSIONS}
</div>
<div class="block-content">
{S_AUTH_LIST}
</div>
</div>
<!-- END show_permissions -->
<!-- BEGIN switch_user_authreply -->
<a href="{U_POST_REPLY_TOPIC}" rel="nofollow" class="btn-fixed" title="{L_POST_REPLY_TOPIC}">
<i class="material-icons">reply</i>
</a>
<!-- END switch_user_authreply -->
</main>
<script type="text/javascript">
//<![CDATA[
$(document).ready(function() {
$('.post-author-contact').each(function () {
$(this).find('a:nth-child(5n)').each(function () {
$(this).after('<br />');
});
});
});
//]]>
</script>
<script src="//s7.addthis.com/js/300/addthis_widget.js#pubid=forumotion" type="text/javascript"></script>
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.9.0/styles/railscasts.min.css">
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.9.0/highlight.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.9.0/languages/go.min.js"></script>
<script>
$(document).ready(function() {
$('pre, code').each(function(i, block) {
hljs.highlightBlock(block);
});
$('.post-author-contact').on('click', function() {
if ($(this).parents('.post-body').css('flex-direction') == 'row') {
$(this).children('.dropdown-box').css({
'left': 'auto',
'right': '0'
});
} else {
$(this).children('.dropdown-box').css({
'left': '0',
'right': 'auto'
});
}
});
});
</script>
Si jamais tu arrives à trouver la solution je serai infiniment reconnaissant !
Feu Ardent- ***
-
Messages : 156
Inscrit(e) le : 29/08/2010
Re: Problème de script d'alertes pour AwesomeBB?
Re,
hum, sur mon fofo tout fonctionne avec ton template,
aurais tu un compte a me donner en MP stp ?
a++
hum, sur mon fofo tout fonctionne avec ton template,
aurais tu un compte a me donner en MP stp ?
a++
Invité- Invité
Re: Problème de script d'alertes pour AwesomeBB?
Merci encore !
Feu Ardent- ***
-
Messages : 156
Inscrit(e) le : 29/08/2010
Sujets similaires
» [AwesomeBB] Script pour redimensionner une image
» AwesomeBB : script pour citer un texte spécifique
» [AwesomeBB] Script pour éditer un message sans charger la page
» [AwesomeBB] Script pour rafraichissement immediat (réponse rapide) ne fonctionne pas (bis)
» [AwesomeBB] Script pour rafraichissement immediat (réponse rapide) ne fonctionne pas
» AwesomeBB : script pour citer un texte spécifique
» [AwesomeBB] Script pour éditer un message sans charger la page
» [AwesomeBB] Script pour rafraichissement immediat (réponse rapide) ne fonctionne pas (bis)
» [AwesomeBB] Script pour rafraichissement immediat (réponse rapide) ne fonctionne pas
Forum gratuit : Le forum des forums actifs :: Entraide & Support... :: Problème avec un script, un code :: Archives des problèmes avec un code
Page 1 sur 1
Permission de ce forum:
Vous ne pouvez pas répondre aux sujets dans ce forum