I want to provide download button feature in Content Fragment | Community
Skip to main content
Level 2
January 3, 2023
Solved

I want to provide download button feature in Content Fragment

  • January 3, 2023
  • 2 replies
  • 1991 views

Hey 

 Hi I want to   provide download button feature in Content Fragment 

Pls provide Any Suggestions on it 

Thanks in Advance

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Siva_Sogalapalli

I don't think so you can achieve this using CF, but you can achieve this using experience fragments, for that you need to create the component based on your requirement where you have control to design the component the way you want and create experience fragment using the component, then refer the XF on page. 

Content Fragments are better fit to expose the data as it is in multiple pages or expose data as API. 

Please explore XF documentation as well and see if that helps.

https://experienceleague.adobe.com/docs/experience-manager-learn/sites/experience-fragments/experience-fragments-feature-video-use.html?lang=en 

2 replies

Siva_Sogalapalli
Community Advisor
Community Advisor
January 3, 2023

If you go to content fragment models localhost:4502/assets.html/content/dam/content-fragments page and select CF, then you can find option to download entire content fragment itself. Please try that and see if that meets your requirement.

Ref: 

 

SYED1111Author
Level 2
January 3, 2023

I want make download that image when we click on download feture  .in content fragment

 

Siva_Sogalapalli
Community Advisor
Siva_SogalapalliCommunity AdvisorAccepted solution
Community Advisor
January 3, 2023

I don't think so you can achieve this using CF, but you can achieve this using experience fragments, for that you need to create the component based on your requirement where you have control to design the component the way you want and create experience fragment using the component, then refer the XF on page. 

Content Fragments are better fit to expose the data as it is in multiple pages or expose data as API. 

Please explore XF documentation as well and see if that helps.

https://experienceleague.adobe.com/docs/experience-manager-learn/sites/experience-fragments/experience-fragments-feature-video-use.html?lang=en 

Umesh_Thakur
Community Advisor
Community Advisor
January 4, 2023

@syed1111 , can you please tell me how you are using content fragment on the  page, thru any custome component, which is having cf picker filed, or exposing CFs data to any UI to generate the look and feel?

In first scenario(in case of custom component) you can write HTML logic in sightly to have the feature to make the PDF or image downloadable.

In second scenario(exposing cfs data to some UI like React or Angular or any other stuff) here you can write your downloadable logic to accomplish your requirement.

but any how you need to do it on front-end(HTML or JS) only as far as I know.

Hope this helps.

Umesh Thakur