Re: Set folder Permissions - WeOnlyDo Discussion board

Re: Set folder Permissions (General questions)

by wodDamir, Saturday, September 19, 2009, 12:36 (5332 days ago) @ Brian Henry

Brian,

Here is what I did in RequestDone event of our VB 2. Simple - manual response sample:

[code]Dim resp As String

If (Args.Request.PageName = index.htm ) Then
resp = <HTML><font face=Verdana size=2>Welcome visitor from
resp = resp & Args.User.RemoteIP & . This is <b>wodWebServer.NET</b>, version & web1.Version
resp = resp & <BR>You requested resource & Args.User.Request.Path & Args.User.Request.PageName
resp = resp & </font></HTML>
Args.User.Response.Body = resp

' don't forget to set status code and content type
Args.User.Response.Headers( Content-Type ).Value = text/html
Args.User.Response.StatusCode = WeOnlyDo.Server.StatusCodes.OK
Else
Args.User.CreateErrorResponse(404, Unauthorized , You aren't authorized to access the requested resource. )
End If[/code]

The above code shows the page if you enter http://127.0.0.1/index.htm in your browser. Otherwise it will display the error page saying that access is restricted.

Can you try the same?

Regards,
Damba


Complete thread: