Example #1
0
 function onshipsave()
 {
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $title = $this->fun->accept('title', 'P');
     $content = $this->fun->accept('content', 'P');
     $price = $this->fun->accept('price', 'P');
     $markup = $this->fun->accept('markup', 'P');
     $iscash = $this->fun->accept('iscash', 'P');
     $isinsure = $this->fun->accept('isinsure', 'P');
     $isinsure = empty($isinsure) ? 0 : $isinsure;
     $insureper = $this->fun->accept('insureper', 'P');
     $insureper = empty($insureper) ? 0 : $insureper;
     $db_table = db_prefix . 'order_shipping';
     $date = time();
     if ($inputclass == 'add') {
         $db_field = 'pid,title,content,price,markup,isclass,iscash,isinsure,insureper,addtime';
         $db_values = "50,'{$title}','{$content}',{$price},{$markup},0,{$iscash},{$isinsure},{$insureper},{$date}";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $this->writelog($this->lng['ordershipping_add_log'], $this->lng['log_extra_ok'] . ' title=' . $title);
         $this->dbcache->clearcache('ordership_array', true);
         exit('true');
     } elseif ($inputclass == 'edit') {
         $osid = $this->fun->accept('osid', 'P');
         $db_where = 'osid=' . $osid;
         $db_set = "title='{$title}',content='{$content}',price={$price},markup={$markup},iscash={$iscash},isinsure={$isinsure},insureper={$insureper}";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['ordershipping_edit_log'], $this->lng['log_extra_ok'] . ' title=' . $title . ' id=' . $osid);
         $this->dbcache->clearcache('ordership_view_' . $osid, true);
         $this->dbcache->clearcache('ordership_array', true);
         exit('true');
     }
 }
Example #2
0
 function onsave()
 {
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $keycode = $this->fun->accept('keycode', 'P');
     $title = $this->fun->accept('title', 'P');
     $lng = $this->fun->accept('lng', 'P');
     $langstr = $this->fun->accept('langstr', 'P');
     $typeid = $this->fun->accept('typeid', 'P');
     $db_table = db_prefix . 'lngpack';
     if ($inputclass == 'add') {
         $db_field = 'pid,lng,title,keycode,langstr,lockin,typeid';
         $db_values = "50,'{$lng}','{$title}','{$keycode}','{$langstr}',0,{$typeid}";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $this->writelog($this->lng['languagepack_add_log'], $this->lng['log_extra_ok'] . ' title=' . $title);
         $this->creat_lanpack($lng, true);
         exit('true');
     } else {
         $lpid = $this->fun->accept('lpid', 'P');
         $db_where = 'lpid=' . $lpid;
         $db_set = "title='{$title}',langstr='{$langstr}',typeid={$typeid}";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->creat_lanpack($lng, true);
         $this->writelog($this->lng['languagepack_edit_log'], $this->lng['log_extra_ok'] . ' title=' . $title . ' id=' . $lpid);
         exit('true');
     }
 }
Example #3
0
 function onclasssave()
 {
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $integra = $this->fun->accept('integra', 'P');
     $integra = empty($integra) ? 0 : $integra;
     $rankname = $this->fun->accept('rankname', 'P');
     $isinter = $this->fun->accept('isinter', 'P');
     $db_table = db_prefix . 'member_class';
     $date = time();
     if ($inputclass == 'add') {
         $db_field = 'rankname,isinter,integra,isclass,lockin';
         $db_values = "'{$rankname}',{$isinter},{$integra},0,0";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $this->writelog($this->lng['memclassmanage_add_log'], $this->lng['log_extra_ok'] . ' rankname=' . $rankname);
         $this->dbcache->clearcache('memberclass_array', true);
         exit('true');
     } elseif ($inputclass == 'edit') {
         $mcid = $this->fun->accept('mcid', 'P');
         $db_where = 'mcid=' . $mcid;
         $db_set = "rankname='{$rankname}',isinter={$isinter},integra={$integra}";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['memclassmanage_edit_log'], $this->lng['log_extra_ok'] . ' subjectname=' . $typename . ' sid=' . $sid);
         $this->dbcache->clearcache('memberclass_array', true);
         $this->dbcache->clearcache('memberclass_view_' . $mcid, true);
         exit('true');
     }
 }
Example #4
0
 function onrecomsave()
 {
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $mid = $this->fun->accept('mid', 'P');
     $mid = empty($mid) ? 0 : $mid;
     $lng = $this->fun->accept('lng', 'P');
     $lng = empty($lng) ? $this->sitelng : $lng;
     $labelname = $this->fun->accept('labelname', 'P');
     $db_table = db_prefix . 'document_label';
     $date = time();
     if ($inputclass == 'add') {
         $db_field = 'lng,mid,labelname';
         $db_values = "'{$lng}',{$mid},'{$labelname}'";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $this->writelog($this->lng['recommanage_add_log'], $this->lng['log_extra_ok'] . ' labelname=' . $labelname);
         $this->dbcache->clearcache('doclabel_array_' . $mid, true);
         $this->dbcache->clearcache('doclabel_array_0', true);
         exit('true');
     } elseif ($inputclass == 'edit') {
         $dlid = $this->fun->accept('dlid', 'P');
         $db_where = 'dlid=' . $dlid;
         $db_set = "labelname='{$labelname}'";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['recommanage_edit_log'], $this->lng['log_extra_ok'] . ' labelname=' . $labelname . ' dlid=' . $dlid);
         $this->dbcache->clearcache('doclabel_array_' . $mid, true);
         $this->dbcache->clearcache('doclabel_array_0', true);
         exit('true');
     }
 }
Example #5
0
 function lib_menu()
 {
     $this->softbase(true);
     parent::start_template();
     $this->ectemplates->caching = false;
     $this->ectemplates->libfile = true;
 }
