function feedback($args) { if(!MediabirdUtility::checkKeyset($args,array('desc'))) { return false; } $description = $args->desc; $results = array(); $body = "User with id $this->userId has suggested the following feature:\n".$description; $body = wordwrap($body, 70); if (!MediabirdConfig::$disable_mail) { $oldReporting = error_reporting(0); if (method_exists($this->auth, 'sendMail') && $this->auth->sendMail(-1, "Mediabird Feedback", $body)) { $result = MediabirdConstants::processed; } else { $result = MediabirdConstants::serverError; } error_reporting($oldReporting); } else { error_log("Feature suggested by user $this->userId: $description ."); $result = MediabirdConstants::processed; } $results['r'] = $result; return $results; }
<?php //create a MediabirdAuthManager instance include 'auth_manager.php'; $auth = new MediabirdAuthManager(); header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); header("Cache-Control: no-store, no-cache, must-revalidate"); header("Cache-Control: post-check=0, pre-check=0", false); header("Pragma: no-cache"); /* * File: MediabirdCaptchaImages.php * Author: Simon Jarvis * Copyright: 2006 Simon Jarvis * Date: 03/08/06 * Updated: 07/02/07 * Requirements: PHP 4/5 with GD and FreeType libraries * Link: http://www.white-hat-web-design.co.uk/articles/php-captcha.php * * 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 2 * 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: * http://www.gnu.org/licenses/gpl.html * */