aboutsummaryrefslogtreecommitdiff
path: root/docs/net.md
diff options
context:
space:
mode:
authoramelia squires <[email protected]>2024-09-30 11:13:49 -0500
committeramelia squires <[email protected]>2024-09-30 11:13:49 -0500
commit31a3a9ed59b720527975341931ebc4111fe23c78 (patch)
treef8f73457a0cd1c96191c829843d01dfdbb8138ca /docs/net.md
parent2a8f9bb657b323711b90bd183854d2bb46aee6e1 (diff)
attatchments
Diffstat (limited to 'docs/net.md')
-rw-r--r--docs/net.md8
1 files changed, 8 insertions, 0 deletions
diff --git a/docs/net.md b/docs/net.md
index 0807c72..9c841b3 100644
--- a/docs/net.md
+++ b/docs/net.md
@@ -158,6 +158,14 @@ res.header["test"] = "wowa"
res.header["Content-Type"] is set automatically depending on the file extention, using /etc/mime.types, or whatever option was supplied to listen (see listen options)
+option table
+
+|key|value|effect|
+|--|--|--|
+|attatchment|boolean, default false|whether or not to add Content-Disposition (if file will be downloaded)|
+|filename|string, defualts as the first argument|what the client should see as a filename (only when attatchment is true)|
+
+
```lua
...
res:sendfile("./html/index.html")