Example #6
0
 function onsmssendedit()
 {
     parent::start_template();
     $tab = $this->fun->accept('tab', 'R');
     $tab = empty($tab) ? 'true' : $tab;
     $type = $this->fun->accept('type', 'R');
     $type = empty($type) ? 'edit' : $type;
     $smsid = intval($this->fun->accept('smsid', 'R'));
     if (empty($smsid)) {
         exit('false');
     }
     $db_table = db_prefix . 'smssendlist';
     $db_where = 'smsid=' . $smsid;
     $read = $this->db->fetch_first('SELECT * FROM ' . $db_table . ' WHERE ' . $db_where);
     $typearray = $this->get_moblie_type_array($read['mobtid']);
     $this->ectemplates->assign('typelist', $typearray['list']);
     $this->ectemplates->assign('read', $read);
     $this->ectemplates->assign('path', admin_URL);
     $this->ectemplates->assign('type', $type);
     $this->ectemplates->assign('tab', $tab);
     if ($type == 'edit') {
         $this->ectemplates->display('mobliemain/sms_send_edit');
     } elseif ($type == 'send') {
         $moblielist_array = explode(',', $read['moblielist']);
         $sendhow = count($moblielist_array);
         $this->ectemplates->assign('sendhow', $sendhow);
         $this->ectemplates->display('mobliemain/sms_send_away');
     }
 }
Example #7
0
 function onsave()
 {
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $sitename = $this->fun->accept('sitename', 'P');
     $sitehttp = $this->fun->accept('sitehttp', 'P');
     $sitedir = $this->fun->accept('sitedir', 'P');
     $sitecode = $this->fun->accept('sitecode', 'P');
     $siteip = $this->fun->accept('siteip', 'P');
     $adminusername = $this->fun->accept('adminusername', 'P');
     $time = time();
     $db_table = db_prefix . 'site';
     if ($inputclass == 'add') {
         $db_field = 'pid,sitename,sitehttp,sitedir,sitecode,siteip,adminusername,addtime';
         $db_values = "50,'{$sitename}','{$sitehttp}','{$sitedir}','{$sitecode}','{$siteip}','{$adminusername}',{$time}";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $this->writelog($this->lng['sitemain_log_add'], $this->lng['log_extra_ok'] . ' 群点名称=' . $sitename);
         exit('true');
     } else {
         $slid = $this->fun->accept('slid', 'P');
         $db_where = 'slid=' . $slid;
         $db_set = "sitename='{$sitename}',sitehttp='{$sitehttp}',sitedir='{$sitedir}',sitecode='{$sitecode}',siteip='{$siteip}',adminusername='******'";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['sitemain_log_edit'], $this->lng['log_extra_ok'] . ' 群点名称=' . $sitename . ' id=' . $slid);
         exit('true');
     }
 }
Example #8
0
 function onacmessagere()
 {
     parent::start_template();
     $tab = $this->fun->accept('tab', 'R');
     $tab = empty($tab) ? 'true' : $tab;
     $type = $this->fun->accept('type', 'R');
     $type = empty($type) ? 'edit' : $type;
     $dmid = intval($this->fun->accept('dmid', 'R'));
     if (empty($dmid)) {
         exit('false');
     }
     $read = $this->get_docmessage_veiw($dmid);
     $reBook = $this->get_documentview($read['did']);
     $this->ectemplates->assign('articelread', $reBook);
     if (!empty($read['userid'])) {
         $rsMember = $this->get_member(null, $read['userid']);
     }
     $this->ectemplates->assign('member', $rsMember);
     if (!empty($read['adminid'])) {
         $rsAdmin = $this->get_admin_view(null, $read['adminid']);
     }
     $this->ectemplates->assign('adminview', $rsAdmin);
     $input_default = $this->CON;
     $this->ectemplates->assign('defaultinput', $input_default);
     $this->ectemplates->assign('lng', $read['lng']);
     $this->ectemplates->assign('read', $read);
     $this->ectemplates->assign('path', admin_URL);
     $this->ectemplates->assign('type', $type);
     $this->ectemplates->assign('tab', $tab);
     $this->ectemplates->display('article/article_message_edit');
 }
Example #9
0
 function onskinadd()
 {
     parent::start_template();
     $tab = $this->fun->accept('tab', 'G');
     $tab = empty($tab) ? 'true' : $tab;
     $this->ectemplates->assign('tab', $tab);
     $this->ectemplates->assign('lng', $lng['list']);
     $this->ectemplates->display('template/skin_add');
 }
Example #10
0
 function onpifrmat()
 {
     parent::start_template();
     $tmid = $this->fun->accept('tmid', 'R');
     $db_table = db_prefix . 'templates';
     $db_where = 'tmid=' . $tmid;
     $read = $this->db->fetch_first('SELECT * FROM ' . $db_table . ' WHERE ' . $db_where);
     $read['templatecontent'] = stripslashes(htmlspecialchars_decode($read['templatecontent']));
     $this->ectemplates->assign('read', $read);
     $this->ectemplates->display('template/printtemplate_frame');
 }
Example #11
0
 function onsmstemplateedit()
 {
     parent::start_template();
     $db_table = db_prefix . 'templates';
     $tmid = intval($this->fun->accept('tmid', 'G'));
     $db_where = 'tmid=' . $tmid;
     $read = $this->db->fetch_first('SELECT * FROM ' . $db_table . ' WHERE ' . $db_where);
     $this->ectemplates->assign('tab', $tab);
     $this->ectemplates->assign('read', $read);
     $this->ectemplates->display('template/smstemplate_edit');
 }
