// lastfive_fr.js
var L5FrameTop; // our last five topics IFrame object
function show_last5t() {
 var responseMessage = document.getElementById('lastfive');
 if(!document.createElement) {return true};
 var IFrameDoc5Last;
 var URL = 'fforum/in.php';
 responseMessage.innerHTML = '<span style="color:green">Téléchargement en cours...<\/span>';
	
 if(!L5FrameTop && document.createElement) {
  try {
   var tempIFrame=document.createElement('iframe');
   tempIFrame.setAttribute('id','last5Frame');
   tempIFrame.style.border='0px';
   tempIFrame.style.width='0px';
   tempIFrame.style.height='0px';
   L5FrameTop = document.body.appendChild(tempIFrame);
   if(document.frames) {
    // this is for IE5 Mac
    L5FrameTop = document.frames['last5Frame'];
   }
  } catch(exception) {
   // This is for IE5 PC
   iframeHTML='<iframe id="last5Frame" style="';
   iframeHTML+='border:0px;';
   iframeHTML+='width:0px;';
   iframeHTML+='height:0px;';
   iframeHTML+='"><\/iframe>';
   document.body.innerHTML+=iframeHTML;
   L5FrameTop = new Object();
   L5FrameTop.document = new Object();
   L5FrameTop.document.location = new Object();
   L5FrameTop.document.location.iframe = document.getElementById('last5Frame');
   L5FrameTop.document.location.replace = function(location) {
    this.iframe.src = location;
   }
  }
 }
 if(navigator.userAgent.indexOf('Gecko') !=-1 && !L5FrameTop.contentDocument) {
  // we have to give NS6 a fraction of a second
  // to recognize the new IFrame
  setTimeout('show_last5t()',10);
  return false;
 }
 if(L5FrameTop.contentDocument) {
  // For NS6
  IFrameDoc5Last = L5FrameTop.contentDocument;
 } else if(L5FrameTop.contentWindow) {
  // For IE5.5 and IE6
  IFrameDoc5Last = L5FrameTop.contentWindow.document;
 } else if(L5FrameTop.document) {
  // For IE5
  IFrameDoc5Last = L5FrameTop.document;
 } else {
  return true;
 }
 IFrameDoc5Last.location.replace(URL);
 return false;
}
function handle5TopResponse(doc) {
 var resMessage = document.getElementById('lastfive');
 resMessage.innerHTML = doc.getElementById('lastfiveresponse').innerHTML;
 return false;
}
