TYPO3Jack.net - Das TYPO3 Mailinglist Forum Archiv

Die TYPO3 Mailingliste - nicht fragen: lesen!

[TYPO3] t3lib_div::makeInstance does not support initializationparameters

This is a discussion on [TYPO3] t3lib_div::makeInstance does not support initializationparameters within the typo3-english@lists.netfielders.de forums, part of the TYPO3-Mailinglists: ENGLISH category; Hi, Does it mean that I should use the new keyword for such case? Or why does the framework force ...


Zurück   TYPO3Jack.net - Das TYPO3 Mailinglist Forum Archiv > TYPO3-Mailinglists: ENGLISH > typo3-english@lists.netfielders.de

Registrieren Hilfe Benutzerliste Kalender Suchen Heutige Beiträge Alle Foren als gelesen markieren
  #1  
Alt 18.08.2008, 17:55
Xavier Perseguers
Gast
 
Beiträge: n/a
Standard [TYPO3] t3lib_div::makeInstance does not support initializationparameters

Hi,

Does it mean that I should use the new keyword for such case? Or why
does the framework force me to create a initialization function distinct
from the constructor?

I do not understand this...

--
Xavier Perseguers
http://xavier.perseguers.ch/en
_______________________________________________
TYPO3-english mailing list
TYPO3-english (AT) lists (DOT) netfielders.de
http://lists.netfielders.de/cgi-bin/.../typo3-english
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!Spurl this Post!Reddit! Diesen Post bei linksilo.de bookmarken!
  #2  
Alt 18.08.2008, 18:48
Dmitry Dulepov [typo3]
Gast
 
Beiträge: n/a
Standard Re: [TYPO3] t3lib_div::makeInstance does not support initializationparameters

Hi!

Xavier Perseguers wrote:
> Does it mean that I should use the new keyword for such case? Or why
> does the framework force me to create a initialization function distinct
> from the constructor?
>
> I do not understand this...


$class = t3lib_div::makeInstanceClassName('tx_whatever');
$inst = new $class($param);

--
Dmitry Dulepov
TYPO3 Core team
My TYPO3 book: http://www.packtpub.com/typo3-extens...velopment/book
In the blog: http://typo3bloke.net/post-details/t...ng_in_eclipse/
_______________________________________________
TYPO3-english mailing list
TYPO3-english (AT) lists (DOT) netfielders.de
http://lists.netfielders.de/cgi-bin/.../typo3-english
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!Spurl this Post!Reddit! Diesen Post bei linksilo.de bookmarken!
  #3  
Alt 18.08.2008, 19:04
Xavier Perseguers
Gast
 
Beiträge: n/a
Standard Re: [TYPO3] t3lib_div::makeInstance does not support initializationparameters

Hi Dmitry,

>> Does it mean that I should use the new keyword for such case? Or why
>> does the framework force me to create a initialization function
>> distinct from the constructor?
>>
>> I do not understand this...

>
> $class = t3lib_div::makeInstanceClassName('tx_whatever');
> $inst = new $class($param);


Ouf! I saw this method but it seems I went to quick over it

Thanks. I really appreciate this much more than having to call a special
method after the initialization.

--
Xavier Perseguers
http://xavier.perseguers.ch/en
_______________________________________________
TYPO3-english mailing list
TYPO3-english (AT) lists (DOT) netfielders.de
http://lists.netfielders.de/cgi-bin/.../typo3-english
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!Spurl this Post!Reddit! Diesen Post bei linksilo.de bookmarken!
 

Themen-Optionen Thema durchsuchen
Thema durchsuchen:

Erweiterte Suche
Ansicht Thema bewerten
Thema bewerten:

Forumregeln
Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are an


Ähnliche Themen

Thema Autor Forum Antworten Letzter Beitrag
[TYPO3-templavoila] t3lib_div::xml2array choking on characters Antonio Reher typo3-project-templavoila@lists.netfielders.de 1 20.05.2008 18:46
[TYPO3-german] t3lib_div::() gibts nicht? Christian Leicht typo3-german@lists.netfielders.de 1 28.04.2008 17:01
[TYPO3] corrupted class.t3lib_div.php? Cate & Peter typo3-english@lists.netfielders.de 2 15.02.2008 12:03
[TYPO3-templavoila] Missing makeInstance inclass.tx_templavoila_mod1_specialdoktypes.php Tapio Markula typo3-project-templavoila@lists.netfielders.de 0 15.08.2007 22:59
[TYPO3-german] Wohin schreibt t3lib_div::devLog() ? Rolf Masfelder typo3-german@lists.netfielders.de 4 21.12.2006 02:46


Alle Zeitangaben in WEZ +1. Es ist jetzt 00:05 Uhr.


Powered by vBulletin® Version 3.7.2 (Deutsch)
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.1.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74