A simple question about Servlet versus Websocket, maybe stupid.
What corresponds to the ServletResponse. (Resp.write) in Websocket?
Sub Handle(req AsServletRequest, resp AsServletResponse)
Dim shl AsShell
shl.Initialize( "shl", "c:\php\php.exe", ArrayAsString("getalbumpics.php","?ID=Start"))
shl.WorkingDirectory = "E:\Program\B4J\Server\AppServer\Objects\www\php\images"
Dim res AsShellSyncResult = shl.RunSynchronous(10000)
Resp.Write(res.StdOut) ‘Works fine!
EndSub
How do you do Resp.write in Wbesocket or is it impossible?
PrivateSub WebSocket_Connected (WebSocket1 AsWebSocket)
ws = WebSocket1
Dim shl AsShell
shl.Initialize( "shl", "c:\php\php.exe", ArrayAsString("getalbumpics.php","?ID=Start"))
shl.WorkingDirectory = "E:\Program\B4J\Server\AppServer\Objects\www\php\images"
Dim res AsShellSyncResult = shl.RunSynchronous(10000)
ws.What ??? something like ws.write (res.StdOut)
ws.Flush
EndSub
What corresponds to the ServletResponse. (Resp.write) in Websocket?
Sub Handle(req AsServletRequest, resp AsServletResponse)
Dim shl AsShell
shl.Initialize( "shl", "c:\php\php.exe", ArrayAsString("getalbumpics.php","?ID=Start"))
shl.WorkingDirectory = "E:\Program\B4J\Server\AppServer\Objects\www\php\images"
Dim res AsShellSyncResult = shl.RunSynchronous(10000)
Resp.Write(res.StdOut) ‘Works fine!
EndSub
How do you do Resp.write in Wbesocket or is it impossible?
PrivateSub WebSocket_Connected (WebSocket1 AsWebSocket)
ws = WebSocket1
Dim shl AsShell
shl.Initialize( "shl", "c:\php\php.exe", ArrayAsString("getalbumpics.php","?ID=Start"))
shl.WorkingDirectory = "E:\Program\B4J\Server\AppServer\Objects\www\php\images"
Dim res AsShellSyncResult = shl.RunSynchronous(10000)
ws.What ??? something like ws.write (res.StdOut)
ws.Flush
EndSub