Do I need to do something special to use a widget from an other module like for example TaxonomyModule?
Rgds,
F
Do I need to do something special to use a widget from an other module like for example TaxonomyModule?
Rgds,
F
No you don't. Just assure that the other module is available.
If you want to publish your own module in the TYPOlight extension repository, you have to add a dependency to this exact module using the dependencies edit button.
That's all.
Best,
Helmut
Blackmail's such an ugly word. I prefer extortion -- the "x" makes it sound cool.
-- Bender
Thx for the reply! But I think I didn't explain correctly. I want to use this widget I my code. DO I need to include the file or do I need to add some code in my configuaration file, as it look like nothing is happening if I use the taxonomy tree widget.
thx
Hi freeyland,
that's what I meant too
I don't know the taxonomy module but if the taxonomy tree is a widget (defined by the taxonomy module), you should have the taxonomy module installed. To use the widget in your code, just create a new instance of the widget like you create any other widget. Usually you don't need to import anything because taxonomy made the widget available.
What you shouldn't do is to copy let's say the taxonomy tree widget class from the taxonomy module into your module and use it there.
Now, to answer your question: You don't need to import the class and you don't need to add some code to your config file.
Best,
Helmut
Blackmail's such an ugly word. I prefer extortion -- the "x" makes it sound cool.
-- Bender
Aaah,
and since the availability of modules is announced be their alphabetical order in the system/modules directory, you might name the directory of your module with something that is after taxonomy in the alphabet.
Best,
Helmut
Blackmail's such an ugly word. I prefer extortion -- the "x" makes it sound cool.
-- Bender
thx.
This is what i've done:
But I can't see my taxonomytree widget. Do you have any idea?Code:$GLOBALS['TL_DCA']['tl_requests'] = array ( // Config .. // List .. // Palettes 'palettes' => array ( '__selector__' => array('addPoReceived', 'addEnclosure'), 'default' => 'modules,author;project,details,implications;status;{enclosure_legend},addEnclosure;cost;{poreceived_legend},addPoReceived;comment;taxonomyRoot', ), // Subpalettes 'subpalettes' => array ( 'addPoReceived' => 'poreceived', 'addEnclosure' => 'enclosure' ), // Fields 'fields' => array ( ...... 'modules' => array ( 'label' => &$GLOBALS['TL_LANG']['tl_requests']['module'], 'exclude' => true, 'search' => true, 'inputType' => 'TaxonomyTree', 'eval' => array('mandatory' => true, 'fieldType' => 'radio','rootid' => '1') ), ..... ) );
thx
Hm,
seems good to me.
What's the name of the folder that contains your dca/tl_requests.php (your module folder)?
Best,
Helmut
Blackmail's such an ugly word. I prefer extortion -- the "x" makes it sound cool.
-- Bender
system/modules/requests
I've posted an other ticket in the forum to ask if it is possible tu use a widget in the front-end. The told me it is not possible.
So I think this is the reason why the taxonomytree is not getting displayed. Strange that I don't get any error message.
I thought you could use all form elements and widgets in a frontend module.
Thx for the help!!!
The backend uses the dca to instantiate backend widgets as it contains a standard editing framework. The front end doesn't use the dca at all, since it's based on templates, for which you manually have to create every template variable and render the template. The front end contains no structure at all, it's all up to you.
Hi,
Again I tried to use the taxonomy widget in a new project.
This time i want to use the taxonomy tree in the backend, but still it is getting displayed.
This is the code I added in DCA / fields part:
'status' => array
(
'label' => &$GLOBALS['TL_LANG']['boekingen']['status'],
'inputType' => 'TaxonomyTree',
'eval' => array('mandatory' => true, 'fieldType' => 'radio','rootid' => '2')
),
Do I need to do something else.
My name of moduleis znowflake, so after taxonomy module
thx for the help
Hi,
Found the problem myself.
taxonomyTree and not TaxonomyTree
Bookmarks