HTML (Hyper Text Markup Language) is a format that implies using a web browser. But if you want to create hyperlinks that open files other than HTML documents, use Insert, Hyperlink, Document (left side of the dialog box), and enter the file's name in the Document Path field (or use the Open File button to its right). In these cases, checking the force download box has no effect. If the resource is a PDF file (stored in Moodle or on a different site), the force download box should be checked in order that students using IE7 or Firefox 3.x can view the PDF. This work-around is necessary because of the way browser handles PDF files. Visualforce page render as pdf example. We can render any page as pdf by adding renderAs attribute to
The download attribute also triggers a force download, something that I used to do on the server side with PHP. View Demo This attribute is extremely useful in cases where generated files are in use -- the file name on the server side needs to be incredibly unique, but the download attribute allows the file name to be meaningful to user.