-
Notifications
You must be signed in to change notification settings - Fork 234
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #516 from wedge-jarrad/download-link-example
Add download link example
- Loading branch information
Showing
3 changed files
with
30 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Download Links | ||
|
||
## Overview | ||
|
||
This page shows how you can create a link that will cause a file to be | ||
downloaded when clicked. | ||
|
||
## Example | ||
|
||
Here is an example: | ||
|
||
[Hello world code sample](./files/sample1.py){: download="hello.py"} | ||
|
||
## Markdown | ||
|
||
Here is the Markdown: | ||
|
||
```MD | ||
[Hello world code sample](./files/sample1.py){: download="hello.py"} | ||
``` | ||
|
||
Note that the name specified after `download=` is the name the file will be | ||
given when it is downloaded. This does not need to be the same as the name of | ||
the file on the server side. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/usr/bin/env python | ||
# vim: ts=4 sw=4 et | ||
|
||
if __name__ == '__main__': | ||
print('Hello world!') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters