Development

Changeset 12763

You must first sign up to be able to contribute.

Changeset 12763

Show
Ignore:
Timestamp:
11/08/08 12:27:24 (8 months ago)
Author:
FabianLange
Message:

[1.2] applied patch for UTF-8 support and using PropelConnections? for PDOSession storage. fixes #4473

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/1.2/lib/database/sfMySQLDatabase.class.php

    r9144 r12763  
    5656        $password = $this->getParameter('password'); 
    5757        $username = $this->getParameter('username'); 
     58        $encoding = $this->getParameter('encoding'); 
    5859 
    5960        break; 
     
    110111      // can't select the database 
    111112      throw new sfDatabaseException(sprintf('Failed to select MySQLDatabase "%s".', $database)); 
     113    } 
     114 
     115    // set encoding if specified 
     116    if($encoding) 
     117    { 
     118      @mysql_query("SET NAMES '".$encoding."'", $this->connection); 
    112119    } 
    113120 
  • branches/1.2/lib/storage/sfDatabaseSessionStorage.class.php

    r10590 r12763  
    100100    $database = $this->options['database']; 
    101101 
    102     // get the database resource 
     102    // get the database and connection 
     103    if(get_class($database) == 'sfPropelDatabase') 
     104    { 
     105      $this->db = Propel::getConnection();  
     106    } 
     107    else 
     108    { 
     109      $this->db = $database->getResource();  
     110    } 
    103111    $this->db = $database->getResource(); 
    104112    $this->con = $database->getConnection(); 
  • doc/branches/1.2/book/08-Inside-the-Model-Layer.txt

    r12576 r12763  
    535535          persistent:         true      # Use persistent connections 
    536536 
    537 The permitted values of the `phptype` parameter are the ones of the database systems supported by Creole
     537The permitted values of the `phptype` parameter are the ones of the database systems supported by PDO
    538538 
    539539  * `mysql` 

The Sensio Labs Network

Since 1998, Sensio Labs has been promoting the Open-Source software movement by providing quality web application development, training, consulting, and supporting several large Open-Source projects.