[Typo3-UG Oesterreich] Probleme mit Extension
Michael Inselsbacher
peacekeeper118 at hotmail.com
Thu May 13 14:41:36 CEST 2004
Hi Leute!
Ich habe jetzt versucht im neuen Typo3 eine extension zu erstellen.
Als ich die DB konfiguriert hatte und es auch als frontpage plugin
gespeichert habe wollte ich es auf die typo3 seite laden um die
grundfunktion zu testen.
Ich habe aber irgendwie das Gefühl das die Main funktion nicht angesprochen
wird.
Normalerweise sollte da ja ein Formular stehen wenn ich den code richtig
lese, oder?
Kann mir dazu jemand einen Tipp geben?
Danke,
Michael
Source Code:
require_once(PATH_tslib."class.tslib_pibase.php");
echo("TETS");
class tx_MIExcelReciever_pi1 extends tslib_pibase {
var $prefixId = "tx_MIExcelReciever_pi1"; // Same as class name
var $scriptRelPath = "pi1/class.tx_MIExcelReciever_pi1.php"; // Path to
this script relative to the extension dir.
var $extKey = "MI_Excel_Reciever"; // The extension key.
/**
* [Put your description here]
*/
function main($content,$conf) {
$this->conf=$conf;
$this->pi_setPiVarDefaults();
$this->pi_loadLL();
echo("TETS");
$content='
<strong>This is a few paragraphs:</strong><BR>
<p>This is line 1</p>
<p>This is line 2</p>
<h3>This is a form:</h3>
<form action="'.$this->pi_getPageLink($GLOBALS["TSFE"]->id).'"
method="POST">
<input type="hidden" name="no_cache" value="1">
<input type="text" name="'.$this->prefixId.'[input_field]"
value="'.htmlspecialchars($this->piVars["input_field"]).'">
<input type="submit" name="'.$this->prefixId.'[submit_button]"
value="'.htmlspecialchars($this->pi_getLL("submit_button_label")).'">
</form>
<BR>
<p>You can click here to '.$this->pi_linkToPage("get to this page
again",$GLOBALS["TSFE"]->id).'</p>
';
return $this->pi_wrapInBaseClass($content);
}
}
_________________________________________________________________
Schützen Sie Ihren Posteingang vor unerwünschten E-Mails.
http://www.msn.de/antispam/prevention/junkmailfilter Schluß mit Spam - MSN
hilft Ihnen hier weiter.
More information about the TYPO3-at
mailing list