Example #12
0
 function onpayplugedit()
 {
     parent::start_template();
     $opid = $this->fun->accept('opid', 'G');
     $db_table = db_prefix . 'order_pay';
     $db_where = 'opid=' . $opid;
     $read = $this->db->fetch_first('SELECT * FROM ' . $db_table . ' WHERE ' . $db_where);
     $paylist = unserialize($read['pluglist']);
     $this->ectemplates->assign('tab', 'true');
     $this->ectemplates->assign('read', $read);
     $this->ectemplates->assign('paylist_config', $paylist);
     $this->ectemplates->display('order/order_payplugedit');
 }
Example #13
0
 function onupgrade()
 {
     parent::start_template();
     $softvolstr = $this->CON['softvolstr'];
     $softvol = $this->CON['softvol'];
     $volarray = $this->oncheckvol();
     $digheight = $this->fun->accept('digheight', 'R');
     $this->ectemplates->assign('digheight', $digheight);
     $this->ectemplates->assign('softvol', $softvol);
     $this->ectemplates->assign('array', $volarray);
     $this->ectemplates->assign('softvolstr', $softvolstr);
     $this->ectemplates->display('admin/admin_softvol');
 }
Example #14
0
 function ongroupedit()
 {
     parent::start_template();
     $db_table = db_prefix . 'admin_powergroup';
     $id = $this->fun->accept('id', 'G');
     $db_where = 'id=' . $id;
     $rsList = $this->db->fetch_first('SELECT * FROM ' . $db_table . ' WHERE ' . $db_where);
     $powermenulist = $this->get_powermenulist();
     $powerlist = explode('|', $rsList['powerlist']);
     $this->ectemplates->assign('tab', 'true');
     $this->ectemplates->assign('groupinfo', $rsList);
     $this->ectemplates->assign('powermenulist', $powermenulist);
     $this->ectemplates->assign('powerlist', $powerlist);
     $this->ectemplates->display('admin/admin_group_edit');
 }
Example #15
0
 function oncreaterss()
 {
     parent::start_template();
     $tab = $this->fun->accept('tab', 'R');
     $tab = empty($tab) ? 'true' : $tab;
     $mid = $this->fun->accept('mid', 'R');
     $mid = empty($mid) ? 0 : $mid;
     $lng = $this->sitelng;
     $lng = empty($lng) ? $this->CON['is_alonelng'] && !empty($this->CON['home_lng']) ? $this->CON['home_lng'] : $this->CON['default_lng'] : $lng;
     $lnglist = $this->get_lng_array($lng);
     $this->ectemplates->assign('lnglist', $lnglist['list']);
     $modelarray = $this->get_model(0, $lng, 1, 2);
     $this->ectemplates->assign('modelarray', $modelarray['list']);
     $this->ectemplates->assign('tab', $tab);
     $this->ectemplates->display('creat/creat_rss');
 }
Example #16
0
 function onsave()
 {
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $shippingsn = $this->fun->accept('shippingsn', 'P');
     $content = $this->fun->accept('content', 'P');
     $oldshippingsn = $this->fun->accept('oldshippingsn', 'P');
     $db_table = db_prefix . 'order_shipreceipt';
     $db_table2 = db_prefix . 'order';
     $date = time();
     if ($inputclass == 'edit') {
         $osrid = $this->fun->accept('osrid', 'P');
         $db_where = 'osrid=' . $osrid;
         $db_set = "shippingsn='{$shippingsn}',content='{$content}'";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['shipreceiptlist_edit_log'], $this->lng['log_extra_ok'] . ' SN=' . $oldshippingsn);
         exit('true');
     } elseif ($inputclass == 'add') {
         $oid = $this->fun->accept('oid', 'P');
         $osid = $this->fun->accept('osid', 'P');
         $ordersn = $this->fun->accept('ordersn', 'P');
         $userid = $this->fun->accept('userid', 'P');
         $shippingmoney = $this->fun->accept('shippingmoney', 'P');
         $isclass = $this->fun->accept('isclass', 'P');
         $username = $this->esp_username;
         $db_field = 'oid,osid,shippingsn,ordersn,shippingmoney,username,content,userid,isclass,addtime';
         $db_values = "{$oid},{$osid},'{$shippingsn}','{$ordersn}',{$shippingmoney},'{$username}','{$content}',{$userid},{$isclass},{$date}";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $db_where = 'oid=' . $oid;
         if ($isclass == 1) {
             if ($this->CON['is_moblie']) {
                 $rsMember = $this->get_member('', $userid);
                 if ($rsMember['ismoblie'] && !empty($rsMember['mobile'])) {
                     $rsMember['ordersn'] = $ordersn;
                     $rsMember['shippingsn'] = $shippingsn;
                     $this->membersmssend($rsMember, $rsMember['mobile'], 'orderre');
                 }
             }
             $db_set = "shippingsn='{$shippingsn}',shippingtime={$date},ordertype=4";
         } elseif ($isclass == 2) {
             $db_set = "ordertype=8";
         }
         $this->db->query('UPDATE ' . $db_table2 . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['shipreceiptlist_add_log'], $this->lng['log_extra_ok'] . ' shippingsn=' . $shippingsn);
         exit('true');
     }
 }
