当前位置: 首页>>代码示例>>PHP>>正文


PHP Feedback::insert方法代码示例

本文整理汇总了PHP中Feedback::insert方法的典型用法代码示例。如果您正苦于以下问题:PHP Feedback::insert方法的具体用法?PHP Feedback::insert怎么用?PHP Feedback::insert使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Feedback的用法示例。


在下文中一共展示了Feedback::insert方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: changeImage

<?php

require_once "administrator/process/class/class.Feedback.php";
require_once "administrator/includes/injection.php";
require_once "deny/connector.php";
$title = sqlInjection($_POST['title']);
$name = sqlInjection($_POST['fullname']);
$email = sqlInjection($_POST['email']);
$content = sqlInjection($_POST['content']);
$error = "";
$_SESSION['FBERROR'] = "";
if (isset($_POST['submit'])) {
    if ($_POST['captcha'] == $_SESSION['CODE']) {
        $fb = new Feedback();
        $fb->insert($title, $name, $email, $content);
        $_SESSION['FBERROR'] = 'Bạn đã gửi thành công.';
    } else {
        $_SESSION['FBERROR'] = '- Sai mã xác nhận !';
    }
}
?>
<script language="javascript">
var error="";

function changeImage(){
	document.getElementById('imgcaptcha').src="captcha/captcha.php";
}

function checkEmpty(elementId,errorMessage)
{
	x1 = document.getElementById(elementId);
开发者ID:meghv999,项目名称:cdshop-php,代码行数:31,代码来源:feedback.php

示例2: Feedback

<?php

include 'feedback.php';
$feedback = new Feedback();
$feedback['name'] = $_POST['name'];
$feedback['email'] = $_POST['email'];
$feedback['subject'] = $_POST['subject'];
$feedback['msg'] = $_POST['msg'];
$res = $feedback->insert();
echo "{$res}";
开发者ID:shroukelsayed,项目名称:php,代码行数:10,代码来源:feedbackUs.php

示例3: Feedback

<?php

require_once '/../modal/core/setup.php';
if (Input::exist() && $user->isLoggedIn()) {
    $feedback = new Feedback();
    try {
        $feedback->insert($user->data()->userID, Input::get('type'), Input::get('feedback'));
    } catch (Exception $e) {
        die($e->getMessage());
    }
    //force refresh
    header('Location: /TCS/feedback');
}
exit;
开发者ID:NoOneLiv3,项目名称:TCS-Webstore,代码行数:14,代码来源:feedback-process.php

示例4: submitFeedback

 public static function submitFeedback()
 {
     $captcha = Core::validate(self::getVar('captcha'));
     $right_code = Session::getSessionVariable('security_code');
     Session::unsetSessionVariable('security_code');
     if ($captcha != $right_code) {
         Core::printErrorJson('Incorrect captcha');
         exit;
     }
     $usr = self::getCurrentUser(1);
     if (!isset($usr)) {
         header('Location: /');
         exit;
     }
     $feedback = array();
     $feedback['type'] = Core::validate(self::getVar('trouble-type'));
     $feedback['message'] = Core::validate(self::getVar('trouble'));
     $feedback['email'] = Core::validate(self::getVar('email'));
     $fbModel = new Feedback();
     $fbModel->setUID($usr->getId());
     $fbModel->setType($feedback['type']);
     $fbModel->setMessage($feedback['message']);
     $fbModel->setEmail($feedback['email']);
     $fbModel->insert();
     Core::printSuccessJson('Your ticket is active now!');
 }
开发者ID:Christian1998,项目名称:php_btc_exchange,代码行数:26,代码来源:usrController.php


注:本文中的Feedback::insert方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。