欢迎各位兄弟 发布技术文章

这里的技术是共享的

You are here

这个是dedecms 执行 php 包含htm的文件

shiping1 的头像

<?php
require_once 'safe.php';
$_GET=safe_func_array($_GET);
$_POST=safe_func_array($_POST);

require_once(dirname(__FILE__)."/config.php");
require_once(DEDEINC."/dedetag.class.php");
require_once(DEDEINC."/userlogin.class.php");
require_once(DEDEINC."/customfields.func.php");
require_once(DEDEMEMBER."/inc/inc_catalog_options.php");
require_once(DEDEMEMBER."/inc/inc_archives_functions.php");
require_once (dirname(__FILE__) . "/../include/common.inc.php");

$channelid = isset($channelid) && is_numeric($channelid) ? $channelid : 1;
$mtypesid = isset($mtypesid) && is_numeric($mtypesid) ? $mtypesid : 0;
$menutype = 'content';
//error_reporting(E_ALL);

/*-------------
function _ShowForm(){  }
--------------*/
if(empty($dopost))
{
    $cInfos = $dsql->GetOne("Select * From `#@__channeltype`  where id='$channelid'; ");
//    if($case=='zaixian'){
//        die('参数已更改');
//        include(DEDETEMPLATE."/default/zaixianbaoming-login.htm");
//    }else if($case=='biye'){
//        include(DEDETEMPLATE."/default/biyeliuyan-login.htm");
//    }
//    else{
//        die('参数不对!');
//    }
    include(DEDETEMPLATE."/$cfg_df_style/zixunbaoming-login.htm");
}

/*------------------------------
function _SaveArticle(){  }
------------------------------*/
else if($dopost=='save')
{
    if (empty($_POST['vdcode'])){
      alert('验证码不能为空');
      exit;
    }

    if(!empty($_POST['vdcode'])){
        //$validate = empty($validate) ? '' : strtolower(trim($validate));
        $svali = strtolower(GetCkVdValue());
        $_POST['vdcode'] = strtolower($_POST['vdcode']);
        if(($_POST['vdcode']=='' || $_POST['vdcode'] != $svali) && preg_match("/6/",$safe_gdopen)){
             alert('验证码不对');
             exit;
        }
    }
    //验证码置为空
    ResetVdValue();
     //重设验证码;
   execJs("window.parent.frames.changeAuthCode();");
   //execJs("parent.document.getElementById('loading').innerHTML=\"<img src='/templets/default/images/loadingbaoming.gif' >\";");
   include 'sendbaoming.class.php';
   execJs("parent.document.getElementById('loading').innerHTML='';");
 
   alert('报名成功,我们将尽快联系您!');
    //var_dump($typeUrl);exit;
   //execJs("parent.location.href='/'");
   execJs("parent.location.href='".$_SERVER['HTTP_REFERER']."'");
    //header("location: $typeUrl");
    
}
?>

普通分类: