[nycphp-talk] Two objects of the same type in same script
David Krings
ramons at gmx.net
Wed Jul 25 14:15:47 EDT 2007
Hi!
As recommended to me some time ago, I used the FCKEditor for my current
project and so far with good success. I will need three editor
components on the page and now wonder on how to add a second editor
object. I am totally uneducated in regards to OOP and PHP and I hope
someone here can fix that a bit.
Currently, I got this:
$oFCKeditor = new FCKeditor('sbtext');
$oFCKeditor->Width = '100%';
$oFCKeditor->Height = '200';
$oFCKeditor->Value = $sbtext;
$oFCKeditor->ToolbarSet = 'cups';
$oFCKeditor->Create();
When I now want to initiate a new editor, do I change it like this:
$oFCKeditor = new FCKeditor('sbnotes') ;
or like this
$oFCKeditorNotes = new FCKeditor('sbnotes');
So, unrelated to the editor, how do I instantiate a second instance of
an object?
Any tips are greatly appreciated.
David
More information about the talk
mailing list