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


PHP mysqlquery::getRow方法代码示例

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


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

示例1: mysqlquery

require_once 'includes/rlsmart/header.php';
require_once "includes/get_sql_value_string.php";
require_once 'userviews_class.php';
require_once 'classes/class_rafl.php';
//find user
$mysql = new mysqlquery();
$userview = new userviews();
$parent_data = $userview->findParent($_GET['item_id'], "rafl");
// Check rights
if (strlen($_GET['share_id'])) {
    $userview->checkSharedRights($_GET['share_id']);
} else {
    $userview->checkViewRights();
}
if (strlen($_SESSION['USER']->id)) {
    $userData = $mysql->getRow("SELECT mb_icon FROM {$_SESSION['RealS_prefix']}members WHERE mb_id=" . $_SESSION['USER']->id);
    $icon = $userData['mb_icon'];
}
$colname_rs_success = "-1";
if (isset($_GET['item_id'])) {
    $colname_rs_success = $_GET['item_id'];
}
mysql_select_db($CFG->dbname, $smart);
// Gimme all success criteria
// Subquery: Conclude from the comment item id what the comment count for each success item must be
$query_rs_success = "SELECT\r\n\t                     \t{$_SESSION['RealS_prefix']}items.item_id,\r\n\t                     \t{$_SESSION['RealS_prefix']}webcells.webcell_title,\r\n\t                     \t{$_SESSION['RealS_prefix']}webcells.webcell_text,\r\n\t                     \t{$_SESSION['RealS_prefix']}rafl.rafl_collective,\r\n\t                     \t{$_SESSION['RealS_prefix']}rafl.rafl_success_evid_req,\r\n\t                     \t{$_SESSION['RealS_prefix']}rafl.rafl_success_obj\r\n\t                     FROM {$_SESSION['RealS_prefix']}items\r\n\t                     \tLEFT OUTER JOIN {$_SESSION['RealS_prefix']}webcells ON {$_SESSION['RealS_prefix']}webcells.webcell_id={$_SESSION['RealS_prefix']}items.item_webcell\r\n\t                     \tLEFT OUTER JOIN {$_SESSION['RealS_prefix']}rafl ON {$_SESSION['RealS_prefix']}rafl.rafl_item={$_SESSION['RealS_prefix']}items.item_id\r\n\t                     \tLEFT OUTER JOIN {$_SESSION['RealS_prefix']}members ON {$_SESSION['RealS_prefix']}webcells.webcell_member = {$_SESSION['RealS_prefix']}members.mb_id\r\n\t                     WHERE {$_SESSION['RealS_prefix']}items.item_parent_item = " . GetSQLValueString($colname_rs_success, "int") . "\r\n\t                     \tAND {$_SESSION['RealS_prefix']}items.item_default_type = 1\r\n\t                     ORDER BY {$_SESSION['RealS_prefix']}rafl.rafl_order";
//$query_rs_success = sprintf("SELECT {$_SESSION['RealS_prefix']}webcells.*, {$_SESSION['RealS_prefix']}items.item_id, {$_SESSION['RealS_prefix']}rafl.* FROM rafl INNER JOIN items ON {$_SESSION['RealS_prefix']}rafl.rafl_item = {$_SESSION['RealS_prefix']}items.item_id INNER JOIN webcells ON {$_SESSION['RealS_prefix']}items.item_webcell = {$_SESSION['RealS_prefix']}webcells.webcell_id WHERE item_parent_item = %s", GetSQLValueString($colname_rs_success, "int"));
$mysql = new mysqlquery();
$successes = $mysql->runsql($query_rs_success);
//$rs_success = mysql_query($query_rs_success, $smart) or die(mysql_error());
//$success = mysql_fetch_assoc($rs_success);
开发者ID:nadavkav,项目名称:MoodleTAO,代码行数:31,代码来源:getSuccess.php


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