Hallo liebes Forum,
in der Extension moc-filemanager gibt es die Möglichkeit, mit einem Layer Infos aus einer DB auszulesen (Uploadatum, Uploaduser(uid), Filesize, etc.) Dieser Layer funzt derzeit ab er nur im IE7 #angry#
Ich benötige dringend Hilfe bez. Java, damit die Layerfunktion auch in anderen Browsern funz. Es ist wiklich dringend. Stehe schon seit einigen Std. vor diesem Problem und komme trotz Forumbeiträgen und Google def. nicht weiter...
Für Eure Hilfe vorab vielen Dank!!!!
$this->canUseLayers = ($this->cInfo['BROWSER'] == 'msie' && false ? 1 : 0) ;
$this->recursive = $this->cObj->stdWrap($this->conf["recursive"],$this->conf["recursive."]);
$this->mode = strtoupper($this->cObj->stdWrap($this->conf["CODE"],$this->conf["CODE."]));
$this->asExplorer = 1;
Und dann...
function writeLayers($mount,$parentdir,$entries) {
if(!is_array($entries))
return "";
$index= 0;
foreach ($entries as $entry){
$row = $this->div->getAdditionalInfo($mount,"$parentdir/$entry");
$layerName = "MOC_filemanager_layer_".$index;
$content .='
<!-- **** InfoLayer'.$layerName.' **** -->
<div id="'.$layerName.'" width="250" style="position:absolute;visibility: hidden;">
<table width="250" cellspacing="0" class="MainInfoTable">
<tr>
<td>
'.$this->pi_getLL('filename').': '.$entry.'<br />
'.$this->pi_getLL('size').': '.($row["size"] != 0 ? t3lib_div::formatSize($row['size']) : $this->pi_getLL('unknown')).'<br />
'.$this->pi_getLL('uploaded_date').': '.($row['uploaded'] ? strftime($this->conf['datetimeFormat'],$row['uploaded']) : $this->pi_getLL('unknown')).'<br />
'.$this->pi_getLL('uploaded_by').': '.($row['name'] ? $row['name'] : $this->pi_getLL('unknown')).'<br />
'.$this->pi_getLL('number_of_downloads').': '.$row['downloads'].'<br />
'.($this->conf['useDescriptions'] ? '<hr />'.$row["comment"] : '').'
</td>
</tr>
</table>
</div>
<!-- ************************* -->
';
$index++;
}
return $content;
}
Und hier das javascript:
if (is_dir("$dir")) {
$files = t3lib_div::getFilesInDir("$dir","",0,"mtime");
$numfiles = count($files);
if($this->canUseLayers) {
$content .= '
<script language="JavaScript" type="text/javascript">
activeInfoLayerHandle = null;
function MOC_filemanager_activateInfo(id) {
alert(id);
MOC_filemanager_hideActiveInfo();
handle = document.getElementById(id);
posx = event.clientX + document.body.scrollLeft-250;
posy = event.clientY + document.body.scrollTop;
handle.style.top= posy;
handle.style.left = posx;
handle.style.visibility = "visible";
activeInfoLayerHandle = handle;
}
function MOC_filemanager_hideActiveInfo() {
if(activeInfoLayerHandle) {
activeInfoLayerHandle.style.visibility = "hidden";
}
activeInfoLayerHandle = null;
}
</script>
';
}