单'; }elseif ($zi == 1){ $zi_fmt = '双'; }elseif ($zi == 2){ $zi_fmt = '叠'; }else{ $zi_fmt = ''; } $xing = $_show['xing']; // SEO 相关 $this->_cfg['titles'] = "{$xing}姓{$sex_fmt}孩{$zi_fmt}字取名-{$xing}姓{$sex_fmt}宝宝{$zi_fmt}字名字大全-{$xing}姓{$sex_fmt}孩名字推荐--{$xing}姓{$sex_fmt}宝宝名字推荐-{$this->_cfg['webname']}"; $this->_cfg['seo_keywords'] = "{$xing}姓{$sex_fmt}孩{$zi_fmt}字取名,{$xing}姓{$sex_fmt}孩{$zi_fmt}字取名,{$xing}姓{$sex_fmt}宝宝{$zi_fmt}字名字大全,{$xing}姓{$sex_fmt}孩名字推荐,{$xing}姓{$sex_fmt}宝宝名字推荐"; $this->_cfg['seo_description'] = "{$this->_cfg['webname']}提供{$xing}姓{$sex_fmt}孩{$zi_fmt}字取名查询,本站为您汇聚了所有的{$xing}姓{$sex_fmt}宝宝{$zi_fmt}字名字大全;我们将根据您需要的信息为您提供{$xing}姓{$sex_fmt}孩{$zi_fmt}字取名大全供大家取名参考。"; $tpl = 'qumingzi_show.htm'; $page = (int)R('page','G'); if( $page > 1 ){ $this->_cfg['titles'] .= '-'.lang('page_current', array('page'=>$page)); } $_show['sex_fmt'] = $sex_fmt; $_show['zi_fmt'] = $zi_fmt; $_show['sex'] = $sex; $_show['zi'] = $zi; $this->assign('cfg', $this->_cfg); $this->assign('cfg_var', $this->_var); $GLOBALS['_show'] = &$_show; $GLOBALS['run'] = &$this; $_ENV['_theme'] = &$this->_cfg['theme']; $this->display($tpl); } //名字详情页 public function mingzi(){ $_GET['xing'] = R('xing'); $_GET['ming'] = R('ming'); if( empty($_GET['xing']) || empty($_GET['ming']) ) core::error404(); $_GET['xing'] = urldecode($_GET['xing']); $_GET['ming'] = urldecode($_GET['ming']); // 检查是否是特殊格式:0_1, 1_2 等(性别_类型) $is_special_format = false; $sex_type = explode('_', $_GET['ming']); if(count($sex_type) == 2 && is_numeric($sex_type[0]) && is_numeric($sex_type[1])){ $is_special_format = true; } if($is_special_format){ // 特殊格式:0_1 - 使用 mz_show.htm 模板 $sex = isset($sex_type[0]) && in_array($sex_type[0], array(0, 1)) ? (int)$sex_type[0] : 99; $zi = isset($sex_type[1]) && in_array($sex_type[1], array(0, 1, 2)) ? (int)$sex_type[1] : 99; if($sex == 99 || $zi == 99){ core::error404(); } $_show = $this->qm_xing->find_fetch(array('xing'=>$_GET['xing']), array(), 0, 1); if( empty($_show) ) core::error404(); $_show = current($_show); $this->_var['topcid'] = $this->_baijiaxing_cid; if($sex == 0){ $sex_fmt = '男'; $_show['sex_type'] = '男孩'; }elseif ($sex == 1){ $sex_fmt = '女'; $_show['sex_type'] = '女孩'; }else{ $sex_fmt = ''; } if($zi == 0){ $zi_fmt = '单'; $_show['zi_type'] = '单字'; }elseif ($zi == 1){ $zi_fmt = '双'; $_show['zi_type'] = '双字'; }elseif ($zi == 2){ $zi_fmt = '叠'; $_show['zi_type'] = '叠字'; }else{ $zi_fmt = ''; } $_show['sex_fmt'] = $sex_fmt; $_show['zi_fmt'] = $zi_fmt; $_show['sex'] = $sex; $_show['zi'] = $zi; $xing = $_show['xing']; $this->_cfg['titles'] = "{$xing}姓{$_show['sex_type']}{$_show['zi_type']}宝宝起名方案-{$xing}姓{$_show['sex_type']}宝宝名字大全-{$this->_cfg['webname']}"; $this->_cfg['seo_keywords'] = "{$xing}姓{$_show['sex_type']}{$_show['zi_type']}起名,{$xing}姓{$_show['sex_type']}名字大全,{$xing}姓宝宝起名"; $this->_cfg['seo_description'] = "{$this->_cfg['webname']}提供{$xing}姓{$_show['sex_type']}{$_show['zi_type']}宝宝起名方案,结合生辰八字、五行、生肖、星座等为您精选优质好名。"; $tpl = 'mz_show.htm'; if(R('year', 'G')){ $params['year'] = R('year', 'G'); }else{ $params['year'] = date('Y',time()); } if(R('month', 'G')){ $params['month'] = (int)R('month', 'G'); }else{ $params['month'] = date('n',time()); } if(R('day', 'G')){ $params['day'] = (int)R('day', 'G'); }else{ $params['day'] = date('j',time()); } if(R('hour', 'G')){ $params['hour'] = R('hour', 'G'); }else{ $params['hour'] = date('G',time()); } $hour_for_calc = $params['hour']; if($hour_for_calc == '未知'){ $hour_for_calc = 0; } $_show['params'] = $params; include_once PLUGIN_PATH.'le_quming_pro/lib/suanming.class.php'; $suanming = new suanming(); if($params['hour'] === '未知'){ $sizhu = $suanming->getSizhu($params['year'], $params['month'], $params['day'], 0, 0); $sizhuwx = array(); foreach($sizhu as $k=>$v){ $sizhuwx[] = $this->qm_zi_wh_bh->tgdzwh($v); } $sizhu[6] = ''; $sizhu[7] = ''; $sizhuwx[6] = ''; $sizhuwx[7] = ''; $_show['hour_unknown'] = true; }else{ $sizhu = $suanming->getSizhu($params['year'], $params['month'], $params['day'], $hour_for_calc, 0); $sizhuwx = array(); foreach($sizhu as $k=>$v){ $sizhuwx[] = $this->qm_zi_wh_bh->tgdzwh($v); } $_show['hour_unknown'] = false; } $_show['sizhu'] = $sizhu; $_show['sizhuwx'] = $sizhuwx; include_once PLUGIN_PATH.'le_quming_pro/lib/nongli.class.php'; $nongli = new nongli(); $nong = $nongli->convertSolarToLunar($params['year'],$params['month'],$params['day']); $mtwelve = array(NULL,"子","丑","寅","卯","辰","巳","午","未","申","酉","戌","亥"); if($params['hour'] == '未知'){ $nlhour = '未知'; }else{ $nlhour = substr($mtwelve[ceil($params['hour']/2)%12+1],0,3); } $_show['nongliymdh'] = array($nong[3],$nong[1],$nong[2],$nlhour); $jmsh = array('jin'=>0, 'mu'=>0, 'shui'=>0, 'huo'=>0, 'tu'=>0); foreach($sizhuwx as $wx){ if($wx == '金') $jmsh['jin']++; elseif($wx == '木') $jmsh['mu']++; elseif($wx == '水') $jmsh['shui']++; elseif($wx == '火') $jmsh['huo']++; elseif($wx == '土') $jmsh['tu']++; } $total = $jmsh['jin'] + $jmsh['mu'] + $jmsh['shui'] + $jmsh['huo'] + $jmsh['tu']; $_show['wuxing_jin'] = $total > 0 ? round($jmsh['jin'] / $total * 100) : 0; $_show['wuxing_mu'] = $total > 0 ? round($jmsh['mu'] / $total * 100) : 0; $_show['wuxing_shui'] = $total > 0 ? round($jmsh['shui'] / $total * 100) : 0; $_show['wuxing_huo'] = $total > 0 ? round($jmsh['huo'] / $total * 100) : 0; $_show['wuxing_tu'] = $total > 0 ? round($jmsh['tu'] / $total * 100) : 0; $_show['wuxing_count_jin'] = $jmsh['jin']; $_show['wuxing_count_mu'] = $jmsh['mu']; $_show['wuxing_count_shui'] = $jmsh['shui']; $_show['wuxing_count_huo'] = $jmsh['huo']; $_show['wuxing_count_tu'] = $jmsh['tu']; $_show['sizhuwx_str'] = implode('',$sizhuwx); $xing1 = substr($xing,0,3); $xingarr = $this->qm_kan empty($post['bihua']) && $post['bihua'] = $post['jianbihua']; // // $data = array( // 'hanzi'=>$hanzi, // 'pinyin'=>$post['pinyin'], // 'bihua'=>$post['bihua'], // 'jianbihua'=>$post['jianbihua'], // 'bushou'=>$post['bushou'], // 'wuxing'=>$post['wuxing'], // 'fanti'=>$post['fanti'], // ); // // $id = $this->qm_kangxi->create($data); // if($id){ // exit('发布成功'); // }else{ // exit('写入数据表失败'); // } // } //姓名首字母处理 // public function initial(){ // $arr = $this->qm_bjx->find_fetch(array('initial'=>''), array('id'=>1)); // foreach ($arr as $v){ // $py = pinyin::getpinyin($v['xing'], ''); // if(!$py){ // continue; // } // // $py_first = substr($py , 0 , 1); // $v['initial'] = strtoupper($py_first); // if(empty($v['pinyin'])){ // $v['pinyin'] = $py; // } // $this->qm_bjx->update($v); // } // exit('OK'); // } } Lecms 3.0.3 lang[error]

lang[error_info]

lang[error_line]

lang[basic_trace]

lang[program_flow]

SQL

$_GET

$_POST

$_COOKIE

lang[include_file]

lang[other_trace]