Example #1
0
}
if ($option == 'actsp') {
    $GETSQL->fUpdate("`{$ODBC['tablepre']}scenic`", "`sc_sp`='{$Industry}'", "`sc_id`='{$id}'");
    die($Industry);
}
if ($option == 'delpass') {
    $sql_hotel = $GETSQL->fSql("sc_uid", "`{$ODBC['tablepre']}scenic`", "`sc_id`='{$id}'", "", "", "", "U_B");
    $GETSQL->fUpdate("`{$ODBC['tablepre']}scenic`", "`sc_pass`='0'", "`sc_id`='{$id}'");
    $GETSQL->fUpdate("`{$ODBC['tablepre']}members`", "`groupid`='3'", "`uid`='{$sql_hotel['sc_uid']}' AND `groupid`='5'");
    die(gb2utf8("<a href=\"javascript:getNews('showfilg{$id}','admin.php?action={$action}&option=pass&id={$id}');\">通过</a> <a href=\"javascript:_confirm_msg_show('确定删除景区','getNews(\\\\'showfilg{$id}\\\\',\\\\'admin.php?action={$action}&option=delhotel&id={$id}\\\\');\$(\\\\'list{$id}\\\\').parentNode.removeChild(\$(\\\\'list{$id}\\\\'))','','');\">删除</a>"));
}
if ($option == 'delhotel') {
    include_once GetLang('image');
    include_once Getincludefun("image");
    $sql_hotel = $GETSQL->fSql("sc_id,sc_logo", "`{$ODBC['tablepre']}scenic`", "`sc_id`='{$id}'", "", "", "", "U_B");
    P_unlink(R_P . "{$config['attach']}/{$sql_hotel['sc_logo']}/{$sql_hotel['sc_logo']}");
    $GETSQL->fDelete("`{$ODBC['tablepre']}scenicattr`", "`attr_hid`='{$sql_hotel['sc_id']}'");
    $GETSQL->fDelete("`{$ODBC['tablepre']}scenicthread`", "`thr_hid`='{$sql_hotel['sc_id']}'");
    $GETSQL->fDelete("`{$ODBC['tablepre']}scenicthreadword`", "`word_hid`='{$sql_hotel['sc_id']}'");
    $GETSQL->fDelete("`{$ODBC['tablepre']}scenicword`", "`word_hid`='{$sql_hotel['sc_id']}'");
    $GETSQL->fDelete("`{$ODBC['tablepre']}scenicyou`", "`thr_hid`='{$sql_hotel['sc_id']}'");
    $GETSQL->fDelete("`{$ODBC['tablepre']}scenicyouword`", "`word_hid`='{$sql_hotel['sc_id']}'");
    $GETSQL->fDelete("`{$ODBC['tablepre']}scenic`", "`sc_id`='{$sql_hotel['sc_id']}'");
    $sql_hotelimage = $GETSQL->fSql("hi_src", "`{$ODBC['tablepre']}scenicimage`", "`hi_hid`='{$sql_hotel['sc_id']}'");
    foreach ($sql_hotelimage as $value) {
        P_unlink(R_P . $value['hi_src']);
        P_unlink(R_P . fimgsrc($value['hi_src'], 'simll/'));
    }
    $GETSQL->fDelete("`{$ODBC['tablepre']}scenicimage`", "`hi_hid`='{$sql_hotel['sc_id']}'");
    die(gb2utf8("删除成功"));
}
Example #2
0
    $GETSQL->fUpdate("`{$ODBC['tablepre']}hotel`", "`hot_see`=`hot_see`+1", "`hot_id`='{$id}'");
    $smarty->assign('config', array('title' => "{$sql_hotel['hot_subject']}_相册", 'keywords' => $config['keywords'] . "{$sql_hotel['hot_subject']}_相册_{$cache_config['subject']}", 'description' => $config['description'] . "{$sql_hotel['hot_subject']}_相册_{$cache_config['subject']}"));
    include_once GetLang('image');
    include_once Getincludefun("image");
    if ($Industry != '') {
        $sql_hotelimage = $GETSQL->fSql("*", "`{$ODBC['tablepre']}hotelimage`", "`hi_hid`='{$id}' AND `hi_id`='{$Industry}'", "", "", "", "U_B");
        $smarty->assign('sql_hotelimage', $sql_hotelimage);
    } else {
        $nCount = "20";
        $cParameter = "action={$action}&option={$option}&id={$id}";
        include_once Getincludefun("page");
        $nNums = $GETSQL->fNumrows("SELECT hi_id FROM `{$ODBC['tablepre']}hotelimage` WHERE `hi_hid`='{$id}'");
        if ($nNums > 0) {
            $sql_hotelimage = $GETSQL->fSql("*", "`{$ODBC['tablepre']}hotelimage`", "`hi_hid`='{$id}'", "ORDER BY `hi_date` DESC,`hi_id` DESC", $nPage * $nCount, $nCount);
            foreach ($sql_hotelimage as $key => $value) {
                $sql_hotelimage[$key]['hi_src'] = fimgsrc($value['hi_src'], 'simll/');
            }
            if ($nNums > $nCount) {
                $fpageup = fPages($nNums, $nPage, $nCount, $cParameter, 1);
                $smarty->assign('fpageup', $fpageup);
            }
            $smarty->assign('sql_hotelimage', $sql_hotelimage);
        }
    }
    $smarty->assign('REQUEST_URI', $_SERVER['REQUEST_URI']);
    $smarty->assign('sql_hotel', $sql_hotel);
    $smarty->assign('rentime', fmicrotime());
    $smarty->display("hotelphoto.htm");
}
if ($option == 'hotelroom') {
    $sql_hotel = $GETSQL->fSql("hot_id,hot_uid,hot_subject,hot_start,hot_pass", "`{$ODBC['tablepre']}hotel`", "`hot_id`='{$id}'", "", "", "", "U_B");
Example #3
0
<?php

if ($actionhtml = GetCache($action)) {
    include_once $actionhtml;
    include_once Getincludefun("html");
    $smarty->assign('cache_config', $cache_config);
}
if ($option == 'index') {
    $smarty->assign('config', array('title' => "", 'keywords' => $config['keywords'] . "_{$cache_config['subject']}", 'description' => $config['description'] . "_{$cache_config['subject']}"));
    $sql_news = $GETSQL->fSql("new_id,new_subject,new_image", "`{$ODBC['tablepre']}news`", "`new_type`='1'", "ORDER BY `new_date` DESC,`new_id` DESC", 0, 5);
    $smarty->assign('sql_news', $sql_news);
    include_once GetLang('image');
    include_once Getincludefun("image");
    $sql_scenicimage = $GETSQL->fSql("hi_id,hi_hid,hi_src,hi_subject", "`{$ODBC['tablepre']}scenicimage`", "", "ORDER BY `hi_date` DESC,`hi_id` DESC", 0, 8);
    foreach ($sql_scenicimage as $key => $value) {
        $sql_scenicimage[$key]['hi_src'] = fimgsrc($value['hi_src'], 'simll/');
    }
    $smarty->assign('sql_scenicimage', $sql_scenicimage);
    $sql_scenic = $GETSQL->fSql("sc_id,sc_subject,sc_logo", "`{$ODBC['tablepre']}scenic`", "`sc_logo`!='' AND `sc_pass`='1'", "ORDER BY `sc_sp` DESC, `sc_see` DESC,`sc_date` DESC,`sc_id` DESC", 0, 2);
    $smarty->assign('sql_scenic0', $sql_scenic[0]);
    $smarty->assign('sql_scenic1', $sql_scenic[1]);
    $sql_scenicattr = $GETSQL->fSql("attr_id,attr_hid,attr_subject", "`{$ODBC['tablepre']}scenicattr`", "", "ORDER BY `attr_date` DESC,`attr_id` DESC", 0, 8);
    $i = 0;
    foreach ($sql_scenicattr as $key => $value) {
        $sql_scenicattr[$key]['attr_content'] = fconurt($value['attr_content']);
        if ($i < 4) {
            $sql_scenicattr0[] = $sql_scenicattr[$key];
        } else {
            $sql_scenicattr1[] = $sql_scenicattr[$key];
        }
        $i++;
Example #4
0
    $nCount = 10;
    if ($Keyword != '') {
        fgetposttoupdatd($Keyword, $ODBC['charset']);
        $where = "`img_uid` LIKE '%{$Keyword}%'";
        $smarty->assign('Keyword', $Keyword);
    } else {
        $where = "1";
    }
    $nNums = $GETSQL->fNumrows("SELECT img_picid FROM `{$ODBC['tablepre']}images` WHERE {$where}");
    if ($nNums > 0) {
        $sql_images = $GETSQL->fSql("*", "`{$ODBC['tablepre']}images`", "{$where}", "ORDER BY `img_filg` DESC,`img_picid` DESC", $nPage * $nCount, $nCount);
        $fpageup = fPages($nNums, $nPage, $nCount, $cParameter, 1);
        $smarty->assign('sql_images', $sql_images);
        $smarty->assign('fpageup', $fpageup);
    }
    $fpageup = fPagesadmin($nNums, $nPage, $nCount, $cParameter, "showtable", 1);
    $smarty->assign('fpageup', $fpageup);
    $smarty->display("images.htm");
}
if ($option == 'del') {
    include_once Getincludefun("image");
    foreach ($_POST['picid'] as $key => $value) {
        if ($_POST['del'][$key] == $value) {
            $sql_images = $GETSQL->fSql("img_picid,img_picsrc", "`{$ODBC['tablepre']}images`", "`img_picid`='{$_POST['del'][$key]}'", "", "", "", "U_B");
            P_unlink(R_P . $sql_images['img_picsrc']);
            P_unlink(R_P . fimgsrc($sql_images['img_picsrc'], 'simll/'));
            $GETSQL->fDelete("`{$ODBC['tablepre']}images`", "`img_picid`='{$_POST['del'][$key]}'");
        }
    }
    die(gb2utf8("ɾ³ý³É¹¦"));
}
Example #5
0
             die(gb2utf8("图片上传成功"));
         }
         if ($type == 'pass') {
             $GETSQL->fUpdate("`{$ODBC['tablepre']}travelimage`", "`hi_pass`='1'", "`hi_id`='{$Industry}' AND `hi_hid`='{$id}'");
             $mesg = "<img src='image/msg/error.gif' onclick=\"getNews('showimgdel_{$Industry}','{$boardurl}index.php?action=update&option=hotelphoto&id={$id}&Industry={$Industry}&type=delpass')\" alt='取消推荐' /><img src='image/msg/closed.gif' onclick=\"_confirm_msg_show('确定删除图片', 'getNews(\\\\\\'showimg_{$Industry}\\\\\\',\\\\\\'{$boardurl}index.php?action=update&option=hotelphoto&id={$id}&Industry={$Industry}&type=del\\\\\\');\$(\\\\\\'showimg_{$Industry}\\\\\\').parentNode.removeChild(\$(\\\\\\'showimg_{$Industry}\\\\\\'))', '', '')\" alt='删除图片' /></div>";
             die(gb2utf8($mesg));
         }
         if ($type == 'delpass') {
             $GETSQL->fUpdate("`{$ODBC['tablepre']}travelimage`", "`hi_pass`='0'", "`hi_id`='{$Industry}' AND `hi_hid`='{$id}'");
             $mesg = "<img src='image/msg/pin_1.gif' onclick=\"getNews('showimgdel_{$Industry}','{$boardurl}index.php?action=update&option=hotelphoto&id={$id}&Industry={$Industry}&type=pass')\" alt='推荐图片' /><img src='image/msg/closed.gif' onclick=\"_confirm_msg_show('确定删除图片', 'getNews(\\\\\\'showimg_{$Industry}\\\\\\',\\\\\\'{$boardurl}index.php?action=update&option=hotelphoto&id={$id}&Industry={$Industry}&type=del\\\\\\');\$(\\\\\\'showimg_{$Industry}\\\\\\').parentNode.removeChild(\$(\\\\\\'showimg_{$Industry}\\\\\\'))', '', '')\" alt='删除图片' /></div>";
             die(gb2utf8($mesg));
         }
         if ($type == 'del') {
             $sql_hotelimage = $GETSQL->fSql("hi_src", "`{$ODBC['tablepre']}travelimage`", "`hi_id`='{$Industry}' AND `hi_hid`='{$id}'", "", "", "", "U_B");
             P_unlink(R_P . "{$sql_hotelimage['hi_src']}");
             P_unlink(R_P . fimgsrc($sql_hotelimage['hi_src'], $simp = 'simll/'));
             $GETSQL->fDelete("`{$ODBC['tablepre']}travelimage`", "`hi_id`='{$Industry}' AND `hi_hid`='{$id}'", "1");
             $GETSQL->fUpdate("`{$ODBC['tablepre']}travel`", "`sc_album`=`hot_album`-1", "`sc_id`='{$id}'");
             if ($actionhtml = GetCache('travel')) {
                 include_once $actionhtml;
                 if ($cache_config['cache'] == '1') {
                     P_unlink(R_P . "html/travel/travelphoto_I_{$id}_Y_{$Industry}.htm");
                 }
             }
         }
     }
 }
 if ($option == 'travelyou') {
     $sql_lyou = $GETSQL->fSql("thr_id,thr_hid,thr_tages", "`{$ODBC['tablepre']}travelyou`", "`thr_hid`='{$id}' AND `thr_id`='{$Industry}'", "", "", "", "U_B");
     if ($sql_lyou['thr_id'] != '' || $sql_pop['group_authority'] == 'all') {
         if ($type == 'del') {