Changeset 14


Ignore:
Timestamp:
Jun 11, 2009, 10:43:35 PM (15 years ago)
Author:
george
Message:
  • Opraveno: Obnova uživatelského hesla přes email.
  • Upraveno: Překládat emulátor s ladícími informacemi pro GDB.
Location:
trunk/www
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/www/emulator.php

    r12 r14  
    2020    global $System;
    2121   
    22     $this->Database->insert('Task', array('User' => $System->Modules['User']->User['Id'], 'Title' => $Title, 'Time' => 'NOW()', 'CommandList' => implode("\n", $Task)));
     22    $this->Database->insert('Task', array('User' => $System->Modules['User']->User['Id'], 'Title' => $Title, 'Time' => 'NOW()', 'CommandList' => implode("\n", $Task)."\n"));
    2323  }
    2424 
     
    6060      'mkdir objdir',
    6161      'cd objdir',
    62       '../configure --prefix='.$Config['BaseDir'].'emulator/'.$this->Id.'/ --enable-cli --enable-ra --with-debug-info',
     62      'export CFLAGS="-march=athlon64 -m64 -O2 -g -ggdb',
     63      'export CXXFLAGS="-march=athlon64 -m64 -O2 -g -ggdb',
     64      '../configure --prefix='.$Config['BaseDir'].'emulator/'.$this->Id.'/ --enable-cli --enable-ra',
    6365      'make',
    6466      'make install',
  • trunk/www/form_classes.php

    r12 r14  
    2727      //'PhoneNumber' => array('Type' => 'String', 'Caption' => 'Telefón', 'Default' => ''),
    2828      //'ICQ' => array('Type' => 'String', 'Caption' => 'ICQ', 'Default' => ''),
     29    ),
     30  ),
     31  'PasswordRecovery' => array(
     32    'Title' => 'Obnova hesla',
     33    'SubmitText' => 'Obnovit',
     34    'Table' => '',
     35    'Items' => array(
     36      'Name' => array('Type' => 'String', 'Caption' => 'Přihlašovací jméno', 'Default' => ''),
     37      'Email' => array('Type' => 'String', 'Caption' => 'E-mail', 'Default' => ''),
    2938    ),
    3039  ),
  • trunk/www/page.php

    r13 r14  
    3535      if($this->System->Modules['User']->User['Role'] == USER_ROLE_ADMINISTRATOR)
    3636      {
    37         $Output .= '<a href="'.$this->System->Config['Web']['RootFolder'].'/?Action=EmulatorList">Emulátory</a>';
     37        $Output .= ' <a href="'.$this->System->Config['Web']['RootFolder'].'/?Action=EmulatorList">Emulátory</a>';
    3838      }
    3939    }
  • trunk/www/server.php

    r12 r14  
    3434    global $System;
    3535   
    36     $this->Database->insert('Task', array('User' => $System->Modules['User']->User['Id'], 'Title' => $Title, 'Time' => 'NOW()', 'CommandList' => implode("\n", $Task)));
     36    $this->Database->insert('Task', array('User' => $System->Modules['User']->User['Id'], 'Title' => $Title, 'Time' => 'NOW()', 'CommandList' => implode("\n", $Task)."\n"));
    3737  }
    3838 
     
    8787  {
    8888    $this->AddTask('Start emulátoru', array(
    89       'screen -A -m -d -S server'.$this->Id.'-realmd emulator/'.$this->Server['Database']['Emulator']['Id'].'/bin/mangos-realmd -c server/'.$this->Id.'/etc/realmd.conf"',
     89      'screen -A -m -d -S server'.$this->Id.'-realmd emulator/'.$this->Server['Database']['Emulator']['Id'].'/bin/mangos-realmd -c server/'.$this->Id.'/etc/realmd.conf',
    9090      'screen -A -m -d -S server'.$this->Id.'-worldd server/'.$this->Id.'/bin/start.sh',
    9191    ));
     
    178178      '#!/bin/sh',
    179179      'while [ 1=1 ] ; do',
    180       'gdb emulator/'.$this->Id.'/bin/mangos-realmd -x mangos.gdb --batch >>server/'.$this->Id.'/log/mangos-worldd.log 2>>server/'.$this->Id.'/log/mangos-worldd.err',
     180      'gdb emulator/'.$this->Id.'/bin/mangos-worldd -x mangos.gdb --batch >>server/'.$this->Id.'/log/mangos-worldd.log 2>>server/'.$this->Id.'/log/mangos-worldd.err',
    181181      'cd www',
    182182      'php mangos_debug_process.php '.$this->Id.' >>server/'.$this->Id.'/log/mangos_debug.log 2>>server/'.$this->Id.'/log/mangos_debug.err',
  • trunk/www/user.php

    r6 r14  
    103103          {
    104104            $this->Database->insert('User', array('Name' => $Name, 'Login' => $Login, 'Password' => sha1($Password), 'Email' => $Email, 'RegistrationTime' => 'NOW()', 'Locked' => 1, 'Role' => 2));
     105            $UserId = $Database->insert_id;
    105106           
    106107            $Subject = FromUTF8('Registrace nového účtu', 'iso2');
     
    236237    global $Config;
    237238
    238     $DbResult = $this->Database->select('User', 'Name, Id, Email, Password', '`Login`="'.$Login.'" AND `Email`="'.$Email.'"');
    239     if($DbResult->num_rows > 0)
    240     {
    241       $Row = $DbResult->fetch_array();
     239    $DbResult = $this->Database->select('User', 'Login, Name, Id, Email, Password', '`Login`="'.$Login.'" AND `Email`="'.$Email.'"');
     240    if($DbResult->num_rows > 0)
     241    {
     242      $Row = $DbResult->fetch_assoc();
    242243      $NewPassword = substr(sha1(strtoupper($Row['Login'])), 0, 7);
    243244
Note: See TracChangeset for help on using the changeset viewer.