Example #17
0
 function onsave()
 {
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $lng = $this->fun->accept('lng', 'P');
     $lng = empty($lng) ? $this->CON['default_lng'] : $lng;
     $typename = $this->fun->accept('typename', 'P');
     $content = $this->fun->accept('content', 'P');
     $content = empty($content) ? '' : $this->fun->Text2Html($content);
     $purview = $this->fun->accept('purview', 'P');
     $ispage = $this->fun->accept('ispage', 'P');
     $isclass = $this->fun->accept('isclass', 'P');
     $pagemax = $this->fun->accept('pagemax', 'P');
     $listmax = $this->fun->accept('listmax', 'P');
     $isaddclass = $this->fun->accept('isaddclass', 'P');
     $ismail = $this->fun->accept('ismail', 'P');
     $putmail = $this->fun->accept('putmail', 'P');
     $mailcode = $this->fun->accept('mailcode', 'P');
     $ismenu = $this->fun->accept('ismenu', 'P');
     $isseccode = $this->fun->accept('isseccode', 'P');
     $inputtime = $this->fun->accept('inputtime', 'P');
     $iswap = $this->fun->accept('iswap', 'P');
     $issms = $this->fun->accept('issms', 'P');
     $smscode = $this->fun->accept('smscode', 'P');
     $istemplates = $this->fun->accept('istemplates', 'P');
     $istemplates = empty($istemplates) ? 0 : $istemplates;
     $templates = $this->fun->accept('templates', 'P');
     $db_table = db_prefix . 'bbs_typelist';
     $date = time();
     if ($inputclass == 'add') {
         $db_field = 'pid,lng,typename,content,purview,ispage,isclass,addtime,pagemax,listmax,isaddclass,ismail,putmail,mailcode,ismenu,isseccode,inputtime,iswap,istemplates,templates,issms,smscode';
         $db_values = "50,'{$lng}','{$typename}','{$content}',{$purview},{$ispage},1,{$date},{$pagemax},{$listmax},{$isaddclass},{$ismail},'{$putmail}','{$mailcode}',{$ismenu},{$isseccode},{$inputtime},{$iswap},{$istemplates},'{$templates}',{$issms},'{$smscode}'";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $this->writelog($this->lng['forumtype_add_log'], $this->lng['log_extra_ok'] . ' typename=' . $typename);
         $this->dbcache->clearcache('bbs_typelist_array_' . $lng, true);
         exit('true');
     } elseif ($inputclass == 'edit') {
         $btid = $this->fun->accept('btid', 'P');
         $db_where = 'btid=' . $btid;
         $db_set = "typename='{$typename}',content='{$content}',purview={$purview},ispage={$ispage},pagemax={$pagemax},listmax={$listmax},isaddclass={$isaddclass},ismail={$ismail},putmail='{$putmail}',mailcode='{$mailcode}',ismenu={$ismenu},isseccode={$isseccode},inputtime={$inputtime},iswap={$iswap},istemplates={$istemplates},templates='{$templates}',issms={$issms},smscode='{$smscode}'";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['forumtype_edit_log'], $this->lng['log_extra_ok'] . ' typename=' . $typename . ' id=' . $btid);
         $this->dbcache->clearcache('bbs_typelist_view_' . $btid, true);
         $this->dbcache->clearcache('bbs_typelist_array_' . $lng, true);
         exit('true');
     }
 }
Example #18
0
 function onadverttypeedit()
 {
     parent::start_template();
     $tab = $this->fun->accept('tab', 'R');
     $tab = empty($tab) ? 'true' : $tab;
     $type = $this->fun->accept('type', 'R');
     $type = empty($type) ? 'edit' : $type;
     $atid = intval($this->fun->accept('atid', 'R'));
     if (empty($atid)) {
         exit('false');
     }
     $read = $this->get_advert_type_view($atid);
     $input_default = $this->CON;
     $this->ectemplates->assign('defaultinput', $input_default);
     $this->ectemplates->assign('lng', $read['lng']);
     $this->ectemplates->assign('read', $read);
     $this->ectemplates->assign('path', admin_URL);
     $this->ectemplates->assign('type', $type);
     $this->ectemplates->assign('tab', $tab);
     $this->ectemplates->display('advert/advert_type_edit');
 }
Example #19
0
 function onsave()
 {
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $bankname = $this->fun->accept('bankname', 'P');
     $bankaccount = $this->fun->accept('bankaccount', 'P');
     $content = $this->fun->accept('content', 'P');
     $paysn = $this->fun->accept('paysn', 'P');
     $db_table = db_prefix . 'order_payreceipt';
     $db_table2 = db_prefix . 'order';
     $date = time();
     if ($inputclass == 'edit') {
         $oprid = $this->fun->accept('oprid', 'P');
         $db_where = 'oprid=' . $oprid;
         $db_set = "bankname='{$bankname}',bankaccount='{$bankaccount}',content='{$content}'";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['payreceiptlist_edit_log'], $this->lng['log_extra_ok'] . ' SN=' . $paysn);
         exit('true');
     } elseif ($inputclass == 'add') {
         $oid = $this->fun->accept('oid', 'P');
         $opid = $this->fun->accept('opid', 'P');
         $ordersn = $this->fun->accept('ordersn', 'P');
         $userid = $this->fun->accept('userid', 'P');
         $orderamount = $this->fun->accept('orderamount', 'P');
         $isclass = $this->fun->accept('isclass', 'P');
         $username = $this->esp_username;
         $db_field = 'oid,opid,paysn,ordersn,orderamount,bankaccount,bankname,username,content,userid,isclass,paytime,addtime';
         $db_values = "{$oid},{$opid},'{$paysn}','{$ordersn}',{$orderamount},'{$bankaccount}','{$bankname}','{$username}','{$content}',{$userid},{$isclass},{$date},{$date}";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $db_where = 'oid=' . $oid;
         if ($isclass == 1) {
             $db_set = "paysn='{$paysn}',paytime={$date},ordertype=2";
         } elseif ($isclass == 2) {
             $db_set = "ordertype=7";
         }
         $this->db->query('UPDATE ' . $db_table2 . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['payreceiptlist_add_log'], $this->lng['log_extra_ok'] . ' paysn=' . $paysn);
         exit('true');
     }
 }
