Dotclear


Ignore:
Timestamp:
09/06/13 21:36:57 (12 years ago)
Author:
franck <carnet.franck.paul@…>
Branch:
default
Message:

Add mysqli support, step 1, addresses #1450

File:
1 edited

Legend:

Unmodified
Added
Removed
  • plugins/importExport/inc/flat/class.flat.import.php

    r1093 r1743  
    160160                         if (in_array($last_line_name,$constrained)) { 
    161161                              # UNDEFER 
    162                               if ($this->con->driver() == 'mysql') $this->con->execute('SET foreign_key_checks = 1'); 
     162                              if ($this->con->driver() == 'mysql' || $this->con->driver() == 'mysqli') $this->con->execute('SET foreign_key_checks = 1'); 
    163163                              if ($this->con->driver() == 'pgsql') $this->con->execute('SET CONSTRAINTS ALL DEFERRED'); 
    164164                         } 
     
    166166                         if (in_array($line->__name,$constrained)) { 
    167167                              # DEFER 
    168                               if ($this->con->driver() == 'mysql') $this->con->execute('SET foreign_key_checks = 0'); 
     168                              if ($this->con->driver() == 'mysql' || $this->con->driver() == 'mysqli') $this->con->execute('SET foreign_key_checks = 0'); 
    169169                              if ($this->con->driver() == 'pgsql') $this->con->execute('SET CONSTRAINTS ALL IMMEDIATE'); 
    170170                         } 
     
    205205               } 
    206206                
    207                if ($this->con->driver() == 'mysql') $this->con->execute('SET foreign_key_checks = 1'); 
     207               if ($this->con->driver() == 'mysql' || $this->con->driver() == 'mysqli') $this->con->execute('SET foreign_key_checks = 1'); 
    208208               if ($this->con->driver() == 'pgsql') $this->con->execute('SET CONSTRAINTS ALL DEFERRED'); 
    209209          } 
Note: See TracChangeset for help on using the changeset viewer.

Sites map