oxdb.php

Go to the documentation of this file.
00001 <?php
00002 
00006 class oxDb extends oxSuperCfg
00007 {
00013     private static $_instance = null;
00014 
00020     private static  $_oDB = null;
00021 
00027     protected static $_aTblDescCache = array();
00028 
00034     public static function getInstance()
00035     {
00036         // disable caching for test modules
00037         if ( defined( 'OXID_PHP_UNIT' ) ) {
00038             static $inst = array();
00039             self::$_instance = $inst[oxClassCacheKey()];
00040         }
00041 
00042 
00043         if ( !self::$_instance instanceof oxDb ) {
00044 
00045             //do not use simple oxNew here as it goes to eternal cycle
00046             self::$_instance = oxNew( 'oxdb' );
00047 
00048             if ( defined( 'OXID_PHP_UNIT' ) ) {
00049                 $inst[oxClassCacheKey()] = self::$_instance;
00050             }
00051         }
00052         return self::$_instance;
00053     }
00054 
00064     public static function getDb( $blAssoc = false )
00065     {
00066         if ( defined( 'OXID_PHP_UNIT' ) ) {
00067             if ( isset( modDB::$unitMOD ) && is_object( modDB::$unitMOD ) ) {
00068                 return modDB::$unitMOD;
00069             }
00070         }
00071 
00072         global  $ADODB_FETCH_MODE;
00073 
00074         if ( $blAssoc )
00075             $ADODB_FETCH_MODE = ADODB_FETCH_ASSOC;
00076         else
00077             $ADODB_FETCH_MODE = ADODB_FETCH_NUM;
00078 
00079         if ( self::$_oDB !== null ) {
00080             return self::$_oDB;
00081         }
00082 
00083         global  $ADODB_CACHE_DIR;
00084         global  $ADODB_DRIVER,
00085                 $ADODB_SESSION_TBL,
00086                 $ADODB_SESSION_CONNECT,
00087                 $ADODB_SESSION_DRIVER,
00088                 $ADODB_SESSION_USER,
00089                 $ADODB_SESSION_PWD,
00090                 $ADODB_SESSION_DB,
00091                 $ADODB_SESS_LIFE,
00092                 $ADODB_SESS_DEBUG;
00093 
00094         //adding exception handler for SQL errors
00095         $myConfig = self::getInstance()->getConfig();
00096         $iDebug = $myConfig->getConfigParam( 'iDebug' );
00097         if ( $iDebug ) {
00098             require_once getShopBasePath() . 'core/adodblite/adodb-exceptions.inc.php';
00099         }
00100 
00101         // session related parameters. don't change.
00102 
00103         //Tomas
00104         //the default setting is 3000 * 60, but actually changing this will give no effect as now redefinition of this constant
00105         //appears after OXID custom settings are loaded and $ADODB_SESS_LIFE depends on user settings.
00106         //You can find the redefinition of ADODB_SESS_LIFE @ oxconfig.php:: line ~ 390.
00107         $ADODB_SESS_LIFE       = 3000 * 60;
00108         $ADODB_SESSION_TBL     = "oxsessions";
00109         //hardcoding to mysql as otherwise it is not set in some cases
00110         //$ADODB_SESSION_DRIVER  = $ADODB_DRIVER;
00111         $ADODB_SESSION_DRIVER  = "mysql";
00112         $ADODB_SESSION_USER    = $myConfig->getConfigParam( 'dbUser' );
00113         $ADODB_SESSION_PWD     = $myConfig->getConfigParam( 'dbPwd' );
00114         $ADODB_SESSION_DB      = $myConfig->getConfigParam( 'dbName' );
00115         $ADODB_SESSION_CONNECT = $myConfig->getConfigParam( 'dbHost' );
00116         $ADODB_SESS_DEBUG      = false;
00117         $ADODB_CACHE_DIR       = $myConfig->getConfigParam( 'sCompileDir' );
00118 
00119         $sModules = '';
00120         if (  $iDebug == 2 || $iDebug == 3 || $iDebug == 4 || $iDebug == 7  ) {
00121             $sModules = 'perfmon';
00122         }
00123 
00124         // log admin changes ?
00125         if ( $myConfig->isAdmin() && $myConfig->getConfigParam( 'blLogChangesInAdmin' ) ) {
00126             $sModules = ( $sModules ? ':' : '' ) . 'oxadminlog';
00127         }
00128 
00129         self::$_oDB = ADONewConnection( $myConfig->getConfigParam( 'dbType' ), $sModules );
00130 
00131         $sVerPrefix = '';
00132             $sVerPrefix = '_ce';
00133 
00134         if ( !self::$_oDB->connect( $myConfig->getConfigParam( 'dbHost' ), $myConfig->getConfigParam( 'dbUser' ), $myConfig->getConfigParam( 'dbPwd' ), $myConfig->getConfigParam( 'dbName' ) ) ) {
00135             $sConfig = join( '', file( getShopBasePath().'config.inc.php' ) );
00136             if ( strpos( $sConfig, '<dbHost'.$sVerPrefix.'>' ) !== false &&
00137                  strpos( $sConfig, '<dbName'.$sVerPrefix.'>' ) !== false ) {
00138                 header( 'location:setup/index.php' ); // pop to setup as there is something wrong
00139                 exit();
00140             } else {
00141 
00142                 // notifying shop owner about connection problems
00143                 $sFailedShop = isset( $_REQUEST['shp'] )?addslashes( $_REQUEST['shp'] ):'Base shop';
00144 
00145                 $sDate = date( 'l dS of F Y h:i:s A');
00146                 $sScript  = $_SERVER['SCRIPT_NAME'].'?'.$_SERVER['QUERY_STRING'];
00147                 $sReferer = $_SERVER['HTTP_REFERER'];
00148 
00149                 //sending a message to admin
00150                 $sWarningSubject = 'Offline warning!';
00151                 $sWarningBody = "
00152                 Database error in OXID eShop:
00153                 Date: $sDate
00154                 Shop: $sFailedShop
00155 
00156                 mysql error: ".self::$_oDB->errorMsg()."
00157                 mysql error no: ".self::$_oDB->errorNo()."
00158 
00159                 Script: $sScript
00160                 Referer: $sReferer";
00161 
00162                 if ( ( $sAdminEmail = $myConfig->getConfigParam( 'sAdminEmail' ) ) ) {
00163                     include 'core/phpmailer/class.phpmailer.php';
00164 
00165                     $oMailer = new phpmailer();
00166                     $oMailer->isMail();
00167                     $oMailer->From = $sAdminEmail;
00168                     $oMailer->AddAddress( $sAdminEmail );
00169                     $oMailer->Subject = $sWarningSubject;
00170                     $oMailer->Body = $sWarningBody;
00171                     $oMailer->send();
00172                 }
00173 
00174                 //only exception to default construction method
00175                 $oEx = new oxConnectionException();
00176                 $oEx->setMessage( 'EXCEPTION_CONNECTION_NODB' );
00177                 $oEx->setConnectionError( $myConfig->getConfigParam( 'dbUser' ).'s'.getShopBasePath().self::$_oDB->errorMsg() );
00178                 throw $oEx;
00179             }
00180         }
00181 
00182         if (  $iDebug == 2 || $iDebug == 3 || $iDebug == 4  || $iDebug == 7 ) {
00183             try {
00184                 self::$_oDB->execute('truncate table adodb_logsql;');
00185             } catch (ADODB_Exception $e) {
00186                 // nothing
00187             }
00188             self::$_oDB->logSQL( true );
00189         }
00190 
00191         self::$_oDB->cacheSecs = 60 * 10; // 10 minute caching
00192         self::$_oDB->execute( 'SET @@session.sql_mode = ""' );
00193 
00194         if ( $myConfig->isUtf() ) {
00195             self::$_oDB->execute( 'SET NAMES "utf8"' );
00196             self::$_oDB->execute( 'SET CHARACTER SET utf8' );
00197             self::$_oDB->execute( 'SET CHARACTER_SET_CONNECTION = utf8' );
00198             self::$_oDB->execute( 'SET CHARACTER_SET_DATABASE = utf8' );
00199             self::$_oDB->execute( 'SET character_set_results = utf8' );
00200             self::$_oDB->execute( 'SET character_set_server = utf8' );
00201         }
00202 
00203         return self::$_oDB;
00204     }
00205 
00213     public function getMultiLangFieldName( $sField )
00214     {
00215         /*
00216         $sLangAdd = $this->getConfig()->getShopLanguage();
00217         if ( $sLangAdd ) {
00218             $sField .= '_'.$sLangAdd;
00219         }*/
00220 
00221         return $sField . oxLang::getInstance()->getLanguageTag();
00222     }
00223 
00232     public function isQuoteNeeded( $sFieldtype)
00233     {
00234         $aTypesWoQuotes = array('int', 'decimal', 'float', 'tinyint', 'smallint', 'mediumint', 'bigint', 'double');
00235         return !in_array( $sFieldtype, $aTypesWoQuotes);
00236     }
00237 
00245     public function getTableDescription( $sTableName )
00246     {
00247         // simple cache
00248         if ( isset( self::$_aTblDescCache[$sTableName] ) ) {
00249             return self::$_aTblDescCache[$sTableName];
00250         }
00251 
00252             $aFields = self::getDb()->MetaColumns( $sTableName );
00253 
00254         self::$_aTblDescCache[$sTableName] = $aFields;
00255 
00256         return $aFields;
00257     }
00258 
00268     public function convertDBDateTime( $oObject, $blToTimeStamp = false, $blOnlyDate = false )
00269     {
00270         $sDate = $oObject->value;
00271 
00272         // defining time format
00273         $sLocalDateFormat = $this->_defineAndCheckDefaultDateValues( $blToTimeStamp );
00274         $sLocalTimeFormat = $this->_defineAndCheckDefaultTimeValues( $blToTimeStamp );
00275 
00276         // default date/time patterns
00277         $aDefDatePatterns = $this->_defaultDatePattern();
00278 
00279         // regexps to validate input
00280         $aDatePatterns = $this->_regexp2ValidateDateInput();
00281         $aTimePatterns = $this->_regexp2ValidateTimeInput();
00282 
00283         // date/time formatting rules
00284         $aDFormats  = $this->_defineDateFormattingRules();
00285         $aTFormats  = $this->_defineTimeFormattingRules();
00286 
00287         // empty date field value ? setting default value
00288         if ( !$sDate) {
00289             $this->_setDefaultDateTimeValue($oObject, $sLocalDateFormat, $sLocalTimeFormat, $blOnlyDate);
00290             return $oObject->value;
00291         }
00292 
00293         $blDefDateFound = false;
00294 
00295         // looking for default values that are formatted by MySQL
00296         foreach ( array_keys( $aDefDatePatterns ) as $sDefDatePattern ) {
00297             if ( preg_match( $sDefDatePattern, $sDate)) {
00298                 $blDefDateFound = true;
00299                 break;
00300             }
00301         }
00302 
00303         // default value is set ?
00304         if ( $blDefDateFound) {
00305             $this->_setDefaultFormatedValue($oObject, $sDate, $sLocalDateFormat, $sLocalTimeFormat, $blOnlyDate);
00306             return $oObject->value;
00307         }
00308 
00309         $blDateFound = false;
00310         $blTimeFound = false;
00311         $aDateMatches = array();
00312         $aTimeMatches = array();
00313 
00314         // looking for date field
00315         foreach ( $aDatePatterns as $sPattern => $sType) {
00316             if ( preg_match( $sPattern, $sDate, $aDateMatches)) {
00317                 $blDateFound = true;
00318 
00319                 // now we know the type of passed date
00320                 $sDateFormat = $aDFormats[$sLocalDateFormat][0];
00321                 $aDFields    = $aDFormats[$sType][1];
00322                 break;
00323             }
00324         }
00325 
00326         // no such date field available ?
00327         if ( !$blDateFound) {
00328             return $sDate;
00329         }
00330 
00331         if ( $blOnlyDate) {
00332             $this->_setDate($oObject, $sDateFormat, $aDFields, $aDateMatches);
00333             return $oObject->value;
00334         }
00335 
00336         // looking for time field
00337         foreach ( $aTimePatterns as $sPattern => $sType) {
00338             if ( preg_match( $sPattern, $sDate, $aTimeMatches)) {
00339                 $blTimeFound = true;
00340 
00341                 // now we know the type of passed time
00342                 $sTimeFormat = $aTFormats[$sLocalTimeFormat][0];
00343                 $aTFields    = $aTFormats[$sType][1];
00344 
00345                 //
00346                 if ( $sType == "USA" && isset($aTimeMatches[4])) {
00347                     $iIntVal = (int) $aTimeMatches[1];
00348                     if ( $aTimeMatches[4] == "PM") {
00349                         if ( $iIntVal < 13) {
00350                             $iIntVal += 12;
00351                         }
00352                     } elseif ( $aTimeMatches[4] == "AM" && $aTimeMatches[1] == "12") {
00353                         $iIntVal = 0;
00354                     }
00355 
00356                     $aTimeMatches[1] = sprintf("%02d", $iIntVal);
00357                 }
00358 
00359                 break;
00360             }
00361         }
00362 
00363         if ( !$blTimeFound) {
00364             //return $sDate;
00365             // #871A. trying to keep date as possible correct
00366             $this->_setDate($oObject, $sDateFormat, $aDFields, $aDateMatches);
00367             return $oObject->value;
00368         }
00369 
00370         $this->_formatCorrectTimeValue($oObject, $sDateFormat, $sTimeFormat, $aDateMatches, $aTimeMatches, $aTFields, $aDFields);
00371 
00372         // on some cases we get empty value
00373         if ( !$oObject->fldmax_length) {
00374             return $this->convertDBDateTime( $oObject, $blToTimeStamp, $blOnlyDate);
00375         }
00376         return $oObject->value;
00377     }
00378 
00387     public function convertDBTimestamp( $oObject, $blToTimeStamp = false )
00388     {
00389          // on this case usually means that we gonna save value, and value is formatted, not plain
00390         $sSQLTimeStampPattern = "/^([0-9]{4})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})$/";
00391         $sISOTimeStampPattern = "/^([0-9]{4})-([0-9]{2})-([0-9]{2}) ([0-9]{2}):([0-9]{2}):([0-9]{2})$/";
00392         $aMatches = array();
00393 
00394         // preparing value to save
00395         if ( $blToTimeStamp) {
00396             // reformatting value to ISO
00397             $this->convertDBDateTime( $oObject, $blToTimeStamp );
00398 
00399             if ( preg_match( $sISOTimeStampPattern, $oObject->value, $aMatches)) {
00400                 // changing layout
00401                 $oObject->setValue($aMatches[1].$aMatches[2].$aMatches[3].$aMatches[4].$aMatches[5].$aMatches[6]);
00402                 $oObject->fldmax_length = strlen( $oObject->value);
00403                 return $oObject->value;
00404             }
00405         } else {
00406             // loading and formatting value
00407             // checking and parsing SQL timestamp value
00408             //$sSQLTimeStampPattern = "/^([0-9]{4})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})$/";
00409             if ( preg_match( $sSQLTimeStampPattern, $oObject->value, $aMatches ) ) {
00410                 $iTimestamp = mktime( $aMatches[4], //h
00411                                         $aMatches[5], //m
00412                                         $aMatches[6], //s
00413                                         $aMatches[2], //M
00414                                         $aMatches[3], //d
00415                                         $aMatches[1]); //y
00416                 if ( !$iTimestamp ) {
00417                     $iTimestamp = "0";
00418                 }
00419 
00420                 $oObject->setValue(trim( date( "Y-m-d H:i:s", $iTimestamp)));
00421                 $oObject->fldmax_length = strlen( $oObject->value);
00422                 $this->convertDBDateTime( $oObject, $blToTimeStamp );
00423                 return $oObject->value;
00424             }
00425         }
00426     }
00427 
00436     public function convertDBDate( $oObject, $blToTimeStamp = false )
00437     {
00438         return $this->convertDBDateTime( $oObject, $blToTimeStamp, true );
00439     }
00440 
00448     public function createSQLList( $aArray )
00449     {
00450         $sRet = "";
00451 
00452         $blSep = false;
00453         foreach ( $aArray as $aToken) {
00454             if ( !$aToken[0]) {
00455                 continue;
00456             }
00457             if ( $blSep) {
00458                 $sRet .= ",";
00459             }
00460             $sRet .= "'".$aToken[0]."'";
00461             $blSep = true;
00462         }
00463         return $sRet;
00464     }
00465 
00471     static public function startTransaction()
00472     {
00473         self::$_oDB->execute( 'START TRANSACTION' );
00474     }
00475 
00481     static public function commitTransaction()
00482     {
00483         self::$_oDB->execute( 'COMMIT' );
00484     }
00485 
00491     static public function rollbackTransaction()
00492     {
00493         self::$_oDB->execute( 'ROLLBACK' );
00494     }
00495 
00504     static public function setTransactionIsolationLevel( $sLevel = null )
00505     {
00506         $aLevels = array( 'READ UNCOMMITTED', 'READ COMMITTED', 'REPEATABLE READ', 'SERIALIZABLE' );
00507 
00508         if (in_array(strtoupper($sLevel), $aLevels)) {
00509             self::$_oDB->execute( 'SET TRANSACTION ISOLATION LEVEL ' . $sLevel );
00510         }
00511     }
00512 
00513 
00522     public function isValidFieldName( $sField )
00523     {
00524         return ( boolean ) preg_match( "#^[\w\d\._]*$#", $sField );
00525     }
00526 
00538     protected function _setDefaultFormatedValue( $oObject, $sDate, $sLocalDateFormat, $sLocalTimeFormat, $blOnlyDate )
00539     {
00540         $aDefTimePatterns = $this->_defaultTimePattern();
00541         $aDFormats  = $this->_defineDateFormattingRules();
00542         $aTFormats  = $this->_defineTimeFormattingRules();
00543 
00544         foreach ( array_keys( $aDefTimePatterns ) as $sDefTimePattern ) {
00545             if ( preg_match( $sDefTimePattern, $sDate ) ) {
00546                 $blDefTimeFound = true;
00547                 break;
00548             }
00549         }
00550 
00551         // setting and returning default formatted value
00552         if ( $blOnlyDate) {
00553             $oObject->setValue(trim( $aDFormats[$sLocalDateFormat][2] ));// . " " . @$aTFormats[$sLocalTimeFormat][2]);
00554             // increasing(decreasing) field lenght
00555             $oObject->fldmax_length = strlen( $oObject->value );
00556             return ;
00557         } elseif ( $blDefTimeFound ) {
00558             // setting value
00559             $oObject->setValue(trim( $aDFormats[$sLocalDateFormat][2] . " " . $aTFormats[$sLocalTimeFormat][2] ));
00560             // increasing(decreasing) field lenght
00561             $oObject->fldmax_length = strlen( $oObject->value );
00562             return ;
00563         }
00564     }
00565 
00573     protected function _defineAndCheckDefaultTimeValues( $blToTimeStamp )
00574     {
00575         // defining time format
00576         // checking for default values
00577         $sLocalTimeFormat = $this->getConfig()->getConfigParam( 'sLocalTimeFormat' );
00578         if ( !$sLocalTimeFormat || $blToTimeStamp) {
00579             $sLocalTimeFormat = "ISO";
00580         }
00581         return $sLocalTimeFormat;
00582     }
00583 
00591     protected function _defineAndCheckDefaultDateValues( $blToTimeStamp )
00592     {
00593         // defining time format
00594         // checking for default values
00595         $sLocalDateFormat = $this->getConfig()->getConfigParam( 'sLocalDateFormat' );
00596         if ( !$sLocalDateFormat || $blToTimeStamp) {
00597             $sLocalDateFormat = "ISO";
00598         }
00599         return $sLocalDateFormat;
00600     }
00601 
00607     protected function _defaultDatePattern()
00608     {
00609         // default date patterns
00610         $aDefDatePatterns = array("/^0000-00-00/"   => "ISO",
00611                                   "/^00\.00\.0000/" => "EUR",
00612                                   "/^00\/00\/0000/" => "USA"
00613                                  );
00614         return $aDefDatePatterns;
00615     }
00616 
00622     protected function _defaultTimePattern()
00623     {
00624         // default time patterns
00625         $aDefTimePatterns = array("/00:00:00$/"    => "ISO",
00626                                   "/00\.00\.00$/"  => "EUR",
00627                                   "/00:00:00 AM$/" => "USA"
00628                                  );
00629         return $aDefTimePatterns;
00630     }
00631 
00637     protected function _regexp2ValidateDateInput()
00638     {
00639         // regexps to validate input
00640         $aDatePatterns = array("/^([0-9]{4})-([0-9]{2})-([0-9]{2})/"   => "ISO",
00641                                "/^([0-9]{2})\.([0-9]{2})\.([0-9]{4})/" => "EUR",
00642                                "/^([0-9]{2})\/([0-9]{2})\/([0-9]{4})/" => "USA"
00643                               );
00644         return $aDatePatterns;
00645     }
00646 
00652     protected function _regexp2ValidateTimeInput()
00653     {
00654         // regexps to validate input
00655         $aTimePatterns = array("/([0-9]{2}):([0-9]{2}):([0-9]{2})$/"   => "ISO",
00656                                "/([0-9]{2})\.([0-9]{2})\.([0-9]{2})$/" => "EUR",
00657                                "/([0-9]{2}):([0-9]{2}):([0-9]{2}) ([AP]{1}[M]{1})$/" => "USA"
00658                               );
00659         return $aTimePatterns;
00660     }
00661 
00667     protected function _defineDateFormattingRules()
00668     {
00669         // date formatting rules
00670         $aDFormats  = array("ISO" => array("Y-m-d", array(2, 3, 1), "0000-00-00"),
00671                             "EUR" => array("d.m.Y", array(2, 1, 3), "00.00.0000"),
00672                             "USA" => array("m/d/Y", array(1, 2, 3), "00/00/0000")
00673                            );
00674         return $aDFormats;
00675     }
00676 
00682     protected function _defineTimeFormattingRules()
00683     {
00684         // time formatting rules
00685         $aTFormats  = array("ISO" => array("H:i:s",   array(1, 2, 3 ), "00:00:00"),
00686                             "EUR" => array("H.i.s",   array(1, 2, 3 ), "00.00.00"),
00687                             "USA" => array("h:i:s A", array(1, 2, 3 ), "00:00:00 AM")
00688                            );
00689         return $aTFormats;
00690     }
00691 
00702     protected function _setDefaultDateTimeValue( $oObject, $sLocalDateFormat, $sLocalTimeFormat, $blOnlyDate )
00703     {
00704         $aDFormats  = $this->_defineDateFormattingRules();
00705         $aTFormats  = $this->_defineTimeFormattingRules();
00706 
00707         $sReturn = $aDFormats[$sLocalDateFormat][2];
00708         if ( !$blOnlyDate) {
00709             $sReturn .= " ".$aTFormats[$sLocalTimeFormat][2];
00710         }
00711 
00712         if ($oObject instanceof oxField) {
00713             $oObject->setValue(trim($sReturn));
00714         } else {
00715             $oObject->value = trim($sReturn);
00716         }
00717         // increasing(decreasing) field lenght
00718         $oObject->fldmax_length = strlen( $oObject->value);
00719     }
00720 
00731     protected function _setDate( $oObject, $sDateFormat, $aDFields, $aDateMatches )
00732     {
00733         // formatting correct time value
00734         $iTimestamp = mktime( 0, 0, 0, $aDateMatches[$aDFields[0]],
00735                               $aDateMatches[$aDFields[1]],
00736                               $aDateMatches[$aDFields[2]]);
00737 
00738         if ($oObject instanceof oxField) {
00739             $oObject->setValue(@date( $sDateFormat, $iTimestamp ));
00740         } else {
00741             $oObject->value = @date( $sDateFormat, $iTimestamp );
00742         }
00743         // we should increase (decrease) field lenght
00744         $oObject->fldmax_length = strlen( $oObject->value );
00745     }
00746 
00760     protected function _formatCorrectTimeValue( $oObject, $sDateFormat, $sTimeFormat, $aDateMatches, $aTimeMatches, $aTFields, $aDFields )
00761     {
00762         // formatting correct time value
00763         $iTimestamp = @mktime( (int) $aTimeMatches[$aTFields[0]],
00764                                (int) $aTimeMatches[$aTFields[1]],
00765                                (int) $aTimeMatches[$aTFields[2]],
00766                                (int) $aDateMatches[$aDFields[0]],
00767                                (int) $aDateMatches[$aDFields[1]],
00768                                (int) $aDateMatches[$aDFields[2]] );
00769 
00770         if ($oObject instanceof oxField) {
00771             $oObject->setValue(trim( @date( $sDateFormat." ".$sTimeFormat, $iTimestamp ) ));
00772         } else {
00773             $oObject->value = trim( @date( $sDateFormat." ".$sTimeFormat, $iTimestamp ) );
00774         }
00775 
00776         // we should increase (decrease) field lenght
00777         $oObject->fldmax_length = strlen( $oObject->value );
00778     }
00779 
00780 }

Generated on Tue Aug 18 09:21:05 2009 for OXID eShop CE by  doxygen 1.5.5