Example #20
0
 function onmodenlist()
 {
     parent::start_template();
     $db_table = db_prefix . 'apply';
     $sql = 'SELECT * FROM ' . $db_table . ' WHERE isetup=1 ORDER BY appid ASC';
     $rs = $this->db->query($sql);
     while ($rsList = $this->db->fetch_assoc($rs)) {
         $rsList['updatevol'] = $this->appupdate($rsList['applycode']);
         $array[] = $rsList;
     }
     $this->ectemplates->assign('array', $array);
     $sql = 'SELECT * FROM ' . $db_table . ' WHERE isetup=0 ORDER BY appid DESC';
     $rs = $this->db->query($sql);
     while ($rsList = $this->db->fetch_assoc($rs)) {
         $noinstallarray[] = $rsList;
     }
     $this->ectemplates->assign('noinstallarray', $noinstallarray);
     $loadurl = convert_uudecode($this->CON['getnetval']);
     $this->ectemplates->assign('loadurl', $loadurl);
     $this->ectemplates->assign('sql', $sql);
     $this->ectemplates->display('admin/admin_app_list');
 }
Example #21
0
 function onprint()
 {
     parent::start_template();
     $eid = $this->fun->accept('eid', 'G');
     $db_table = db_prefix . 'enquiry';
     $db_where = ' WHERE eid=' . $eid;
     $read = $this->db->fetch_first('SELECT * FROM ' . $db_table . $db_where);
     $db_table = db_prefix . 'enquiry_info';
     $sql = 'SELECT * FROM ' . $db_table . $db_where . ' ORDER BY eiid DESC';
     $rs = $this->db->query($sql);
     $arrayList = array();
     while ($rsList = $this->db->fetch_assoc($rs)) {
         $array[] = $rsList;
     }
     $read['province'] = $this->get_cityview($read['province'], 'cityname');
     $read['city'] = $this->get_cityview($read['city'], 'cityname');
     $read['district'] = $this->get_cityview($read['district'], 'cityname');
     $sread = array();
     $sread['order_companyname'] = $this->CON['order_companyname'];
     $sread['order_contact'] = $this->CON['order_contact'];
     $sread['order_province'] = $this->CON['order_province'];
     $sread['order_city'] = $this->CON['order_city'];
     $sread['order_add'] = $this->CON['order_add'];
     $sread['order_post'] = $this->CON['order_post'];
     $sread['order_tel'] = $this->CON['order_tel'];
     $sread['order_moblie'] = $this->CON['order_moblie'];
     $sread['admine_mail'] = $this->CON['admine_mail'];
     $sread['domain'] = $this->CON['domain'];
     $this->ectemplates->assign('sread', $sread);
     $this->ectemplates->assign('order', $read);
     $this->ectemplates->assign('array', $array);
     $this->ectemplates->display('enquiry/enquiry_print');
 }
Example #22
0
 function onsave()
 {
     parent::start_template();
     $date = time();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $lng = $this->fun->accept('lng', 'P');
     $bid = $this->fun->accept('bid', 'P');
     $btid = $this->fun->accept('btid', 'P');
     $title = $this->fun->accept('title', 'P');
     $content = $this->fun->accept('content', 'P');
     $username = $this->fun->accept('username', 'P');
     $email = $this->fun->accept('email', 'P');
     $qq = $this->fun->accept('qq', 'P');
     $qq = empty($qq) ? 0 : $qq;
     $msn = $this->fun->accept('msn', 'P');
     $address = $this->fun->accept('address', 'P');
     $tel = $this->fun->accept('tel', 'P');
     $mobile = $this->fun->accept('mobile', 'P');
     $db_table = db_prefix . 'bbs';
     $adminid = $this->ec_member_username_id;
     $adminid = empty($adminid) ? 0 : $adminid;
     $ipadd = $this->fun->ip($_SERVER['REMOTE_ADDR']);
     if ($inputclass == 'edit') {
         if (empty($bid)) {
             exit('false');
         }
         $db_where = 'bid=' . $bid;
         $db_set = "adminid={$adminid},title='{$title}',content='{$content}',username='******',email='{$email}',qq={$qq},msn='{$msn}',address='{$address}',tel='{$tel}',mobile='{$mobile}'";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['forummain_edit_log'], $this->lng['log_extra_ok'] . ' title=' . $title . ' id=' . $bid);
         $this->dbcache->clearcache('bbs_list_array_' . $btid, true);
         exit('true');
     } elseif ($inputclass == 'add') {
         $reemail = $this->fun->accept('reemail', 'P');
         if ($btid) {
             $typeread = $this->get_bbstype_view($btid);
         }
         $db_field = 'btid,upbid,adminid,userid,lng,title,content,username,email,qq,msn,address,tel,mobile,replynum,click,addtime,retime,isclass,istop,ipadd';
         $db_values = "{$btid},{$bid},{$adminid},0,'{$lng}','{$title}','{$content}','','','','','','','',0,0,{$date},{$date},1,0,'{$ipadd}'";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $db_where = 'bid=' . $bid;
         $db_set = "replynum=1,retime={$date}";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         if ($typeread['ismail'] && $this->CON['is_email']) {
             if (preg_match("/^\\w+((-\\w+)|(\\.\\w+))*\\@[A-Za-z0-9]+((\\.|-)[A-Za-z0-9]+)*\\.[A-Za-z0-9]+\$/i", $reemail)) {
                 $this->forumsendmail('forumre', $bid, $reemail);
             }
         }
         $this->writelog($this->lng['forummain_add_log'], $this->lng['log_extra_ok'] . ' title=' . $title . ' id=' . $bid);
         exit('true');
     }
 }
