Exemple #1
0
}
$objArr = array();
if ($logicid == 'mingcheng' || startsWith($objectid, "fromtable")) {
    $objArr = explode("__", $objectid);
    # <selectoption>hss_tuanduitbl__mingcheng:团款|hss_info_gouwudiantbl__mingcheng:商店流水|2:导游人头|3:摄像|4:其他</selectoption>
    $tbl = $objArr[0];
    $_REQUEST['tbl'] = $tbl;
    #print_r($objArr);
}
$gtbl = new GTbl($tbl, array(), $elementsep);
$hm = null;
if ($logicid == 'mingcheng') {
    #
} else {
    if ($logicid == 'xiane') {
        $hm = $gtbl->getBy("*", "id='" . $objectid . "'");
        if ($hm[0]) {
            $hm = $hm[1];
            $tbl = $hm[0]['tblname'];
            $_REQUEST['tbl'] = $tbl;
        }
    } else {
        if ($logicid == "leibie") {
            $tbl = $_REQUEST['tbl'];
            if (strpos($tbl, $_CONFIG['tblpre']) !== 0) {
                $tbl = $_CONFIG['tblpre'] . $tbl;
                # 兼容不是以 hss_ 开头的表名
            }
        }
    }
}
Exemple #2
0
$db = $_REQUEST['db'] == '' ? $mydb : $_REQUEST['db'];
$field = $_REQUEST['field'];
$url = $rtvdir . "/ido.php";
$url = mkUrl($url, $_REQUEST);
$maintbl_sanke = "hss_sanke_tuanduitbl";
$otbl = $_REQUEST['otbl'];
$oid = $_REQUEST['oid'];
$lfield = $_REQUEST['linkfield'];
#if($oid == ''  && $otbl != $_CONFIG['maintbl']){
if ($_REQUEST['linkfieldval'] != '') {
    # added on Mon Mar 19 21:09:43 CST 2012
    $linkfv = $_REQUEST['linkfieldval'];
    $hmconf = GTbl::xml2hash($xmlpathpre, $elementsep, $db, $otbl);
    $gtbl = new GTbl($otbl, $hmconf[0], $elementsep);
    $gtbl->setId($oid);
    $hm = $gtbl->getBy($linkfv, "id=?");
    if ($hm[0]) {
        $hm = $hm[1][0];
        $id = $hm[$linkfv];
    }
} else {
    $id = $oid;
}
$url = preg_replace("/linkfield=([0-9a-zA-Z]*)/", "pnsk\$1=" . $id, $url);
$url = preg_replace("/&id=([0-9]*)/", "", $url);
if (strpos($url, "linkfield2") > 1) {
    $url = preg_replace("/linkfield2=([0-9a-z]*)/", "pnsk\$1=" . $otbl, $url);
    $url .= "&pnsm=1";
    # page navigator search mode, see in class/pagenavi.class.php
}
$out .= "<!-- <br/> --> <table width=\"100%\" >";