• sonam singh 22
  • NEWBIE
  • 0 Points
  • Member since 2017

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies
I have a lightning component that I'm putting on a Community page, and I want to place a download link on it - to download an attachment.

In Visualforce - I always did...
<apex:image value="/servlet/servlet.FileDownload?file={!attachmentId}"  />Download</apex:image>

So, in the markup of the component, I've tried
<a href="{!'/servlet/servlet.FileDownload?file=00P4D000000Oub6'}">Download</a>

But when I do this, and click on the link - it just's takes me to a Site is in Maintenance message. 

Has anybody done a download link of an attachment ID in a componet?

Thanks