Example #23
0
 function oncreatesubwindow()
 {
     parent::start_template();
     $read['lng'] = $this->fun->accept('lng', 'R');
     $read['mid'] = $this->fun->accept('mid', 'R');
     $read['sid'] = $this->fun->accept('sid', 'R');
     $read['time'] = time();
     $is_html = $this->CON['is_html'];
     $this->ectemplates->assign('is_html', $is_html);
     $this->ectemplates->assign('read', $read);
     $this->ectemplates->display('creat/create_subject_window');
 }
Example #24
0
 function onsave()
 {
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $fvid = $this->fun->accept('fvid', 'P');
     if (empty($fvid)) {
         exit('false');
     }
     $email = $this->fun->accept('email', 'P');
     $isreply = $this->fun->accept('isreply', 'P');
     $ismail = $this->fun->accept('ismail', 'P');
     $content = $this->fun->accept('content', 'P');
     $db_table = db_prefix . 'form_value';
     $date = time();
     if ($inputclass == 'edit' && $isreply == 0) {
         $username = $this->esp_username;
         $db_where = 'fvid=' . $fvid;
         $db_set = "retime={$date},username='******',recontent='{$content}'";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         if ($this->CON['is_email'] && $isreply == 0 && $ismail) {
             $this->formmailsend('formreremind', $fvid, $email);
         }
         $this->writelog($this->lng['formmessmain_edit_log'], $this->lng['log_extra_ok'] . ' fvid=' . $fvid . ' username='******'true');
     }
 }
Example #25
0
 function onbaiducreate()
 {
     parent::start_template();
     $tab = $this->fun->accept('tab', 'R');
     $tab = empty($tab) ? 'true' : $tab;
     $lng = $this->sitelng;
     $lng = empty($lng) ? $this->CON['is_alonelng'] && !empty($this->CON['home_lng']) ? $this->CON['home_lng'] : $this->CON['default_lng'] : $lng;
     $file_sitemapdir = $this->CON['file_sitemapdir'];
     $this->ectemplates->assign('tab', $tab);
     $this->ectemplates->assign('htmldir', $file_sitemapdir);
     $this->ectemplates->display('creat/creat_baidu');
 }
Example #26
0
 function ondocedit()
 {
     parent::start_template();
     $tab = $this->fun->accept('tab', 'R');
     $tab = empty($tab) ? 'true' : $tab;
     $type = $this->fun->accept('type', 'R');
     $type = empty($type) ? 'edit' : $type;
     $did = intval($this->fun->accept('did', 'R'));
     $mid = intval($this->fun->accept('mid', 'R'));
     $mid = empty($mid) ? 0 : $mid;
     $tid = intval($this->fun->accept('tid', 'R'));
     $tid = empty($tid) ? 0 : $tid;
     if (empty($did)) {
         exit('false');
     }
     $docview = $this->get_document($did);
     if (empty($docview['color'])) {
         $docview['color'] = $this->CON['input_color'];
     }
     $mid = empty($docview['mid']) ? $mid : $docview['mid'];
     $tid = empty($docview['tid']) ? $tid : $docview['tid'];
     $lng = $docview['lng'];
     $typeread = $this->get_type($tid);
     $this->ectemplates->assign('typeread', $typeread);
     $typelist = $this->get_typeselect($mid, 0, $tid, $lng, 0, 1, false, false);
     $this->ectemplates->assign('typelist', $typelist);
     $extid_array = !empty($docview['extid']) ? explode(',', $docview['extid']) : array();
     $this->ectemplates->assign('extid', $extid_array);
     $memberpuv = $this->get_member_purview_array($docview['purview']);
     $this->ectemplates->assign('memberpuvlist', $memberpuv['list']);
     $modelatt = $this->get_modelattArray($mid, false);
     if (is_array($modelatt)) {
         foreach ($modelatt as $key => $value) {
             if ($value['inputtype'] == 'select' || $value['inputtype'] == 'radio') {
                 foreach ($value['attrvalue'] as $key2 => $value2) {
                     if (trim($docview[$value['attrname']]) == trim($value2['name'])) {
                         $modelatt[$key]['attrvalue'][$key2]['selected'] = 'selected';
                     }
                 }
             } elseif ($value['inputtype'] == 'checkbox') {
                 $expvale = explode(',', $docview[$value['attrname']]);
                 foreach ($value['attrvalue'] as $key2 => $value2) {
                     if (in_array($value2['name'], $expvale)) {
                         $modelatt[$key]['attrvalue'][$key2]['selected'] = 'selected';
                     }
                 }
             } else {
                 $modelatt[$key]['attrvalue'] = $docview[$value['attrname']];
             }
         }
     }
     $this->ectemplates->assign('modelatt', $modelatt);
     $modelview = $this->get_modelview($mid);
     $this->ectemplates->assign('modelview', $modelview);
     $subjectlistarray = $this->get_subjectlist_array($docview['sid'], $mid, $lng);
     $this->ectemplates->assign('subjectlistarray', $subjectlistarray['list']);
     $formarray = $this->get_form_array($docview['fgid'], $lng);
     $this->ectemplates->assign('formarray', $formarray['list']);
     $piclist = $this->get_album_array($did);
     $piclist['num'] = $piclist['num'] + 1;
     $this->ectemplates->assign('picarray', $piclist['list']);
     $this->ectemplates->assign('piccount', $piclist['num']);
     $this->ectemplates->assign('aidlist', $piclist['aidlist']);
     $linkdid = $this->get_document_link($docview['linkdid']);
     $this->ectemplates->assign('linkdid', $linkdid['list']);
     $doclabel = $this->get_doclabel_array($docview['recommend'], $mid, $lng);
     $this->ectemplates->assign('doclabel', $doclabel['list']);
     if ($modelview['istsn'] && empty($docview['tsn'])) {
         $tsnArray = array('s' => rand(100, 999), 'datetime' => date("YmdHis"), 'data' => date("Ymd"), 'y' => date("Y"), 'm' => date("m"), 'd' => date("d"));
         $docview['tsn'] = $this->get_htmlfilename($modelview['tsnstyle'], $tsnArray);
     }
     $input_default = $this->CON;
     $this->ectemplates->assign('defaultinput', $input_default);
     $this->ectemplates->assign('lng', $lng);
     $this->ectemplates->assign('read', $docview);
     $this->ectemplates->assign('path', admin_URL);
     $this->ectemplates->assign('mid', $mid);
     $this->ectemplates->assign('tid', $tid);
     $this->ectemplates->assign('tab', $tab);
     $this->ectemplates->assign('type', $type);
     $this->ectemplates->display('article/article_edit');
 }
