Changeset 88
- Timestamp:
- Dec 18, 2009, 12:21:39 PM (15 years ago)
- Location:
- branches/DirectWeb
- Files:
-
- 3 added
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/DirectWeb/UHTTPServer.pas
r87 r88 10 10 11 11 type 12 THTTPServer = class; 12 13 13 14 TQueryParameterList = class(TStringList) … … 28 29 Query: TQueryParameterList; 29 30 Path: string; 30 Host: string;31 31 Method: string; 32 32 Headers: TStringList; … … 47 47 end; 48 48 49 TRequestEvent = procedure(Request: THTTPRequest; Response: THTTPResponse) of object; 49 { THTTPHandlerData } 50 51 THTTPHandlerData = class 52 Server: THTTPServer; 53 Request: THTTPRequest; 54 Response: THTTPResponse; 55 SessionId: string; 56 Session: TStringList; 57 constructor Create; 58 destructor Destroy; override; 59 end; 60 61 TRequestEvent = procedure(HandlerData: THTTPHandlerData) of object; 50 62 51 63 TRequestHandler = class … … 63 75 { THTTPSession } 64 76 65 THTTPSession = class 66 Variables: TStringList; 67 procedure Load(Request: THTTPRequest); virtual; 68 procedure Save(Response: THTTPResponse); virtual; 77 { THTTPSessionStorage } 78 79 THTTPSessionStorage = class 80 procedure Load(HandlerData: THTTPHandlerData); virtual; 81 procedure Save(HandlerData: THTTPHandlerData); virtual; 69 82 constructor Create; virtual; 70 83 destructor Destroy; override; … … 76 89 private 77 90 procedure HandleClient(Sender: TObject); 78 procedure ErrorResponse( Request: THTTPRequest; Response: THTTPResponse);91 procedure ErrorResponse(HandlerData: THTTPHandlerData); 79 92 public 80 93 Name: string; … … 83 96 MaxConnection: Integer; 84 97 RequestHandlerList: TRequestHandlerList; 85 SessionHandler: THTTPSession; 86 procedure FileResponse(Request: THTTPRequest; 87 Response: THTTPResponse); 98 SessionStorage: THTTPSessionStorage; 99 procedure FileResponse(HandlerData: THTTPHandlerData); 88 100 constructor Create; 89 101 destructor Destroy; override; … … 100 112 LineIndex: Integer; 101 113 LineParts: array of string; 102 Request: THTTPRequest; 103 Response: THTTPResponse; 114 HandlerData: THTTPHandlerData; 104 115 I: Integer; 105 116 QueryString: string; 106 117 begin 107 118 with TTCPClientThread(Sender), Socket do begin 108 WriteLn('Client ' + IntToStr(Parent.IndexOf(Sender)) + ' connected from ' + GetRemoteSinIP); 119 WriteLn('Used thrads ' + IntToStr(Parent.ThreadPool.UsedCount) + '. Client connected from ' + GetRemoteSinIP); 120 121 HandlerData := THTTPHandlerData.Create; 122 with HandlerData do begin 123 Server := Self; 109 124 110 125 Response := THTTPResponse.Create; … … 128 143 LineParts[0] := Copy(LineParts[0], 1, Length(LineParts[0]) - 1); 129 144 Request.Headers.Values[LineParts[0]] := LineParts[1]; 130 WriteLn(Line);145 //WriteLn(Line); 131 146 end; 132 147 end; … … 138 153 Request.Cookies.Parse(Request.Headers.Values['Cookie']); 139 154 140 // Process session141 if Assigned(Session Handler) then142 Session Handler.Load(Request);155 // Load session variables 156 if Assigned(SessionStorage) then 157 SessionStorage.Load(HandlerData); 143 158 144 159 Response.Stream.Clear; … … 148 163 RequestHandler := RequestHandlerList.IndexOfName(Request.Path); 149 164 150 if Assigned(RequestHandler) then RequestHandler.Handler(Request, Response) 151 else ErrorResponse(Request, Response); 152 153 if Assigned(SessionHandler) then 154 SessionHandler.Save(Response); 165 if Assigned(RequestHandler) then RequestHandler.Handler(HandlerData) 166 else ErrorResponse(HandlerData); 167 168 // Store session variables 169 if Assigned(SessionStorage) then 170 SessionStorage.Save(HandlerData); 155 171 156 172 with Response do begin … … 167 183 // Send headers 168 184 for I := 0 to Headers.Count - 1 do begin 169 WriteLn(Headers.Names[I] + ': ' + Headers.ValueFromIndex[I] + #13#10);185 //WriteLn(Headers.Names[I] + ': ' + Headers.ValueFromIndex[I] + #13#10); 170 186 SendString(Headers.Names[I] + ': ' + Headers.ValueFromIndex[I] + #13#10); 171 187 end; … … 175 191 end; 176 192 177 Request.Destroy; 178 Response.Destroy; 179 end; 180 end; 181 182 procedure THTTPServer.ErrorResponse(Request: THTTPRequest; 183 Response: THTTPResponse); 184 begin 185 with Response.Stream do begin 193 Destroy; 194 end; 195 end; 196 end; 197 198 procedure THTTPServer.ErrorResponse(HandlerData: THTTPHandlerData); 199 begin 200 with HandlerData, Response.Stream do begin 186 201 WriteString('<html><body>Page ' + Request.Path + ' not found.</body></html>'); 187 202 end; 188 203 end; 189 204 190 procedure THTTPServer.FileResponse(Request: THTTPRequest; 191 Response: THTTPResponse); 205 procedure THTTPServer.FileResponse(HandlerData: THTTPHandlerData); 192 206 var 193 207 BinaryFile: TFileStream; 194 208 FileName: string; 195 209 begin 196 FileName := DocumentRoot + Request.Path; 197 if FileExists(FileName) then begin 198 Response.Headers.Values['Content-Type'] := GetMIMEType(Copy(ExtractFileExt(FileName), 2, 255)); 199 BinaryFile := TFileStream.Create(FileName, fmOpenRead); 200 Response.Stream.WriteStream(BinaryFile); 201 BinaryFile.Destroy; 202 end else 203 with Response.Stream do begin 204 WriteLn('File ' + Request.Path + ' not found.'); 205 WriteString('<html><body>File ' + Request.Path + ' not found.</body></html>'); 210 with HandlerData do begin 211 FileName := DocumentRoot + Request.Path; 212 if FileExists(FileName) then begin 213 Response.Headers.Values['Content-Type'] := GetMIMEType(Copy(ExtractFileExt(FileName), 2, 255)); 214 BinaryFile := TFileStream.Create(FileName, fmOpenRead); 215 Response.Stream.WriteStream(BinaryFile); 216 BinaryFile.Destroy; 217 end else 218 with Response.Stream do begin 219 WriteLn('File ' + Request.Path + ' not found.'); 220 WriteString('<html><body>File ' + Request.Path + ' not found.</body></html>'); 221 end; 206 222 end; 207 223 end; … … 329 345 end; 330 346 331 { THTTPSession } 332 333 procedure THTTPSession.Load(Request: THTTPRequest); 334 begin 335 336 end; 337 338 procedure THTTPSession.Save(Response: THTTPResponse); 339 begin 340 341 end; 342 343 constructor THTTPSession.Create; 344 begin 345 Variables := TStringList.Create; 346 end; 347 348 destructor THTTPSession.Destroy; 349 begin 350 Variables.Destroy; 347 { THTTPSessionStorage } 348 349 procedure THTTPSessionStorage.Load(HandlerData: THTTPHandlerData); 350 begin 351 352 end; 353 354 procedure THTTPSessionStorage.Save(HandlerData: THTTPHandlerData); 355 begin 356 357 end; 358 359 constructor THTTPSessionStorage.Create; 360 begin 361 362 end; 363 364 destructor THTTPSessionStorage.Destroy; 365 begin 366 inherited Destroy; 367 end; 368 369 { THTTPHandlerData } 370 371 constructor THTTPHandlerData.Create; 372 begin 373 Request := THTTPRequest.Create; 374 Response := THTTPResponse.Create; 375 Session := TStringList.Create; 376 end; 377 378 destructor THTTPHandlerData.Destroy; 379 begin 380 Request.Destroy; 381 Response.Destroy; 382 Session.Destroy; 351 383 inherited Destroy; 352 384 end; -
branches/DirectWeb/UHTTPSessionFile.pas
r87 r88 6 6 7 7 uses 8 Classes, SysUtils, UHTTPServer ;8 Classes, SysUtils, UHTTPServer, syncobjs; 9 9 10 type 10 type 11 11 12 { T HTTPSessionFile }12 { TFileHTTPSessionStorage } 13 13 14 THTTPSessionFile = class(THTTPSession) 14 TFileHTTPSessionStorage = class(THTTPSessionStorage) 15 private 16 Lock: TCriticalSection; 17 procedure GetSessionId(HandlerData: THTTPHandlerData); 18 public 15 19 Directory: string; 16 20 SessionIdCookieName: string; 17 Session Id: string;18 procedure Load( Request: THTTPRequest); override;19 procedure Save( Response: THTTPResponse); override;21 Sessions: TStringList; 22 procedure Load(HandlerData: THTTPHandlerData); override; 23 procedure Save(HandlerData: THTTPHandlerData); override; 20 24 constructor Create; override; 21 25 destructor Destroy; override; … … 26 30 { THTTPSession } 27 31 28 procedure T HTTPSessionFile.Load(Request: THTTPRequest);32 procedure TFileHTTPSessionStorage.GetSessionId(HandlerData: THTTPHandlerData); 29 33 begin 34 with HandlerData do 30 35 if Request.Cookies.IndexOfName(SessionIdCookieName) <> -1 then begin 31 SessionId := Request.Cookies.Values[SessionIdCookieName]; 32 end else begin 33 SessionId := IntToStr(Random(1000)); 34 // TODO: Check if new id already used 36 SessionId := Request.Cookies.Values[SessionIdCookieName]; 37 end else begin 38 SessionId := IntToStr(Random(2000000000)); 39 // TODO: Check if new id already used 40 end; 41 end; 42 43 procedure TFileHTTPSessionStorage.Load(HandlerData: THTTPHandlerData); 44 var 45 SessionFile: string; 46 begin 47 GetSessionId(HandlerData); 48 try 49 Lock.Acquire; 50 SessionFile := Directory + '/' + HandlerData.SessionId; 51 if FileExists(SessionFile) then 52 HandlerData.Session.LoadFromFile(SessionFile); 53 finally 54 Lock.Release; 35 55 end; 36 37 if FileExists(Directory + '/' + SessionId) then38 Variables.LoadFromFile(Directory + '/' + SessionId);39 56 inherited; 40 57 end; 41 58 42 procedure THTTPSessionFile.Save(Response: THTTPResponse); 59 procedure TFileHTTPSessionStorage.Save(HandlerData: THTTPHandlerData); 60 var 61 SessionFile: string; 43 62 begin 44 ForceDirectories(Directory); 45 if DirectoryExists(Directory) then 46 Variables.SaveToFile(Directory + '/' + SessionId) 47 else raise Exception.Create('Can''t create session storage directory.'); 63 try 64 Lock.Acquire; 65 SessionFile := Directory + '/' + HandlerData.SessionId; 66 ForceDirectories(Directory); 67 if DirectoryExists(Directory) then begin 68 DeleteFile(SessionFile); 69 HandlerData.Session.SaveToFile(SessionFile) 70 end else raise Exception.Create('Can''t create session storage directory.'); 48 71 49 Response.Cookies.Values[SessionIdCookieName] := SessionId; 50 inherited Save(Response); 72 HandlerData.Response.Cookies.Values[SessionIdCookieName] := HandlerData.SessionId; 73 finally 74 Lock.Release; 75 end; 76 inherited; 51 77 end; 52 78 53 constructor T HTTPSessionFile.Create;79 constructor TFileHTTPSessionStorage.Create; 54 80 begin 55 inherited; 81 inherited Create; 82 Lock := TCriticalSection.Create; 83 Sessions := TStringList.Create; 56 84 SessionIdCookieName := 'SessionId'; 57 85 Directory := 'Session'; 58 86 end; 59 87 60 destructor T HTTPSessionFile.Destroy;88 destructor TFileHTTPSessionStorage.Destroy; 61 89 begin 90 Sessions.Destroy; 91 Lock.Destroy; 62 92 inherited Destroy; 63 93 end; -
branches/DirectWeb/UTCPServer.pas
r84 r88 13 13 //LibC, 14 14 {$ENDIF} 15 BlckSock ;15 BlckSock, UPool, UResetableThread; 16 16 17 17 type 18 18 TTCPServer = class; 19 TTCPClientList = class;20 19 21 20 { TTCPClientThread } 22 21 23 TTCPClientThread = class(T Thread)24 Parent: TTCP ClientList;22 TTCPClientThread = class(TResetableThread) 23 Parent: TTCPServer; 25 24 Socket: TTCPBlockSocket; 26 25 procedure Execute; override; 27 constructor Create(CreateSuspended: Boolean; 28 const StackSize: SizeUInt = DefaultStackSize); 26 constructor Create; 29 27 destructor Destroy; override; 28 end; 29 30 { TClientThreadedPool } 31 32 TClientThreadedPool = class(TThreadedPool) 33 private 34 FActive: Boolean; 35 procedure SetActive(const AValue: Boolean); 36 public 37 property Active: Boolean read FActive write SetActive; 30 38 end; 31 39 … … 35 43 Parent: TTCPServer; 36 44 procedure Execute; override; 37 end;38 39 { TTCPClientList }40 41 TTCPClientList = class(TList)42 Parent: TTCPServer;43 procedure Add(ASocket: TSocket);44 procedure Remove(Item: TTCPClientThread);45 procedure Terminate;46 procedure WaitFor;47 constructor Create;48 destructor Destroy; override;49 45 end; 50 46 … … 59 55 procedure SetActive(const AValue: Boolean); 60 56 public 61 Clients: TTCPClientList;57 ThreadPool: TClientThreadedPool; 62 58 Address: string; 63 59 Port: Word; … … 77 73 if AValue and not FActive then begin 78 74 with Socket do begin 75 ThreadPool.Active := True; 79 76 CreateSocket; 80 77 SetLinger(True, 10); … … 96 93 AcceptThread.WaitFor; 97 94 AcceptThread.Destroy; 98 Clients.Terminate; 99 Clients.WaitFor; 95 ThreadPool.Active := False; 100 96 CloseSocket; 101 97 end; … … 105 101 106 102 constructor TTCPServer.Create; 103 var 104 I: Integer; 107 105 begin 108 Clients := TTCPClientList.Create; 109 Clients.Parent := Self; 106 ThreadPool := TClientThreadedPool.Create; 107 ThreadPool.TotalCount := 10; 108 110 109 Socket := TTCPBlockSocket.Create; 111 110 Address := '0.0.0.0'; … … 115 114 destructor TTCPServer.Destroy; 116 115 begin 116 ThreadPool.Destroy; 117 117 Active := False; 118 118 Socket.Destroy; 119 Clients.Destroy;120 119 inherited Destroy; 121 120 end; … … 126 125 var 127 126 NewSocket: TSocket; 127 NewObject: TTCPClientThread; 128 128 begin 129 129 repeat … … 131 131 NewSocket := Parent.Socket.Accept; 132 132 if Parent.Socket.LastError = 0 then begin 133 Parent.Clients.Add(NewSocket); 133 NewObject := TTCPClientThread(Parent.ThreadPool.Acquire); 134 NewObject.Parent := Parent; 135 NewObject.Socket.Socket := NewSocket; 136 NewObject.Start; 134 137 end; 135 138 end; 136 139 until Terminated; 137 end;138 139 { TTCPClientList }140 141 procedure TTCPClientList.Add(ASocket: TSocket);142 begin143 with TTCPClientThread(Items[inherited Add(TTCPClientThread.Create(True))]) do begin144 Socket.Socket := ASocket;145 Parent := Self;146 Resume;147 end;148 end;149 150 procedure TTCPClientList.Remove(Item: TTCPClientThread);151 begin152 inherited Remove(Item);153 Item.Destroy;154 end;155 156 procedure TTCPClientList.Terminate;157 var158 I: Integer;159 begin160 for I := 0 to Count - 1 do161 TTCPClientThread(Items[I]).Terminate;162 end;163 164 procedure TTCPClientList.WaitFor;165 var166 I: Integer;167 begin168 for I := 0 to Count - 1 do169 TTCPClientThread(Items[I]).WaitFor;170 end;171 172 constructor TTCPClientList.Create;173 begin174 inherited;175 end;176 177 destructor TTCPClientList.Destroy;178 var179 I: Integer;180 begin181 for I := 0 to Count - 1 do182 TTCPClientThread(Items[I]).Destroy;183 inherited Destroy;184 140 end; 185 141 … … 188 144 procedure TTCPClientThread.Execute; 189 145 begin 190 if Assigned(Parent.Parent.FOnClientConnect) then 191 Parent.Parent.FOnClientConnect(Self); 192 Parent.Remove(Self); 146 if Assigned(Parent.FOnClientConnect) then 147 Parent.FOnClientConnect(Self); 193 148 end; 194 149 195 constructor TTCPClientThread.Create(CreateSuspended: Boolean; 196 const StackSize: SizeUInt); 150 constructor TTCPClientThread.Create; 197 151 begin 198 inherited Create(CreateSuspended, StackSize);152 inherited; 199 153 Socket := TTCPBlockSocket.Create; 200 154 end; … … 202 156 destructor TTCPClientThread.Destroy; 203 157 begin 204 //Socket.Destroy; 205 inherited Destroy; 158 Socket.Destroy; 159 inherited; 160 end; 161 162 { TClientThreadedPool } 163 164 procedure TClientThreadedPool.SetActive(const AValue: Boolean); 165 var 166 I: Integer; 167 begin 168 if not FActive and Active then begin 169 Allocate; 170 for I := 0 to TotalCount - 1 do begin 171 TThreadedPoolItem(Items[I]).Item := TTCPClientThread.Create; 172 end; 173 end else 174 if FActive and not Active then begin 175 176 end; 177 FActive := Active; 206 178 end; 207 179 -
branches/DirectWeb/UWebServer.pas
r87 r88 7 7 uses 8 8 Classes, SysUtils, UHTTPServer, UHTTPSessionFile, 9 UTCPServer, 10 UCommon, 9 UTCPServer, Contnrs, 10 UCommon, syncobjs, 11 11 UMemoryStreamEx, 12 12 UMIMEType, Synautil, 13 USqlDatabase, DOM, XMLRead ;13 USqlDatabase, DOM, XMLRead, UHTMLControls; 14 14 15 15 const … … 17 17 18 18 type 19 { TWebServer } 20 21 TWebServer = class 19 20 { TDatabasePool } 21 22 TDatabasePool = class(TObjectList) 22 23 private 23 HTTPSessionFile: THTTPSessionFile; 24 function PagesList(URL: string; Page, TotalCount, CountPerPage: Integer 25 ): string; 26 procedure ServerInfo(Request: THTTPRequest; Response: THTTPResponse); 24 Lock: TCriticalSection; 27 25 public 28 HTTPServer: THTTPServer;26 PoolSize: Integer; 29 27 HostName: string; 30 28 Schema: string; 31 29 UserName: string; 32 30 Password: string; 33 34 procedure ViewList(Request: THTTPRequest; Response: THTTPResponse); 35 procedure ViewItem(Request: THTTPRequest; Response: THTTPResponse); 36 procedure SendIndex(Request: THTTPRequest; Response: THTTPResponse); 31 procedure Allocate; 32 function Acquire: TSqlDatabase; 33 procedure Release(Database: TSqlDatabase); 34 constructor Create; 35 destructor Destroy; override; 36 end; 37 38 { TWebServer } 39 40 TWebServer = class 41 private 42 SessionStorage: TFileHTTPSessionStorage; 43 procedure ServerInfo(HandlerData: THTTPHandlerData); 44 public 45 HTTPServer: THTTPServer; 46 DatabasePool: TDatabasePool; 47 48 procedure ViewList(HandlerData: THTTPHandlerData); 49 procedure ViewItem(HandlerData: THTTPHandlerData); 50 procedure SendIndex(HandlerData: THTTPHandlerData); 37 51 procedure WriteHeader(Stream: TMemoryStreamEx); 38 52 procedure WriteFooter(Stream: TMemoryStreamEx); … … 63 77 with ChildNodes[I3] do begin 64 78 if NodeName = 'hostname' then 65 HostName := TextContent;79 DatabasePool.HostName := TextContent; 66 80 if NodeName = 'schema' then 67 Schema := TextContent;81 DatabasePool.Schema := TextContent; 68 82 if NodeName = 'username' then 69 UserName := TextContent;83 DatabasePool.UserName := TextContent; 70 84 if NodeName = 'password' then 71 Password := TextContent;85 DatabasePool.Password := TextContent; 72 86 end; 73 87 if NodeName = 'server' then … … 102 116 end; 103 117 104 function TWebServer.PagesList(URL: string; Page, TotalCount, CountPerPage: Integer): string; 105 const 106 Around: Integer = 10; 107 var 108 Count: Integer; 109 PagesMax: Integer; 110 PagesMin: Integer; 111 I: Integer; 112 begin 113 Count := Round(TotalCount / CountPerPage); 114 Result := ''; 115 if Count > 1 then begin 116 if Page > 0 then begin 117 Result := Result + '<a href="' + URL + '0"><<</a> '; 118 Result := Result + '<a href="' + URL + IntToStr(Page - 1) + '"><</a> '; 119 end; 120 PagesMax := Count - 1; 121 PagesMin := 0; 122 if PagesMax > (Page + Around) then PagesMax := Page + Around; 123 if PagesMin < (Page - Around) then begin 124 Result := Result + ' .. '; 125 PagesMin := Page - Around; 126 end; 127 for I := PagesMin to PagesMax do begin 128 if I = Page then Result := Result + '<strong>'; 129 Result := Result + '<a href="' + URL + IntToStr(I) + '">' + IntToStr(I + 1) + '</a> '; 130 if I = Page then Result := Result + '</strong>'; 131 end; 132 if PagesMax < (Count - 1) then Result := Result + ' .. '; 133 if Page < (Count - 1) then begin 134 Result := Result + '<a href="' + URL + IntToStr(Page + 1) + '">></a> '; 135 Result := Result + '<a href="' + URL + IntToStr(Count - 1) + '">>></a>'; 136 end; 137 end; 138 end; 139 140 procedure TWebServer.ViewList(Request: THTTPRequest; Response: THTTPResponse); 118 procedure TWebServer.ViewList(HandlerData: THTTPHandlerData); 141 119 var 142 120 SqlDatabase: TSqlDatabase; … … 147 125 Title: string; 148 126 LinkQuery: TQueryParameterList; 149 begin 150 SqlDatabase := TSqlDatabase.Create; 151 with Response, Stream, SqlDatabase do 127 PageList: TPageList; 128 begin 129 SqlDatabase := DatabasePool.Acquire; 130 with HandlerData, Response, Stream, SqlDatabase do 152 131 begin 153 132 WriteHeader(Stream); 154 HostName := Self.HostName; 155 UserName := Self.UserName; 156 Password := Self.Password; 157 Database := Self.Schema; 158 Connect; 159 WriteString(Request.Query.Values['Table']); 133 134 WriteString('<div align="center">'); 135 136 // Prepare table paging 137 DbRows := Query('SELECT COUNT(*) FROM ' + Request.Query.Values['Table']); 138 PageList := TPageList.Create; 139 PageList.HandlerData := HandlerData; 140 with PageList do begin 141 TotalCount := StrToInt(DbRows[0].ValuesAtIndex[0]); 142 ItemPerPage := 20; 143 NavigatorVisibleItems := 5; 144 Process; 145 end; 146 DbRows.Destroy; 147 148 //WriteString(Request.Query.Values['Table']); 160 149 OrderColumn := Request.Query.Values['OrderCol']; 161 150 OrderDirection := Request.Query.Values['OrderDir']; … … 165 154 OrderDirection := 'DESC'; 166 155 DbRows := Query('SELECT * FROM ' + Request.Query.Values['Table'] + 167 ' ORDER BY ' + OrderColumn + ' ' + OrderDirection );156 ' ORDER BY ' + OrderColumn + ' ' + OrderDirection + PageList.SQLLimit); 168 157 169 158 LinkQuery := TQueryParameterList.Create; 170 159 LinkQuery.Assign(Request.Query); 171 160 172 WriteString('<strong>Seznam typů karet</strong>'); 161 WriteString('<strong>Seznam typů karet</strong><br/>'); 162 WriteString(PageList.Output); 173 163 WriteString('<table><tr>'); 174 164 if DbRows.Count > 0 then … … 197 187 end; 198 188 WriteString('</table>'); 189 WriteString(PageList.Output); 190 WriteString('</div>'); 191 199 192 DbRows.Destroy; 200 193 Destroy; 201 194 WriteFooter(Stream); 202 195 end; 203 end; 204 205 procedure TWebServer.ViewItem(Request: THTTPRequest; Response: THTTPResponse); 196 PageList.Destroy; 197 end; 198 199 procedure TWebServer.ViewItem(HandlerData: THTTPHandlerData); 206 200 var 207 201 SqlDatabase: TSqlDatabase; … … 214 208 begin 215 209 SqlDatabase := TSqlDatabase.Create; 216 with Response, Stream, SqlDatabase do210 with HandlerData, Response, Stream, SqlDatabase do 217 211 begin 218 212 WriteHeader(Stream); 219 HostName := Self.HostName;220 UserName := Self.UserName;221 Password := Self.Password;222 Database := Self.Schema;223 Connect;224 213 DbRows := Query('SELECT * FROM ' + Request.Query.Values['Table'] + 225 214 ' WHERE Id=' + Request.Query.Values['Id']); … … 239 228 end; 240 229 241 procedure TWebServer.ServerInfo( Request: THTTPRequest; Response: THTTPResponse);230 procedure TWebServer.ServerInfo(HandlerData: THTTPHandlerData); 242 231 var 243 232 I: Integer; 244 233 begin 245 with Response.Stream do begin246 Response.Cookies.Values['Test'] := 'Halo';234 with HandlerData, Response.Stream do begin 235 //Response.Cookies.Values['Test'] := 'Halo'; 247 236 //Response.Cookies.Values['Test2'] := 'Halo2'; 248 237 249 HTTPServer.SessionHandler.Variables.Values['Session1'] := 'Value1';238 //HTTPServer.SessionHandler.Variables.Values['Session1'] := 'Value1'; 250 239 //HTTPServer.SessionHandler.Variables.Values['Session2'] := 'Value2'; 251 240 … … 263 252 264 253 WriteString('<h5>Session variables</h5>'); 265 for I := 0 to HTTPServer.SessionHandler.Variables.Count - 1 do begin;266 WriteString( HTTPServer.SessionHandler.Variables.Strings[I] + '<br/>');254 for I := 0 to Session.Count - 1 do begin; 255 WriteString(Session.Strings[I] + '<br/>'); 267 256 end; 268 257 … … 275 264 end; 276 265 277 procedure TWebServer.SendIndex( Request: THTTPRequest; Response: THTTPResponse);278 begin 279 with Response, Stream do266 procedure TWebServer.SendIndex(HandlerData: THTTPHandlerData); 267 begin 268 with HandlerData, Response, Stream do 280 269 begin 281 270 WriteHeader(Stream); 282 WriteString('<img src="logo.png"/><br/>'); 283 WriteString('<strong>Congratulations</strong>'); 284 WriteString('<hr/>'); 285 WriteString('Your PWU LightWebServer based application is running.<br/>'); 286 WriteString('<hr/>'); 287 WriteString('Generated ' + RFC822DateTime(Now) + ' by PWU LightWebServer.'); 271 272 288 273 WriteFooter(Stream); 289 274 end; … … 324 309 begin 325 310 inherited Create; 326 HTTPSessionFile := THTTPSessionFile.Create; 327 with HTTPSessionFile do begin 328 end; 311 DatabasePool := TDatabasePool.Create; 312 DatabasePool.Capacity := 20; 313 DatabasePool.Allocate; 314 315 SessionStorage := TFileHTTPSessionStorage.Create; 329 316 HTTPServer := THTTPServer.Create; 330 317 with HTTPServer, Socket do begin 331 Session Handler := HTTPSessionFile;318 SessionStorage := Self.SessionStorage; 332 319 DocumentRoot := 'Data'; 333 320 with RequestHandlerList do begin … … 346 333 destructor TWebServer.Destroy; 347 334 begin 335 DatabasePool.Destroy; 348 336 HTTPServer.Destroy; 349 HTTPSessionFile.Destroy;337 SessionStorage.Destroy; 350 338 inherited Destroy; 351 339 end; 352 340 341 { TDatabasePool } 342 343 procedure TDatabasePool.Allocate; 344 var 345 I: Integer; 346 begin 347 for I := 0 to PoolSize - 1 do 348 with TSqlDatabase(Items[Add(TSqlDatabase.Create)]) do begin 349 HostName := Self.HostName; 350 UserName := Self.UserName; 351 Password := Self.Password; 352 Database := Self.Schema; 353 Connect; 354 end; 355 end; 356 357 function TDatabasePool.Acquire: TSqlDatabase; 358 begin 359 360 end; 361 362 procedure TDatabasePool.Release(Database: TSqlDatabase); 363 begin 364 try 365 Lock.Acquire; 366 367 finally 368 Lock.Release; 369 end; 370 end; 371 372 constructor TDatabasePool.Create; 373 begin 374 Lock := TCriticalSection.Create; 375 end; 376 377 destructor TDatabasePool.Destroy; 378 begin 379 Lock.Destroy; 380 inherited Destroy; 381 end; 382 353 383 end. 354 384 -
branches/DirectWeb/WoWHostingWebServer.lpi
r87 r88 37 37 </Item1> 38 38 </RequiredPackages> 39 <Units Count=" 27">39 <Units Count="37"> 40 40 <Unit0> 41 41 <Filename Value="WoWHostingWebServer.lpr"/> 42 42 <IsPartOfProject Value="True"/> 43 43 <UnitName Value="WoWHostingWebServer"/> 44 <CursorPos X=" 26" Y="20"/>44 <CursorPos X="32" Y="12"/> 45 45 <TopLine Value="1"/> 46 46 <EditorIndex Value="0"/> … … 52 52 <CursorPos X="1" Y="1"/> 53 53 <TopLine Value="1"/> 54 <UsageCount Value="19 6"/>54 <UsageCount Value="191"/> 55 55 <SyntaxHighlighter Value="None"/> 56 56 </Unit1> … … 58 58 <Filename Value="mimetable.pp"/> 59 59 <UnitName Value="mimetable"/> 60 <UsageCount Value="19 6"/>60 <UsageCount Value="191"/> 61 61 </Unit2> 62 62 <Unit3> 63 63 <Filename Value="BreakTokens.pp"/> 64 64 <UnitName Value="BreakTokens"/> 65 <UsageCount Value="19 6"/>65 <UsageCount Value="191"/> 66 66 </Unit3> 67 67 <Unit4> … … 70 70 <CursorPos X="3" Y="208"/> 71 71 <TopLine Value="202"/> 72 <UsageCount Value=" 200"/>72 <UsageCount Value="195"/> 73 73 </Unit4> 74 74 <Unit5> … … 76 76 <IsPartOfProject Value="True"/> 77 77 <UnitName Value="UHTTPServer"/> 78 <CursorPos X=" 9" Y="169"/>79 <TopLine Value="1 46"/>80 <EditorIndex Value=" 3"/>78 <CursorPos X="80" Y="119"/> 79 <TopLine Value="102"/> 80 <EditorIndex Value="11"/> 81 81 <UsageCount Value="200"/> 82 82 <Loaded Value="True"/> … … 84 84 <Unit6> 85 85 <Filename Value="..\..\..\..\..\Programy\Lazarus_0.9.29\fpc\2.3.1\source\rtl\objpas\classes\classesh.inc"/> 86 <CursorPos X="14" Y="556"/> 87 <TopLine Value="539"/> 88 <UsageCount Value="77"/> 86 <CursorPos X="14" Y="1436"/> 87 <TopLine Value="1419"/> 88 <EditorIndex Value="8"/> 89 <UsageCount Value="96"/> 90 <Loaded Value="True"/> 89 91 </Unit6> 90 92 <Unit7> … … 93 95 <CursorPos X="15" Y="397"/> 94 96 <TopLine Value="380"/> 95 <UsageCount Value=" 100"/>97 <UsageCount Value="95"/> 96 98 </Unit7> 97 99 <Unit8> … … 99 101 <IsPartOfProject Value="True"/> 100 102 <UnitName Value="UTCPServer"/> 101 <CursorPos X=" 1" Y="1"/>102 <TopLine Value=" 1"/>103 <EditorIndex Value=" 2"/>103 <CursorPos X="5" Y="23"/> 104 <TopLine Value="6"/> 105 <EditorIndex Value="3"/> 104 106 <UsageCount Value="200"/> 105 107 <Loaded Value="True"/> … … 111 113 <CursorPos X="23" Y="116"/> 112 114 <TopLine Value="92"/> 113 <EditorIndex Value="5"/>114 115 <UsageCount Value="200"/> 115 <Loaded Value="True"/>116 116 </Unit9> 117 117 <Unit10> … … 120 120 <CursorPos X="54" Y="330"/> 121 121 <TopLine Value="327"/> 122 <UsageCount Value=" 12"/>122 <UsageCount Value="7"/> 123 123 </Unit10> 124 124 <Unit11> … … 128 128 <CursorPos X="24" Y="61"/> 129 129 <TopLine Value="1"/> 130 <UsageCount Value=" 78"/>130 <UsageCount Value="130"/> 131 131 </Unit11> 132 132 <Unit12> … … 134 134 <CursorPos X="41" Y="704"/> 135 135 <TopLine Value="690"/> 136 <UsageCount Value=" 11"/>136 <UsageCount Value="6"/> 137 137 </Unit12> 138 138 <Unit13> … … 140 140 <CursorPos X="9" Y="356"/> 141 141 <TopLine Value="348"/> 142 <UsageCount Value=" 11"/>142 <UsageCount Value="6"/> 143 143 </Unit13> 144 144 <Unit14> … … 148 148 <CursorPos X="3" Y="130"/> 149 149 <TopLine Value="121"/> 150 <EditorIndex Value="7"/> 151 <UsageCount Value="77"/> 152 <Loaded Value="True"/> 150 <UsageCount Value="129"/> 153 151 </Unit14> 154 152 <Unit15> … … 158 156 <CursorPos X="26" Y="28"/> 159 157 <TopLine Value="25"/> 160 <EditorIndex Value="6"/> 161 <UsageCount Value="77"/> 162 <Loaded Value="True"/> 158 <UsageCount Value="129"/> 163 159 </Unit15> 164 160 <Unit16> 165 161 <Filename Value="USqlDatabase.pas"/> 162 <IsPartOfProject Value="True"/> 166 163 <UnitName Value="USqlDatabase"/> 167 <CursorPos X=" 24" Y="345"/>168 <TopLine Value="3 30"/>169 <UsageCount Value=" 36"/>164 <CursorPos X="3" Y="316"/> 165 <TopLine Value="314"/> 166 <UsageCount Value="76"/> 170 167 </Unit16> 171 168 <Unit17> … … 173 170 <CursorPos X="52" Y="6"/> 174 171 <TopLine Value="1392"/> 175 <UsageCount Value=" 10"/>172 <UsageCount Value="5"/> 176 173 </Unit17> 177 174 <Unit18> … … 179 176 <CursorPos X="29" Y="275"/> 180 177 <TopLine Value="260"/> 181 <UsageCount Value=" 10"/>178 <UsageCount Value="5"/> 182 179 </Unit18> 183 180 <Unit19> 184 181 <Filename Value="..\..\..\..\..\Programy\Lazarus_0.9.29\fpc\2.3.1\source\rtl\win\tthread.inc"/> 185 <CursorPos X="17" Y="37"/> 186 <TopLine Value="30"/> 187 <UsageCount Value="9"/> 182 <CursorPos X="3" Y="113"/> 183 <TopLine Value="97"/> 184 <EditorIndex Value="9"/> 185 <UsageCount Value="30"/> 186 <Loaded Value="True"/> 188 187 </Unit19> 189 188 <Unit20> … … 192 191 <CursorPos X="27" Y="2"/> 193 192 <TopLine Value="1"/> 194 <UsageCount Value=" 6"/>193 <UsageCount Value="1"/> 195 194 </Unit20> 196 195 <Unit21> … … 198 197 <IsPartOfProject Value="True"/> 199 198 <UnitName Value="UWebServer"/> 200 <CursorPos X=" 7" Y="247"/>201 <TopLine Value=" 237"/>199 <CursorPos X="12" Y="10"/> 200 <TopLine Value="12"/> 202 201 <EditorIndex Value="1"/> 203 <UsageCount Value=" 67"/>202 <UsageCount Value="119"/> 204 203 <Loaded Value="True"/> 205 204 </Unit21> … … 209 208 <CursorPos X="25" Y="58"/> 210 209 <TopLine Value="31"/> 211 <UsageCount Value=" 10"/>210 <UsageCount Value="5"/> 212 211 </Unit22> 213 212 <Unit23> … … 216 215 <CursorPos X="32" Y="11"/> 217 216 <TopLine Value="1"/> 218 <EditorIndex Value="8"/> 219 <UsageCount Value="25"/> 220 <Loaded Value="True"/> 217 <UsageCount Value="77"/> 221 218 <SyntaxHighlighter Value="XML"/> 222 219 </Unit23> … … 226 223 <CursorPos X="77" Y="4"/> 227 224 <TopLine Value="1"/> 228 <UsageCount Value=" 25"/>225 <UsageCount Value="77"/> 229 226 <SyntaxHighlighter Value="None"/> 230 227 </Unit24> … … 234 231 <CursorPos X="1" Y="19"/> 235 232 <TopLine Value="1"/> 236 <UsageCount Value=" 20"/>233 <UsageCount Value="15"/> 237 234 </Unit25> 238 235 <Unit26> … … 240 237 <IsPartOfProject Value="True"/> 241 238 <UnitName Value="UHTTPSessionFile"/> 242 <CursorPos X="33" Y="31"/> 243 <TopLine Value="19"/> 239 <CursorPos X="35" Y="8"/> 240 <TopLine Value="1"/> 241 <EditorIndex Value="12"/> 242 <UsageCount Value="74"/> 243 <Loaded Value="True"/> 244 </Unit26> 245 <Unit27> 246 <Filename Value="UHTMLControls.pas"/> 247 <IsPartOfProject Value="True"/> 248 <UnitName Value="UHTMLControls"/> 249 <CursorPos X="40" Y="60"/> 250 <TopLine Value="33"/> 251 <EditorIndex Value="2"/> 252 <UsageCount Value="72"/> 253 <Loaded Value="True"/> 254 </Unit27> 255 <Unit28> 256 <Filename Value="..\..\..\..\..\Programy\Lazarus_0.9.29\fpc\2.3.1\source\rtl\inc\threadh.inc"/> 257 <CursorPos X="11" Y="154"/> 258 <TopLine Value="130"/> 259 <EditorIndex Value="5"/> 260 <UsageCount Value="12"/> 261 <Loaded Value="True"/> 262 </Unit28> 263 <Unit29> 264 <Filename Value="..\..\..\..\..\Programy\Lazarus_0.9.29\fpc\2.3.1\source\rtl\win\sysosh.inc"/> 265 <CursorPos X="3" Y="33"/> 266 <TopLine Value="1"/> 267 <UsageCount Value="5"/> 268 </Unit29> 269 <Unit30> 270 <Filename Value="..\..\..\..\..\Programy\Lazarus_0.9.29\fpc\2.3.1\source\packages\fcl-base\src\syncobjs.pp"/> 271 <UnitName Value="syncobjs"/> 272 <CursorPos X="4" Y="60"/> 273 <TopLine Value="43"/> 244 274 <EditorIndex Value="4"/> 245 <UsageCount Value="22"/> 246 <Loaded Value="True"/> 247 </Unit26> 275 <UsageCount Value="30"/> 276 <Loaded Value="True"/> 277 </Unit30> 278 <Unit31> 279 <Filename Value="..\..\..\..\..\Programy\Lazarus_0.9.29\fpc\2.3.1\source\rtl\inc\objpash.inc"/> 280 <CursorPos X="8" Y="170"/> 281 <TopLine Value="153"/> 282 <UsageCount Value="10"/> 283 </Unit31> 284 <Unit32> 285 <Filename Value="..\..\..\..\..\Programy\Lazarus_0.9.29\fpc\2.3.1\source\rtl\win\wininc\func.inc"/> 286 <CursorPos X="10" Y="142"/> 287 <TopLine Value="125"/> 288 <UsageCount Value="6"/> 289 </Unit32> 290 <Unit33> 291 <Filename Value="..\..\..\..\..\Programy\Lazarus_0.9.29\fpc\2.3.1\source\rtl\objpas\classes\lists.inc"/> 292 <CursorPos X="12" Y="102"/> 293 <TopLine Value="100"/> 294 <UsageCount Value="6"/> 295 </Unit33> 296 <Unit34> 297 <Filename Value="..\..\..\..\..\Programy\Lazarus_0.9.29\fpc\2.3.1\source\packages\fcl-base\src\contnrs.pp"/> 298 <UnitName Value="contnrs"/> 299 <CursorPos X="26" Y="72"/> 300 <TopLine Value="64"/> 301 <EditorIndex Value="7"/> 302 <UsageCount Value="30"/> 303 <Loaded Value="True"/> 304 </Unit34> 305 <Unit35> 306 <Filename Value="UPool.pas"/> 307 <IsPartOfProject Value="True"/> 308 <UnitName Value="UPool"/> 309 <CursorPos X="3" Y="86"/> 310 <TopLine Value="82"/> 311 <EditorIndex Value="6"/> 312 <UsageCount Value="60"/> 313 <Loaded Value="True"/> 314 </Unit35> 315 <Unit36> 316 <Filename Value="UResetableThread.pas"/> 317 <IsPartOfProject Value="True"/> 318 <UnitName Value="UResetableThread"/> 319 <CursorPos X="3" Y="22"/> 320 <TopLine Value="5"/> 321 <EditorIndex Value="10"/> 322 <UsageCount Value="59"/> 323 <Loaded Value="True"/> 324 </Unit36> 248 325 </Units> 249 326 <JumpHistory Count="30" HistoryIndex="29"> 250 327 <Position1> 251 <Filename Value="U HTTPServer.pas"/>252 <Caret Line=" 312" Column="1" TopLine="295"/>328 <Filename Value="UTCPServer.pas"/> 329 <Caret Line="57" Column="24" TopLine="34"/> 253 330 </Position1> 254 331 <Position2> 255 <Filename Value="U HTTPServer.pas"/>256 <Caret Line="3 13" Column="1" TopLine="296"/>332 <Filename Value="UTCPServer.pas"/> 333 <Caret Line="32" Column="38" TopLine="15"/> 257 334 </Position2> 258 335 <Position3> 259 <Filename Value="U HTTPServer.pas"/>260 <Caret Line="3 14" Column="1" TopLine="297"/>336 <Filename Value="UPool.pas"/> 337 <Caret Line="33" Column="24" TopLine="6"/> 261 338 </Position3> 262 339 <Position4> 263 <Filename Value="U HTTPServer.pas"/>264 <Caret Line="3 15" Column="1" TopLine="298"/>340 <Filename Value="UTCPServer.pas"/> 341 <Caret Line="32" Column="39" TopLine="15"/> 265 342 </Position4> 266 343 <Position5> 267 <Filename Value="U HTTPServer.pas"/>268 <Caret Line=" 316" Column="1" TopLine="299"/>344 <Filename Value="UTCPServer.pas"/> 345 <Caret Line="58" Column="24" TopLine="39"/> 269 346 </Position5> 270 347 <Position6> 271 <Filename Value="U HTTPServer.pas"/>272 <Caret Line=" 317" Column="1" TopLine="300"/>348 <Filename Value="UTCPServer.pas"/> 349 <Caret Line="57" Column="30" TopLine="34"/> 273 350 </Position6> 274 351 <Position7> 275 <Filename Value="U HTTPServer.pas"/>276 <Caret Line=" 315" Column="1" TopLine="298"/>352 <Filename Value="UTCPServer.pas"/> 353 <Caret Line="218" Column="24" TopLine="195"/> 277 354 </Position7> 278 355 <Position8> 279 <Filename Value="U HTTPServer.pas"/>280 <Caret Line=" 316" Column="1" TopLine="299"/>356 <Filename Value="UTCPServer.pas"/> 357 <Caret Line="133" Column="65" TopLine="116"/> 281 358 </Position8> 282 359 <Position9> 283 <Filename Value="U HTTPServer.pas"/>284 <Caret Line=" 317" Column="1" TopLine="300"/>360 <Filename Value="UTCPServer.pas"/> 361 <Caret Line="135" Column="22" TopLine="118"/> 285 362 </Position9> 286 363 <Position10> 287 <Filename Value="U HTTPServer.pas"/>288 <Caret Line=" 315" Column="1" TopLine="298"/>364 <Filename Value="UTCPServer.pas"/> 365 <Caret Line="193" Column="8" TopLine="190"/> 289 366 </Position10> 290 367 <Position11> 291 <Filename Value="U HTTPServer.pas"/>292 <Caret Line=" 316" Column="1" TopLine="299"/>368 <Filename Value="UTCPServer.pas"/> 369 <Caret Line="134" Column="25" TopLine="117"/> 293 370 </Position11> 294 371 <Position12> 295 <Filename Value="U HTTPServer.pas"/>296 <Caret Line=" 317" Column="1" TopLine="300"/>372 <Filename Value="UTCPServer.pas"/> 373 <Caret Line="25" Column="17" TopLine="8"/> 297 374 </Position12> 298 375 <Position13> 299 <Filename Value="U HTTPServer.pas"/>300 <Caret Line=" 319" Column="1" TopLine="302"/>376 <Filename Value="UTCPServer.pas"/> 377 <Caret Line="134" Column="32" TopLine="117"/> 301 378 </Position13> 302 379 <Position14> 303 <Filename Value=" WoWHostingWebServer.lpr"/>304 <Caret Line="1 " Column="1" TopLine="1"/>380 <Filename Value="UTCPServer.pas"/> 381 <Caret Line="143" Column="1" TopLine="126"/> 305 382 </Position14> 306 383 <Position15> 307 <Filename Value=" WoWHostingWebServer.lpr"/>308 <Caret Line="1 9" Column="3" TopLine="1"/>384 <Filename Value="UTCPServer.pas"/> 385 <Caret Line="141" Column="1" TopLine="126"/> 309 386 </Position15> 310 387 <Position16> 311 <Filename Value="U WebServer.pas"/>312 <Caret Line=" 250" Column="57" TopLine="237"/>388 <Filename Value="UTCPServer.pas"/> 389 <Caret Line="135" Column="36" TopLine="119"/> 313 390 </Position16> 314 391 <Position17> 315 <Filename Value="U HTTPServer.pas"/>316 <Caret Line=" 137" Column="1" TopLine="120"/>392 <Filename Value="UTCPServer.pas"/> 393 <Caret Line="23" Column="13" TopLine="8"/> 317 394 </Position17> 318 395 <Position18> 319 <Filename Value=" WoWHostingWebServer.lpr"/>320 <Caret Line="1 9" Column="1" TopLine="1"/>396 <Filename Value="UTCPServer.pas"/> 397 <Caret Line="148" Column="5" TopLine="130"/> 321 398 </Position18> 322 399 <Position19> 323 <Filename Value="U HTTPSessionFile.pas"/>324 <Caret Line=" 51" Column="1" TopLine="21"/>400 <Filename Value="UTCPServer.pas"/> 401 <Caret Line="154" Column="12" TopLine="137"/> 325 402 </Position19> 326 403 <Position20> 327 <Filename Value="U HTTPSessionFile.pas"/>328 <Caret Line="2 9" Column="1" TopLine="12"/>404 <Filename Value="UTCPServer.pas"/> 405 <Caret Line="22" Column="31" TopLine="9"/> 329 406 </Position20> 330 407 <Position21> 331 <Filename Value="U HTTPSessionFile.pas"/>332 <Caret Line=" 30" Column="1" TopLine="13"/>408 <Filename Value="UTCPServer.pas"/> 409 <Caret Line="26" Column="24" TopLine="9"/> 333 410 </Position21> 334 411 <Position22> 335 <Filename Value=" WoWHostingWebServer.lpr"/>336 <Caret Line="1 6" Column="59" TopLine="1"/>412 <Filename Value="UTCPServer.pas"/> 413 <Caret Line="153" Column="36" TopLine="133"/> 337 414 </Position22> 338 415 <Position23> 339 <Filename Value=" WoWHostingWebServer.lpr"/>340 <Caret Line="1 4" Column="17" TopLine="1"/>416 <Filename Value="UTCPServer.pas"/> 417 <Caret Line="171" Column="25" TopLine="148"/> 341 418 </Position23> 342 419 <Position24> 343 <Filename Value="UHTTPSe ssionFile.pas"/>344 <Caret Line=" 29" Column="1" TopLine="12"/>420 <Filename Value="UHTTPServer.pas"/> 421 <Caret Line="35" Column="28" TopLine="35"/> 345 422 </Position24> 346 423 <Position25> 347 <Filename Value="UHTTPSe ssionFile.pas"/>348 <Caret Line=" 30" Column="1" TopLine="13"/>424 <Filename Value="UHTTPServer.pas"/> 425 <Caret Line="180" Column="23" TopLine="162"/> 349 426 </Position25> 350 427 <Position26> 351 <Filename Value="UHTTPSe ssionFile.pas"/>352 <Caret Line=" 33" Column="1" TopLine="16"/>428 <Filename Value="UHTTPServer.pas"/> 429 <Caret Line="119" Column="37" TopLine="102"/> 353 430 </Position26> 354 431 <Position27> 355 <Filename Value=" UHTTPSessionFile.pas"/>356 <Caret Line=" 37" Column="1" TopLine="20"/>432 <Filename Value="WoWHostingWebServer.lpr"/> 433 <Caret Line="15" Column="26" TopLine="1"/> 357 434 </Position27> 358 435 <Position28> 359 <Filename Value=" UWebServer.pas"/>360 <Caret Line="2 47" Column="7" TopLine="237"/>436 <Filename Value="WoWHostingWebServer.lpr"/> 437 <Caret Line="25" Column="1" TopLine="1"/> 361 438 </Position28> 362 439 <Position29> 363 440 <Filename Value="WoWHostingWebServer.lpr"/> 364 <Caret Line="1 4" Column="17" TopLine="1"/>441 <Caret Line="18" Column="24" TopLine="1"/> 365 442 </Position29> 366 443 <Position30> 367 444 <Filename Value="WoWHostingWebServer.lpr"/> 368 <Caret Line="2 2" Column="14" TopLine="1"/>445 <Caret Line="21" Column="18" TopLine="1"/> 369 446 </Position30> 370 447 </JumpHistory> -
branches/DirectWeb/WoWHostingWebServer.lpr
r87 r88 10 10 {$ENDIF} 11 11 {$ENDIF} 12 Classes, 13 SysUtils, UWebServer, UHTTPSessionFile; 12 Classes, SysUtils, UWebServer; 14 13 15 14 {$IFDEF WINDOWS}{$R WoWHostingWebServer.rc}{$ENDIF}
Note:
See TracChangeset
for help on using the changeset viewer.