Ignore:
Timestamp:
Apr 30, 2011, 11:44:14 PM (14 years ago)
Author:
george
Message:
  • Modified: SQL database class is now used as component.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Modules/UMainModule.pas

    r50 r51  
    3232    HTTPServer: THTTPServerCGI;
    3333    HTTPSessionStorageMySQL1: THTTPSessionStorageMySQL;
     34    Database: TSqlDatabase;
    3435    procedure HTTPServerRequest(HandlerData: THTTPHandlerData);
    3536  private
     
    5152    HtmlDocument: THtmlDocument;
    5253    Pages: TRegistredPageList;
    53     Database: TSqlDatabase;
    5454    PageName: string;
    5555    ModuleName: string;
     
    164164begin
    165165  inherited;
    166   Database := TSqlDatabase.Create;
    167166  Pages := TRegistredPageList.Create;
    168167  HtmlDocument := THtmlDocument.Create;
     
    176175begin
    177176  HtmlDocument.Free;
    178   Database.Free;
    179177  Pages.Free;
    180178  User.Free;
     
    291289  MainModule.HTTPServer.ShowExceptions := Config.ShowException;
    292290  //Database.Query('SELECT * FROM ssss');
    293   THTTPSessionStorageMySQL(MainModule.HTTPServer.SessionStorage).SqlDatabase := Database;
    294291  MainModule.HTTPServer.Run;
    295292end;
Note: See TracChangeset for help on using the changeset viewer.