web/lib/Zend/Cache/Frontend/Function.php
changeset 807 877f952ae2bd
parent 207 621fa6caec0c
child 1230 68c69c656a2c
equal deleted inserted replaced
805:5e7a0fedabdf 807:877f952ae2bd
    13  * to license@zend.com so we can send you a copy immediately.
    13  * to license@zend.com so we can send you a copy immediately.
    14  *
    14  *
    15  * @category   Zend
    15  * @category   Zend
    16  * @package    Zend_Cache
    16  * @package    Zend_Cache
    17  * @subpackage Zend_Cache_Frontend
    17  * @subpackage Zend_Cache_Frontend
    18  * @copyright  Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
    18  * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
    19  * @license    http://framework.zend.com/license/new-bsd     New BSD License
    19  * @license    http://framework.zend.com/license/new-bsd     New BSD License
    20  * @version    $Id: Function.php 22648 2010-07-20 14:43:27Z mabe $
    20  * @version    $Id: Function.php 24593 2012-01-05 20:35:02Z matthew $
    21  */
    21  */
    22 
    22 
    23 
    23 
    24 /**
    24 /**
    25  * @see Zend_Cache_Core
    25  * @see Zend_Cache_Core
    28 
    28 
    29 
    29 
    30 /**
    30 /**
    31  * @package    Zend_Cache
    31  * @package    Zend_Cache
    32  * @subpackage Zend_Cache_Frontend
    32  * @subpackage Zend_Cache_Frontend
    33  * @copyright  Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
    33  * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
    34  * @license    http://framework.zend.com/license/new-bsd     New BSD License
    34  * @license    http://framework.zend.com/license/new-bsd     New BSD License
    35  */
    35  */
    36 class Zend_Cache_Frontend_Function extends Zend_Cache_Core
    36 class Zend_Cache_Frontend_Function extends Zend_Cache_Core
    37 {
    37 {
    38     /**
    38     /**
   102         } else {
   102         } else {
   103             // A cache is not available (or not valid for this frontend)
   103             // A cache is not available (or not valid for this frontend)
   104             ob_start();
   104             ob_start();
   105             ob_implicit_flush(false);
   105             ob_implicit_flush(false);
   106             $return = call_user_func_array($callback, $parameters);
   106             $return = call_user_func_array($callback, $parameters);
   107             $output = ob_get_contents();
   107             $output = ob_get_clean();
   108             ob_end_clean();
       
   109             $data = array($output, $return);
   108             $data = array($output, $return);
   110             $this->save($data, $id, $tags, $specificLifetime, $priority);
   109             $this->save($data, $id, $tags, $specificLifetime, $priority);
   111         }
   110         }
   112 
   111 
   113         echo $output;
   112         echo $output;