Where I can modify TaxonomiesSection for UploadDocuments??
In Settings - Advanced - Libraries tree, I cannot find TaxonomiesSection for UploadDocuments page. I would like to set Categories and tags section to be expanded.
Thanks.
Hello,
Thank you for using our services.
I observed this behavior, and indeed, the taxonomies section is not available in the configurations. However, one thing you can do is change the default backend theme. Since currently the css property display: none; is set to the Taxonomies section, you can simply declare display: block in your new backend theme. This should be enough to make the section visible. The only possible way to extend the styles of the backend theme is to use the default backend theme (located in a .zip file in the SDK) and add your styles to it. Then register it as a Custom backend theme in Administration -> Settings -> Appearance (as you properly pointed out). If the changes you want to introduce to the theme are minor, you can also add styles with a css widget on the backend pages.
Hope this helps!
Thank you.
Could you please give me more details to edit backend template? Which tree section hides its taxonomies section for upload images/documents???
Hi Jae Hong,
Please observe the attached image. This is the div, which is currently hidden. If you declare display: block to it, this will make it visible.
Kind regards,Thank you for the answer; however, that is not the one I want to edit. (I may give you confusion)
My category tree as below:
Root
- Documents
- Images
- News
In Settings - Advanced, I already setup each content controls' Root taxon ID (Insert, Edit, bulkEdit) to it's category ID. (see attach)
My question is how to setup Root taxon ID for Upload Image and Documents ?? I could not find upload image document configuration section ....
Hello Jae Hong,
Since the UploadDialog doesn't have definitions, exposed in the Configurations section of Sitefinity, you would have to ma its template to set the Root TaxonID of the Categories selector. I have attached below a modified template, where in the code-behind on the OnPrerender event we do the following:
protected
override
void
OnPreRender(EventArgs e)
base
.OnPreRender(e);
var taxonomyControl =
this
.FindControl(
"taxonomiesSelector"
)
as
SectionControl;
foreach
(var fieldDefinition
in
taxonomyControl.Fields)
if
(fieldDefinition.GetType() ==
typeof
(HierarchicalTaxonFieldDefinition) && fieldDefinition.Title ==
"Custom taxonomy1"
)
var categorySelector = (HierarchicalTaxonFieldDefinition)fieldDefinition;
categorySelector.RootTaxonID =
new
Guid(
"1c1241c3-8bf1-6570-800f-ff00002d8424"
);
else
if
(fieldDefinition.GetType() ==
typeof
(HierarchicalTaxonFieldDefinition) && fieldDefinition.Title ==
"Custom taxonomy2"
)