Example #27
0
 function onsubsave()
 {
     include_once admin_ROOT . adminfile . '/include/command_templatesdir.php';
     include_once admin_ROOT . 'public/class_pingying.php';
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $lng = $this->sitelng;
     $lng = empty($lng) ? $this->CON['is_alonelng'] && !empty($this->CON['home_lng']) ? $this->CON['home_lng'] : $this->CON['default_lng'] : $lng;
     $mid = $this->fun->accept('mid', 'P');
     $mid = empty($mid) ? 0 : $mid;
     $pagemax = $this->fun->accept('pagemax', 'P');
     $pagemax = empty($pagemax) ? 0 : $pagemax;
     $subjectname = $this->fun->accept('subjectname', 'P');
     $content = $this->fun->accept('content', 'P');
     $content = empty($content) ? '' : $this->fun->Text2Html($content);
     $keywords = $this->fun->accept('keywords', 'P');
     $description = $this->fun->accept('description', 'P');
     $isdirname = $this->fun->accept('isdirname', 'P');
     $subpic = $this->fun->accept('subpic', 'P');
     $dirname = $this->fun->accept('dirname', 'P');
     $purview = $this->fun->accept('purview', 'P');
     $styleid = $this->fun->accept('styleid', 'P');
     $template = $this->fun->accept('template', 'P');
     $template = empty($template) ? $TEMPNAMELIST['subjectlist'] : $template;
     $indextemplates = $this->fun->accept('indextemplates', 'P');
     $indextemplates = empty($indextemplates) ? $TEMPNAMELIST['subjectindex'] : $indextemplates;
     $ishtml = $this->fun->accept('ishtml', 'P');
     $ishtml = empty($ishtml) ? 0 : $ishtml;
     $iswap = $this->fun->accept('iswap', 'P');
     $iswap = empty($iswap) ? 0 : $iswap;
     $waptempalte = $this->fun->accept('waptempalte', 'P');
     $waptempalte = empty($waptempalte) ? $TEMPNAMELIST['subjectlist'] : $waptempalte;
     $filenamestyle = $this->fun->accept('filenamestyle', 'P');
     $db_table = db_prefix . 'subjectlist';
     $date = time();
     if ($inputclass == 'add') {
         if ($isdirname) {
             $chinesespelit = new chineseSpell();
             $dirname = $chinesespelit->getFullSpell($subjectname);
         } else {
             if (!preg_match("/^[\\w-]+\$/i", $dirname)) {
                 exit('false');
             }
         }
         $db_table2 = db_prefix . 'typelist';
         $db_where = " WHERE dirname='{$dirname}' AND lng='{$lng}'";
         $countnum = $this->db_numrows($db_table, $db_where);
         if (!$isdirname) {
             if ($countnum > 0) {
                 exit('false');
             } else {
                 $countnum = $this->db_numrows($db_table2, $db_where);
                 if ($countnum > 0) {
                     exit('false');
                 }
             }
         } else {
             if ($countnum > 0) {
                 $dirname = $dirname . mt_rand(10, 99);
             } else {
                 $countnum = $this->db_numrows($db_table2, $db_where);
                 if ($countnum > 0) {
                     $dirname = $dirname . mt_rand(10, 99);
                 }
             }
         }
         $subpath = admin_ROOT . $this->CON['file_htmldir'];
         if (!$this->fun->filemode($subpath)) {
             exit('false');
         }
         if ($this->CON['is_alonelng']) {
             $subdir = $subpath . $dirname;
         } else {
             $lngdir = $this->get_lng_dirpack($lng);
             $subdir = $subpath . $lngdir . '/' . $dirname;
         }
         if (!is_dir($subdir)) {
             if (!@mkdir($subdir, 0777, true)) {
                 exit('false');
             }
         }
         $db_field = 'pid,mid,lng,subjectname,keywords,description,content,subpic,dirname,purview,isclass,styleid,indextemplates,template,filenamestyle,dirpath,addtime,ishtml,iswap,waptempalte,pagemax';
         $db_values = "50,{$mid},'{$lng}','{$subjectname}','{$keywords}','{$description}','{$content}','{$subpic}','{$dirname}',{$purview},1,{$styleid},'{$indextemplates}','{$template}','{$filenamestyle}','{$dirname}',{$date},{$ishtml},{$iswap},'{$waptempalte}',{$pagemax}";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $this->writelog($this->lng['subjectmanage_add_log'], $this->lng['log_extra_ok'] . ' subjectname=' . $subjectname);
         $this->dbcache->clearcache('subjectlist_array_' . $lng, true);
         exit('true');
     } elseif ($inputclass == 'edit') {
         $sid = $this->fun->accept('sid', 'P');
         $db_where = 'sid=' . $sid;
         $db_set = "subjectname='{$subjectname}',keywords='{$keywords}',description='{$description}',content='{$content}',subpic='{$subpic}',purview={$purview},styleid={$styleid},indextemplates='{$indextemplates}',template='{$template}',filenamestyle='{$filenamestyle}',ishtml={$ishtml},iswap={$iswap},waptempalte='{$waptempalte}',pagemax={$pagemax}";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['subjectmanage_edit_log'], $this->lng['log_extra_ok'] . ' subjectname=' . $typename . ' sid=' . $sid);
         $this->dbcache->clearcache('subjectlist_view_' . $sid, true);
         $this->dbcache->clearcache('subjectlist_array_' . $lng, true);
         exit('true');
     }
 }
