![]() |
| | LinkBack | Themen-Optionen | Thema bewerten | Ansicht |
|
#1
| |||
| |||
ich hab ein darstellungsproblem meiner eigenen extension... ich möchte die daten wie eingegeben als tabelle ausgeben. mein template sieht so aus: Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html> <head> <title>Untitled</title> </head> <body> <!-- ###BODY_INHALT### begin--> <table width="100%" border="1" cellspacing="1" cellpadding="0"> <!-- ###BL64### begin--> <tr> <td>###WTAG###</td> <td>###DATUM###</td> <td>###ZEIT###</td> <td>###BESUCHER###</td> <td>###ANZAHL###</td> <td>###KONTAKTPERSON###</td> <td>###FUEHRER###</td> </tr> <!-- ###BL64### end--> </table> <!-- ###BODY_INHALT### end--> </body> </html> Code: ...
plugin.tx_bl64_pi{
tmpl = fileadmin/template/bl64.htm
...
} Code: <?php
/***************************************************************
* Copyright notice
*
* (c) 2006 Patrick Jordi <patrick@patrick-jordi.ch>
* All rights reserved
*
* This script is part of the TYPO3 project. The TYPO3 project is
* free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* The GNU General Public License can be found at
* http://www.gnu.org/copyleft/gpl.html.
*
* This script is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* This copyright notice MUST APPEAR in all copies of the script!
***************************************************************/
/**
* Plugin 'bl64-fuehrungen' for the 'bl64' extension.
*
* @author Patrick Jordi <patrick@patrick-jordi.ch>
*/
require_once(PATH_tslib.'class.tslib_pibase.php');
class tx_bl64_pi1 extends tslib_pibase {
var $prefixId = 'tx_bl64_pi1'; // Same as class name
var $scriptRelPath = 'pi1/class.tx_bl64_pi1.php'; // Path to this script relative to the extension dir.
var $extKey = 'bl64'; // The extension key.
var $pi_checkCHash = TRUE;
/**
* The main method of the PlugIn
*
* @param string $content: The PlugIn content
* @param array $conf: The PlugIn configuration
* @return The content that is displayed on the website
*/
function main($content,$conf) {
$this->conf=$conf;
$this->pi_setPiVarDefaults();
$this->pi_loadLL();
$content="";
$marker = array();
$template = $this->cObj->fileResource($conf["tmpl"]);
$template = $this->cObj->getSubpart($template, "###BODY_INHALT###");
$template_referenz = $this->cObj->getSubpart($template, "###BL64###");
$result = $GLOBALS["TYPO3_DB"]->exec_SELECTquery("*","tx_bl64_main", "deleted = 0 AND hidden = 0");
if (mysql_error()) debug(array(mysql_error(),$query));
while ($row = mysql_fetch_row ($result))
{
$marker["###DATUM###"] = $row[7];
$marker["###ZEIT###"] = $row[8];
$marker["###BESUCHER###"] = $row[9];
$marker["###ANZAHL###"] = $row[10];
$marker["###KONTAKTPERSON###"] = $row[11];
$marker["###FUEHRER###"] = $row[12];
$content .=$this->cObj->substituteMarkerArrayCached($template, $marker);
}
return $content;
}
}
if (defined('TYPO3_MODE') && $TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['ext/bl64/pi1/class.tx_bl64_pi1.php']) {
include_once($TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['ext/bl64/pi1/class.tx_bl64_pi1.php']);
}
?> Code: <table width="100%" border="1" cellspacing="1" cellpadding="0"> <table width="100%" border="1" cellspacing="1" cellpadding="0"> <!-- ###BL64### begin--> <tr> <td>1164322800</td> <td>14.00 - 16.00</td> <td>Testgruppe</td> <td>138</td> <td>Hans Muster</td> <td>Hans Muster</td> <td></td> </tr> <!-- ###BL64### end--> </table> <table width="100%" border="1" cellspacing="1" cellpadding="0"> <!-- ###BL64### begin--> <tr> <td>1164322800</td> <td>14.00 - 16.00</td> <td>Testgruppe</td> <td>138</td> <td>Hans Muster</td> <td>Hans Muster</td> <td></td> </tr> <!-- ###BL64### end--> </table> </table> Code: <table width="100%" border="1" cellspacing="1" cellpadding="0">
<tr>
<td>1164322800</td>
<td>14.00 - 16.00</td>
<td>Testgruppe</td>
<td>138</td>
<td>Hans Muster</td>
<td>Hans Muster</td>
<td></td>
</tr>
<tr>
<td>1164322800</td>
<td>14.00 - 16.00</td>
<td>Testgruppe</td>
<td>138</td>
<td>Hans Muster</td>
<td>Hans Muster</td>
<td></td>
</tr>
<!-- ###BL64### end-->
</table> Danke im voraus! Viele Grüsse patrick |
![]() |
| Lesezeichen |
| Themen-Optionen | |
| Ansicht | Thema bewerten |
| |
Ähnliche Themen | ||||
| Thema | Autor | Forum | Antworten | Letzter Beitrag |
| Bilder darstellen | smithers | Extension suchen und neue vorschlagen | 4 | 06.08.07 10:49 |
| Kontakte darstellen | Spocky | Extension suchen und neue vorschlagen | 0 | 25.06.07 12:52 |
| XML auslesen und darstellen | dallartz | Extension suchen und neue vorschlagen | 0 | 18.06.07 10:06 |
| Archivdatum in tt_news darstellen!? | Kurt51 | TYPO3 4.x Fragen und Probleme | 0 | 20.10.06 16:37 |
| Datenbanktabellen darstellen | schildi | TYPO3 3.x Fragen und Probleme | 0 | 14.12.05 12:53 |