';
contenu_upd = true;
}
break;
case '[/lotro]':
if (lfr_open){
lfr_open = false;
contenu_parse = '';
}
break;
}
contenu_split.push( contenu_parse );
idx_start = idx_start + matches[1].length;
}
if (idx_start < contenu.length) contenu_split.push( contenu.substring(idx_start) );
// reconstruct body
if (contenu_upd) document.getElementsByTagName("BODY")[0].innerHTML = contenu_split.join('');
//document.getElementsByTagName("BODY")[0].innerHTML = contenu.replace(myrx,'$1');
var tipNameSpaceURI = "http://www.w3.org/1999/xhtml";
if(!tipContainerID){ var tipContainerID = "qTip";}
var tipContainer = document.getElementById(tipContainerID);
if(!tipContainer){
tipContainer = document.createElementNS ? document.createElementNS(tipNameSpaceURI, "div") : document.createElement("div");
tipContainer.setAttribute("id", tipContainerID);
tipContainer.style.border = "1px solid #666666";
tipContainer.style.display = "none";
tipContainer.style.position = "absolute";
tipContainer.style.zindex = "99999";
tipContainer.style.width = "302px";
document.getElementsByTagName("body").item(0).appendChild(tipContainer);
}
if (!document.getElementById) return;
this.tip = document.getElementById (this.name);
if (this.tip) document.onmousemove = function (evt) {tooltip.move (evt)};
var a, sTitle, sID, elements;
elements = document.getElementsByTagName("span");
if(elements){
for (var i = 0; i < elements.length; i ++){
a = elements[i];
if (a.className != "lotrofr") continue;
sID = a.getAttribute("oid");
a.removeAttribute("title");
a.removeAttribute("alt");
sTitle = "http://lotro.fr/bdd/objet_img/";
if (sID){
sTitle+=sID+"-.png";
}else{
sTitle+=a.innerHTML+".png";
}
a.setAttribute("tip",sTitle);
a.onmouseover = function(evt){tooltip.show(evt,this.getAttribute("tip"))};
a.onmouseout = function(){tooltip.hide()};
a.onclick = function(evt){tooltip.click(evt,this.getAttribute("tip"))};
}
}
}
tooltip.move = function (evt){
if (!this.trackmouse) return false;
var x=0, y=0;
if (document.all) {//IE
x = (document.documentElement && document.documentElement.scrollLeft) ? document.documentElement.scrollLeft : document.body.scrollLeft;
y = (document.documentElement && document.documentElement.scrollTop) ? document.documentElement.scrollTop : document.body.scrollTop;
x += window.event.clientX;
y += window.event.clientY;
} else {//Good Browsers
x = evt.pageX;
y = evt.pageY;
}
this.tip.style.left = (x + this.offsetX) + "px";
this.tip.style.top = (y + this.offsetY) + "px";
}
tooltip.show = function (evt,text) {
if (!this.tip) return;
this.trackmouse = true;
this.move(evt);
this.tip.innerHTML = '';
this.tip.style.display = "block";
}
tooltip.hide = function (){
if (!this.tip || !this.trackmouse) return;
this.tip.innerHTML = "";
this.tip.style.display = "none";
this.trackmouse = false;
}
tooltip.click = function (evt,text) {
if (!this.tip) return;
this.tip.innerHTML = '
[Fermer]
';
this.tip.style.display = "block";
this.trackmouse = false;
}
window.onload = function (){ tooltip.init(); }
// -->
Chargement...