[WebDNA] lighttpd problem with returnraw http header
This WebDNA talk-list message is from 2018
It keeps the original formatting.
numero = 113970
interpreted = N
texte = 1570--Apple-Mail=_941D3ED2-A177-40FA-B61A-7A8C0C7BEE45Content-Transfer-Encoding: quoted-printableContent-Type: text/plain;charset=utf-8Hi everybody,We use lighttpd with webdna 8.We have set server.error_handler_404 =3D =E2=80=9Cdispatch.dna=E2=80=9D =- Now all request go to dispatch.dna (except static files (images, css, =js,=E2=80=A6))In dispatch.dna webdna looks up [thisurl] in the database (and does lots =of other stuff) and decides which HTTP response to return =(200,401,404,301,302,=E2=80=A6) with returnraw (see code below).It has all worked fine till lighttpd 1.4.45, now with 1.4.46 something =changed:Now it works kinda for 404,301,302.It does not with 200 (I get 2 headers in the http response, only the =first is used, the second is shown as plain text, but then the =content-length is not correct=E2=80=A6 - idk).Also 401: The server answers with a 401 but does not deliver my =html-error-page but delivers the standard html =E2=80=9C401 - =Unauthorized=E2=80=9D...Do you have the same problem? Is it a bug, or it just now works like =this? Ist there any =E2=80=9Cfix=E2=80=9D on the horizon for webdna or =is it a lighttpd-thing?ThanksNoah[text show=3Df]CRLF=3D[unurl]%0D%0A[/unurl][/text][!][/!][function name=3DShow301][!][/!][returnraw][!][/!]]result=3DHTTP/1.1 301 Moved Permanently[CRLF][!][/!]Location: https://google.com[CRLF][CRLF][!][/!][/returnraw][!][/!][/function][!][/!][function name=3DShow302][!][/!][returnraw][!][/!]result=3D HTTP/1.1 302 Found[CRLF][!][/!]Location: https://google.com[CRLF][CRLF][/!][/returnraw][!][/!][/function][!][/!][function name=3D Show404][!][/!][returnraw][!][/!]Status: 404 Not Found[CRLF][!][/!]Content-type: text/html[CRLF][CRLF][!][/!][include file=3Derror_page.inc][!][/!][/returnraw][!][/!][/function][!][/!][function name=3D Show401][!][/!][returnraw][/!]HTTP/1.1 401 Unauthorized[CRLF][!][/!]Content-type: text/html[CRLF][CRLF][!][/!][include file=3Dlogin_page.inc][!][/!][/returnraw][!][/!][/function][!][/!][function name=3D Show200][!][/!][returnraw][!][/!]HTTP/1.1 200 OK[CRLF][!][/!]Status: OK[CRLF][!][/!]Set-Cookie:mycookie=3Dcookievalue;Path=3D/[CRLF][!][/!]Content-type: text/html[CRLF][CRLF][!][/!][include file=3Dcontent_page.inc][!][/!][/returnraw][!][/!][/function]---------------------------------------------------------This message is sent to you because you are subscribed tothe mailing list talk@webdna.usTo unsubscribe, E-mail to: talk-leave@webdna.usarchives: http://www.webdna.us/page.dna?numero=3D55Bug Reporting: support@webdna.us--Apple-Mail=_941D3ED2-A177-40FA-B61A-7A8C0C7BEE45Content-Transfer-Encoding: quoted-printableContent-Type: text/html;charset=utf-8
Hi everybody,
We use lighttpd with webdna =8.
We have =set server.error_handler_404 =3D =E2=80=9Cdispatch.dna=E2=80=9D - =Now all request go to dispatch.dna (except static files (images, css, =js,=E2=80=A6))
In dispatch.dna webdna looks up [thisurl] in the =database (and does lots of other stuff) and decides which HTTP response =to return (200,401,404,301,302,=E2=80=A6) with returnraw (see code =below).
It has all =worked fine till lighttpd 1.4.45, now with 1.4.46 something =changed:
Now it works =kinda for 404,301,302.
It =does not with 200 (I get 2 headers in the http response, only the first =is used, the second is shown as plain text, but then the content-length =is not correct=E2=80=A6 - idk).
Also 401: The server answers with a 401 but does not deliver =my html-error-page but delivers the standard html =E2=80=9C401 - =Unauthorized=E2=80=9D...
Do you have the same problem? Is it a bug, or it just now =works like this? Ist there any =E2=80=9Cfix=E2=80=9D on the horizon for =webdna or is it a lighttpd-thing?
Thanks
Noah
[text =show=3Df]CRLF=3D[unurl]%0D%0A[/unurl][/text][!]
[/!][function name=3DShow301][!]
=[/!][returnraw][!]
[/!]]result=3DHTTP/1.1 =301 Moved Permanently[CRLF][!]
[/!][/returnraw][!]
[/!][/function][!]
[/!][function name=3DShow302][!]
=[/!][returnraw][!]
=[/!]result=3D HTTP/1.1 302 Found[CRLF][!]
=[/!][/returnraw][!]
[/!][/function][!]
[/!][function name=3D Show404][!]
=[/!][returnraw][!]
=[/!]Status: 404 Not Found[CRLF][!]
[/!]Content-type: =text/html[CRLF][CRLF][!]
=[/!][include =file=3Derror_page.inc][!][/!][/returnraw][!][/!][/function][!][/!][function =name=3D Show401][!]=[/!][returnraw]
[/!]HTTP/1.1 401 =Unauthorized[CRLF][!][/!]Content-type: =text/html[CRLF][CRLF][!]
=[/!][include file=3Dlogin_page.inc][!]
=[/!][/returnraw][!] [/!][/function][!]
[/!][function =name=3D Show200][!][/!][returnraw][!][/!]HTTP/1.1 200 OK[CRLF][!][/!]Status: OK[CRLF][!][/!]Set-Cookie:mycookie=3Dcookievalue;Path=3D/[CRLF][!][/!]Content-type: =text/html[CRLF][CRLF][!]=[/!][include file=3Dcontent_page.inc][!]
[/!][/returnraw][!][/!][/function] =--Apple-Mail=_941D3ED2-A177-40FA-B61A-7A8C0C7BEE45--.
Associated Messages, from the most recent to the oldest:
1570--Apple-Mail=_941D3ED2-A177-40FA-B61A-7A8C0C7BEE45Content-Transfer-Encoding: quoted-printableContent-Type: text/plain;charset=utf-8Hi everybody,We use lighttpd with webdna 8.We have set server.error_handler_404 =3D =E2=80=9Cdispatch.dna=E2=80=9D =- Now all request go to dispatch.dna (except static files (images, css, =js,=E2=80=A6))In dispatch.dna webdna looks up
[thisurl] in the database (and does lots =of other stuff) and decides which HTTP response to return =(200,401,404,301,302,=E2=80=A6) with returnraw (see code below).It has all worked fine till lighttpd 1.4.45, now with 1.4.46 something =changed:Now it works kinda for 404,301,302.It does not with 200 (I get 2 headers in the http response, only the =first is used, the second is shown as plain text, but then the =content-length is not correct=E2=80=A6 - idk).Also 401: The server answers with a 401 but does not deliver my =html-error-page but delivers the standard html =E2=80=9C401 - =Unauthorized=E2=80=9D...Do you have the same problem? Is it a bug, or it just now works like =this? Ist there any =E2=80=9Cfix=E2=80=9D on the horizon for webdna or =is it a lighttpd-thing?ThanksNoah[text show=3Df]CRLF=3D
[unurl]%0D%0A[/unurl][/text]
[!][/!][function name=3DShow301]
[!][/!]
[returnraw][!][/!]]result=3DHTTP/1.1 301 Moved Permanently[CRLF]
[!][/!]Location: https://google.com[CRLF][CRLF]
[!][/!][/returnraw]
[!][/!][/function]
[!][/!][function name=3DShow302]
[!][/!]
[returnraw][!][/!]result=3D HTTP/1.1 302 Found[CRLF]
[!][/!]Location: https://google.com[CRLF][CRLF][/!][/returnraw]
[!][/!][/function]
[!][/!][function name=3D Show404]
[!][/!]
[returnraw][!][/!]Status: 404 Not Found[CRLF]
[!][/!]Content-type: text/html[CRLF][CRLF]
[!][/!][include file=3Derror_page.inc]
[!][/!][/returnraw]
[!][/!][/function]
[!][/!][function name=3D Show401]
[!][/!]
[returnraw][/!]HTTP/1.1 401 Unauthorized[CRLF]
[!][/!]Content-type: text/html[CRLF][CRLF]
[!][/!][include file=3Dlogin_page.inc]
[!][/!][/returnraw]
[!][/!][/function]
[!][/!][function name=3D Show200]
[!][/!]
[returnraw][!][/!]HTTP/1.1 200 OK[CRLF]
[!][/!]Status: OK[CRLF]
[!][/!]Set-Cookie:mycookie=3Dcookievalue;Path=3D/[CRLF]
[!][/!]Content-type: text/html[CRLF][CRLF]
[!][/!][include file=3Dcontent_page.inc]
[!][/!][/returnraw]
[!][/!][/function]---------------------------------------------------------This message is sent to you because you are subscribed tothe mailing list talk@webdna.usTo unsubscribe, E-mail to: talk-leave@webdna.usarchives: http://www.webdna.us/page.dna?numero=3D55Bug Reporting: support@webdna.us--Apple-Mail=_941D3ED2-A177-40FA-B61A-7A8C0C7BEE45Content-Transfer-Encoding: quoted-printableContent-Type: text/html;charset=utf-8
Hi everybody,
We use lighttpd with webdna =8.
We have =set server.error_handler_404 =3D =E2=80=9Cdispatch.dna=E2=80=9D - =Now all request go to dispatch.dna (except static files (images, css, =js,=E2=80=A6))
In dispatch.dna webdna looks up
[thisurl] in the =database (and does lots of other stuff) and decides which HTTP response =to return (200,401,404,301,302,=E2=80=A6) with returnraw (see code =below).
It has all =worked fine till lighttpd 1.4.45, now with 1.4.46 something =changed:
Now it works =kinda for 404,301,302.
It =does not with 200 (I get 2 headers in the http response, only the first =is used, the second is shown as plain text, but then the content-length =is not correct=E2=80=A6 - idk).
Also 401: The server answers with a 401 but does not deliver =my html-error-page but delivers the standard html =E2=80=9C401 - =Unauthorized=E2=80=9D...
Do you have the same problem? Is it a bug, or it just now =works like this? Ist there any =E2=80=9Cfix=E2=80=9D on the horizon for =webdna or is it a lighttpd-thing?
Thanks
Noah
[text =show=3Df]CRLF=3D
[unurl]%0D%0A[/unurl][/text]
[!][/!][function name=3DShow301]
[!][/!]]result=3DHTTP/1.1 =301 Moved Permanently[CRLF]
[!][/!][/function]
[!][/!][function name=3DShow302]
[!]=[/!]result=3D HTTP/1.1 302 Found[CRLF]
[!] [/!][/function]
[!][/!][function name=3D Show404]
[!]=[/!]
[returnraw][!]=[/!]Status: 404 Not Found[CRLF]
[!] [/!]Content-type: =text/html[CRLF][CRLF]
[!]=[/!][include =file=3Derror_page.inc][!][/!][/returnraw][!][/!][/function][!][/!][function =name=3D Show401][!][/!]HTTP/1.1 401 =Unauthorized[CRLF][!][/!]Content-type: =text/html[CRLF][CRLF]
[!]=[/!][include file=3Dlogin_page.inc]
[!] =[/!][/returnraw][!] [/!][function =name=3D Show200][!][/!][returnraw][!][/!]HTTP/1.1 200 OK[CRLF][!][/!]Status: OK[CRLF][!][/!]Set-Cookie:mycookie=3Dcookievalue;Path=3D/[CRLF][!][/!]Content-type: =text/html[CRLF][CRLF][!]=[/!][include file=3Dcontent_page.inc]
[!] [/!][/returnraw][!][/!][/function] =--Apple-Mail=_941D3ED2-A177-40FA-B61A-7A8C0C7BEE45--.
Noah Valley
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
Emailer or [sendmail] questions ... (1998)
WebCat templates for TyphoonPro admin (1999)
[WebDNA] SSD's and second disk (2017)
RE: creating writefile data from a nested search (1997)
[sendmail] sending twice... (Update) (2003)
Sort Order on a page search (1997)
WC2.0 Memory Requirements (1997)
oops private message leaked into talk list (1997)
[OT] Site test... (2003)
Word search (1997)
WebCatalog for Postcards ? (1997)
More Applescript (1997)
WebCommerce: Folder organization ? (1997)
Date Help! (2003)
Automatic POST arg sending? (1998)
Line items in table cells (1997)
Search Result refinement help (2003)
More on the email templates (I like it) (1997)
mac hack (1997)
Repeating Fields (1997)