Example #28
0
 function onmailinviteinput()
 {
     parent::start_template();
     $tab = $this->fun->accept('tab', 'R');
     $tab = empty($tab) ? 'true' : $tab;
     $mlvid = intval($this->fun->accept('mlvid', 'R'));
     if (empty($mlvid)) {
         exit('false');
     }
     $db_table = db_prefix . 'mailinvite_type';
     $db_where = 'mlvid=' . $mlvid;
     $read = $this->db->fetch_first('SELECT * FROM ' . $db_table . ' WHERE ' . $db_where);
     $input_default = $this->CON;
     $this->ectemplates->assign('defaultinput', $input_default);
     $this->ectemplates->assign('lng', $lng);
     $this->ectemplates->assign('read', $read);
     $this->ectemplates->assign('tab', $tab);
     $this->ectemplates->display('mailinvite/mailinvite_mail_batadd');
 }
Example #29
0
 function onkeylinktypesave()
 {
     parent::start_template();
     $inputclass = $this->fun->accept('inputclass', 'P');
     $keytypename = $this->fun->accept('keytypename', 'P');
     $keyworklist = $this->fun->accept('keyworklist', 'P');
     $description = $this->fun->accept('description', 'P');
     $mid = $this->fun->accept('mid', 'P');
     $tid = $this->fun->accept('tid', 'P');
     $lng = $this->sitelng;
     $lng = empty($lng) ? $this->CON['is_alonelng'] && !empty($this->CON['home_lng']) ? $this->CON['home_lng'] : $this->CON['default_lng'] : $lng;
     $db_table = db_prefix . 'keylink_type';
     if ($inputclass == 'add') {
         $db_field = 'lng,mid,tid,keytypename,keyworklist,description,isclass';
         $db_values = "'{$lng}',{$mid},{$tid},'{$keytypename}','{$keyworklist}','{$description}',1";
         $this->db->query('INSERT INTO ' . $db_table . ' (' . $db_field . ') VALUES (' . $db_values . ')');
         $this->writelog($this->lng['seomanage_type_add_log'], $this->lng['log_extra_ok'] . ' keytypename=' . $keytypename);
         $this->dbcache->clearcache('keylinktype_array_' . $lng, true);
         exit('true');
     } else {
         $id = $this->fun->accept('id', 'P');
         $db_where = 'ktid=' . $id;
         $db_set = "tid={$tid},keytypename='{$keytypename}',keyworklist='{$keyworklist}',description='{$description}'";
         $this->db->query('UPDATE ' . $db_table . ' SET ' . $db_set . ' WHERE ' . $db_where);
         $this->writelog($this->lng['seomanage_type_edit_log'], $this->lng['log_extra_ok'] . ' keytypename=' . $keytypename . ' id=' . $id);
         $this->dbcache->clearcache('keylinktype_array_' . $lng, true);
         $this->dbcache->clearcache('keylinktype_view_' . $id, true);
         exit('true');
     }
 }
Example #30
0
 function onprintorder()
 {
     parent::start_template();
     $class = $this->fun->accept('class', 'G');
     $oid = $this->fun->accept('oid', 'G');
     $db_table = db_prefix . 'order';
     $db_where = 'oid=' . $oid;
     $read = $this->db->fetch_first('SELECT * FROM ' . $db_table . ' WHERE ' . $db_where);
     $read['payname'] = $this->get_payplug_view($read['opid'], 'payname');
     $read['shipname'] = $this->get_shipplug_view($read['osid'], 'title');
     $read['province'] = $this->get_cityview($read['province'], 'cityname');
     $read['city'] = $this->get_cityview($read['city'], 'cityname');
     $read['district'] = $this->get_cityview($read['district'], 'cityname');
     $productmoney = $read['productmoney'];
     $dis = 100 - $read['discount'] / $productmoney * 100;
     $db_table = db_prefix . 'order_info';
     $db_where = " WHERE oid={$oid}";
     $sql = 'SELECT oiid,oid,did,tsn,title,oprice,bprice,countprice,amount,inventory FROM ' . $db_table . $db_where . ' ORDER BY oiid DESC';
     $rs = $this->db->query($sql);
     $arrayList = array();
     while ($rsList = $this->db->fetch_assoc($rs)) {
         $didlist .= $rsList['did'] . ',';
         $endid = $rsList['did'];
         $array[] = $rsList;
     }
     $sread = array();
     $sread['order_companyname'] = $this->CON['order_companyname'];
     $sread['order_contact'] = $this->CON['order_contact'];
     $sread['order_province'] = $this->CON['order_province'];
     $sread['order_city'] = $this->CON['order_city'];
     $sread['order_add'] = $this->CON['order_add'];
     $sread['order_post'] = $this->CON['order_post'];
     $sread['order_tel'] = $this->CON['order_tel'];
     $sread['order_moblie'] = $this->CON['order_moblie'];
     $sread['admine_mail'] = $this->CON['admine_mail'];
     $sread['domain'] = $this->CON['domain'];
     $this->ectemplates->assign('dis', $dis);
     $this->ectemplates->assign('sread', $sread);
     $this->ectemplates->assign('order', $read);
     $this->ectemplates->assign('array', $array);
     if ($class == 1) {
         $this->ectemplates->display('order/order_orderprint1');
     }
     if ($class == 2) {
         $this->ectemplates->display('order/order_orderprint2');
     }
 }