How to filter content for given profiling attribute
Having trouble deploying Oxygen XML Web Author? Got a bug to report? Post it all here.
-
- Posts: 67
- Joined: Thu Oct 29, 2020 12:01 am
How to filter content for given profiling attribute
Post by manojdcoder »
Is it possible to filter document content by one or more profiling attributes?
For example if I have content for two different country, I would like to allow user to filter content for one country, so the other one is hidden.
For example if I have content for two different country, I would like to allow user to filter content for one country, so the other one is hidden.
-
- Posts: 513
- Joined: Thu Sep 04, 2014 4:22 pm
Re: How to filter content for given profiling attribute
Post by cristi_talau »
Hello,
You can filter the content by specifying a DITAVAL file as an URL parameter, or by using the JS API [1].
The default behavior is to render the excluded content with low opacity. You can add a custom CSS in the Web Author UI [2] to specify a different style for elements with "oxy-filtered" class, for example to hide them. Note however that this CSS class is not API and is possible to change in a future version. However, at some point we will also offer the option to hide excluded content, so you will not have to use this class anymore.
Best,
Cristian
[1] https://www.oxygenxml.com/doc/versions/ ... e-cms.html
[2] https://www.oxygenxml.com/doc/versions/ ... 3j_p1x_3bb
You can filter the content by specifying a DITAVAL file as an URL parameter, or by using the JS API [1].
The default behavior is to render the excluded content with low opacity. You can add a custom CSS in the Web Author UI [2] to specify a different style for elements with "oxy-filtered" class, for example to hide them. Note however that this CSS class is not API and is possible to change in a future version. However, at some point we will also offer the option to hide excluded content, so you will not have to use this class anymore.
Best,
Cristian
[1] https://www.oxygenxml.com/doc/versions/ ... e-cms.html
[2] https://www.oxygenxml.com/doc/versions/ ... 3j_p1x_3bb
-
- Posts: 67
- Joined: Thu Oct 29, 2020 12:01 am
Re: How to filter content for given profiling attribute
Post by manojdcoder »
Lets say we have an editor action in the toolbar using which user can pick the attributes he wants to show / hide.
Is it possible to pass the DITAVAL content as parameters instead of file url? Would you suggest implementing a servlet that would return the DITAVAL content?
Is it possible to pass the DITAVAL content as parameters instead of file url? Would you suggest implementing a servlet that would return the DITAVAL content?
Re: How to filter content for given profiling attribute
Hello,
There is no parameter available to provide the DITAVAL content, you can only provide the URL of a DITAVAL file. The solution you suggested seems right.
Best regards,
Mihaela
There is no parameter available to provide the DITAVAL content, you can only provide the URL of a DITAVAL file. The solution you suggested seems right.
Best regards,
Mihaela
Mihaela Calotescu
http://www.oxygenxml.com
http://www.oxygenxml.com
-
- Posts: 67
- Joined: Thu Oct 29, 2020 12:01 am
Re: How to filter content for given profiling attribute
Post by manojdcoder »
Thank you mihael.
Does Oxygen have something similar for DocBook, filter by profile attributes?
Does Oxygen have something similar for DocBook, filter by profile attributes?
Re: How to filter content for given profiling attribute
Hi,
There is no URL parameter similar with ditaval for DocBook, but you can implement that functionality using the current API: you can set a pseudo pseudo-class on the root XML element describing which are the attribute values to be searched to show or hide elements using CSS. Here is a forum post that explain how you can do this (the post contains a DITA sample, but it is similar for DocBook):
topic14410.html#p42512
This approach is suitable for the case when you want to dynamically change the profiling information.
If you need to impose the initial profiling conditions you can use the following API added on 23.0 that alloows you to set various pseudo classes to elements before the content is presented visually:
https://www.oxygenxml.com/InstData/Edit ... essor.html
Best Regards,
Mihaela
There is no URL parameter similar with ditaval for DocBook, but you can implement that functionality using the current API: you can set a pseudo pseudo-class on the root XML element describing which are the attribute values to be searched to show or hide elements using CSS. Here is a forum post that explain how you can do this (the post contains a DITA sample, but it is similar for DocBook):
topic14410.html#p42512
This approach is suitable for the case when you want to dynamically change the profiling information.
If you need to impose the initial profiling conditions you can use the following API added on 23.0 that alloows you to set various pseudo classes to elements before the content is presented visually:
https://www.oxygenxml.com/InstData/Edit ... essor.html
Best Regards,
Mihaela
Mihaela Calotescu
http://www.oxygenxml.com
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service