davidak
(davidak)
July 16, 2016, 11:19pm
1
Caddyfile :
redir /blog/wp-content/uploads/2010/12/Bildschirmfoto-2010-12-14-um-19.47.29-1024x640.png /images/celtx_auf_osx_wortspiele_polysemia.thumbnail.png
Error:
caddy[8444]: 2016/07/17 00:57:32 Caddyfile:23 - Parse error: Invalid redirect code '/images/celtx_auf_osx_wortspiele_polysemia.thumbnail.png'
when i understand the example right that should work.
what am i doing wrong?
davidak
(davidak)
July 17, 2016, 12:08am
2
I fixed it by only using the redir directive once but with multiple urls.
matt
(Matt Holt)
July 17, 2016, 6:25am
3
You’re missing the redirect code; the example uses 307.
davidak
(davidak)
July 17, 2016, 2:28pm
4
Default is 301 Moved Permanently.
and that is what i want. in what case do i have to set it explicitly?
matt
(Matt Holt)
July 17, 2016, 6:06pm
5
Oh, umm maybe that’s not true for the table form. I’ll double check and make the fix.
matt
(Matt Holt)
July 19, 2016, 12:32am
6
Okay, so actually this isn’t a bug; using this format: redir from to code
, all 3 values are required. This is still correct in the docs because the code
parameter doesn’t have those optional [ ]
brackets around it. The default code is still 301, but only when the syntax allows it to be omitted.
I’ll try to clear that up in the docs.
1 Like
system
(system)
Closed
October 17, 2016, 12:32am
7
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.