Ignore:
Timestamp:
Sep 13, 2010, 11:45:27 AM (14 years ago)
Author:
george
Message:
  • Opraveno: Načítání session.
  • Opraveno: Úniky paměti.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Application/UCustomApplication.pas

    r33 r34  
    7676  DbRows: TDbRows;
    7777begin
    78   Database := TSqlDatabase.Create;
    7978  with Database do begin
    8079    Hostname := DatabaseHostName;
     
    8483    Connect;
    8584  end;
    86   DbRows := Database.Query('SET NAMES utf8');
    87   DbRows.Free;
     85  try
     86    DbRows := Database.Query('SET NAMES utf8');
     87  finally
     88    DbRows.Free;
     89  end;
    8890end;
    8991
     
    9395  TitleTag: THtmlString;
    9496begin
    95   HTTPServer.ShowExceptions := False;
    9697  with HandlerData do begin
    9798  Style := ConfigStyle;
     
    130131  inherited;
    131132  Database := TSqlDatabase.Create;
    132   InitDatabase;
    133133  Pages := TObjectList.Create;
    134134  HtmlDocument := THtmlDocument.Create;
     
    250250procedure TCustomApplication.Run;
    251251begin
     252  InitDatabase;
     253  //Database.Query('SELECT * FROM ssss');
    252254  HTTPServer.SessionStorage := THTTPSessionStorageMySQL.Create;
    253255  THTTPSessionStorageMySQL(HTTPServer.SessionStorage).SqlDatabase := Database;
Note: See TracChangeset for help on using the changeset viewer.