public function beforeAction($action) { if (!parent::beforeAction($action)) { return false; } if ($action->id != 'error' && Extension_Loaded('zlib')) { Ob_Start('ob_gzhandler'); } return true; }
static function load($template_name, $vars = array()) { Extract($vars); $template_path = Locate_Template($template_name); Ob_Start(); if (!empty($template_path)) { include $template_path; } else { include SPrintF('%s/templates/%s', Core::$plugin_folder, $template_name); } return Ob_Get_Clean(); }
function AnimatedOut() { for ($i = 0; $i < ANIM_FRAMES; $i++) { $image = imageCreateTrueColor(imageSX($this->image), imageSY($this->image)); if (imageCopy($image, $this->image, 0, 0, 0, 0, imageSX($this->image), imageSY($this->image))) { Captcha::DoNoise($image, 200, 0); Ob_Start(); imageGif($image); imageDestroy($image); $f_arr[] = Ob_Get_Contents(); $d_arr[] = ANIM_DELAYS; Ob_End_Clean(); } } $GIF = new GIFEncoder($f_arr, $d_arr, 0, 2, -1, -1, -1, 'C_MEMORY'); return $GIF->GetAnimation(); }
<?php /** * Irate Framework * Copyright (C) 2011 <Irate Designs || framework@iratedesigns.com> * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. **/ //Turn Error Reporting Off: error_reporting(0); //Start the Ob_Start() Function Ob_Start(); //Include the Installation Database Class. include INSTALL_PREFIX . "classes/" . INSTALL_PREFIX . "database.class.php";
public function Render_Gallery($template_file) { # Uses template filter $template_file = Apply_Filters('fancy_gallery_template', $template_file); # If there is no valid template file we bail out if (!Is_File($template_file)) { $template_file = $this->Get_Default_Template(); } # Load template Ob_Start(); include $template_file; $code = Ob_Get_Clean(); # Strip Whitespaces $code = PReg_Replace('/\\s+/', ' ', $code); $code = Str_Replace('> <', '><', $code); $code = Trim($code); # Return return $code; }