Expand my Community achievements bar.

SOLVED

How to use experience fragment to manage disclaimers?

Avatar

Level 1

We have 10 different disclaimers we list on various pages as text in a footer. Some pages have all 10 listed and some may only have 7. Is there a way to implement an experience fragment that would allow us to select which disclaimers we want to appear on a given page? Or would I need to create a version for 1-10 vs. 1-7 vs. 1,3,7,10, etc.? 

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @savpro,

 

Ideally, the XF versions are used if you are creating different versions of the same content. As you said, if you have 10 different disclaimers, it should be 10 different XFs with their own versions

 

If you still want to use a single XF, the best way is 

  1. author them on the page as required or
  2. create a template based on the disclaimer appearance and author it in the template and create pages using these templates

Hope this helps!

 

Thanks,

Kiran Vedantam.

View solution in original post

4 Replies

Avatar

Correct answer by
Community Advisor

Hi @savpro,

 

Ideally, the XF versions are used if you are creating different versions of the same content. As you said, if you have 10 different disclaimers, it should be 10 different XFs with their own versions

 

If you still want to use a single XF, the best way is 

  1. author them on the page as required or
  2. create a template based on the disclaimer appearance and author it in the template and create pages using these templates

Hope this helps!

 

Thanks,

Kiran Vedantam.

Avatar

Employee Advisor

One option you can consider is to use tags. Assign a tag to each xFragment disclaimer. Now on your page, you can select the disclaimer tag which needs to be rendered on this page.

Benefits you will see with this approach are:

  • Editors can control which disclaimer to be placed on the page
  • Editors can also control the sequence of disclaimers (based on the order tags are selected)
  • You can implement inheritance behavior also for disclaimer.

Though, the constraint with this approach will be that the placement of the disclaimer will be controlled at the template level. You have the flexibility to create a component, which renders disclaimers (by reading tags in page property) and uses this component in the structure section or as part of page authoring.

Avatar

Level 5

@savpro  - You should have 'N' versions of XF versions to defined the different experience.

 

Consuming XF's on Pages -

Component to include XF's versions based on customer authoring requirement.

  1.   Simple XF component can be include to page.(Multiple in your case)
  2.   Custom Component  -Dialog Based selection of disclaimers versions internally it can simple resource include or based on query (tags) etc..

Hopes helps you.

   

 

 

Avatar

Employee Advisor

@savpro the approaches that have been suggested by the community are really good, now it depends on your business requirement on what is the end objective.

 

you can combine @Mohit_KBansal  @manjunathdj suggested way  to achieve pretty much all the permutations