'Dong Shin Church', 'EMAIL' => 'webmaster@dongshincms.com'); $config['EMAIL_DEFAULT'] = array('NAME' => 'Dong Shin Church', 'EMAIL' => 'webmaster@dongshincms.com'); $config['EMAIL_CONTACTUS'] = array('NAME' => 'Dong Shin Church', 'EMAIL' => 'webmaster@dongshincms.com'); $config['PAGE_TITLE_BASE'] = 'Dongshin CMS'; $config['PAGE_TITLE'] = ''; $config['PAGE_KEYWORDS'] = 'Dongshin CMS'; $config['PAGE_DESCRIPTION'] = 'Dongshin CMS'; $config['DB_TYPE'] = 'mysql'; $config['DB_HOST'] = 'localhost'; $config['DB_NAME'] = 'dongshincms_dev'; $config['DB_UID'] = 'dongshincms'; $config['DB_PWD'] = 'ds021801'; $config['DB_NAMESET'] = 'utf8'; $config['PROFILE_PWDMIN'] = 6; $config['BBS_PWDMIN'] = 4; $config['SECURITY_DEFAULT'] = array( 'home' => constant('sec_read'), 'signin' => constant('sec_update'), 'signout' => constant('sec_read'), 'upload' => constant('sec_update'), 'forum_write' => constant('sec_none'), 'register' => constant('sec_update'), 'forgotpwd' => constant('sec_update'), 'contactus' => constant('sec_update'), 'calculator' => constant('sec_read'), ); $config['SECURITY_MEMBER'] = array( 'form' => constant('sec_read') | constant('sec_edit') | constant('sec_add'), 'forum_write' => constant('sec_read') | constant('sec_edit') | constant('sec_add'), 'forum_article' => constant('sec_read') | constant('sec_edit') | constant('sec_add') | constant('sec_delete'), ); $config['USE_SITELOG'] = false; ?>'', 'exec'=>'', 'act'=>'', 'id'=>'', 'qry'=>'', 'filter'=>'', 'menu_main'=>array(), 'menu_top'=>array(), ); $rsx = array( 'ok'=>true, 'id'=>'', 'data'=>'', 'code'=>0, 'mst'=>'', // message title 'msg'=>'', // message details 'go'=>'', 'go_type'=>0, //0:no action, 1:go, 2:replace, 3:replace-mother-href & close current window 'disp_type'=>0, // 0:normal, 1:off headers, 2:off framepage, 3:off headers & off framepage, 4:off_page 'HTML'=>'', ); $pgx = array( 'no_cache'=>true, 'title'=>'', 'title_base'=>$config['PAGE_TITLE_BASE'], 'keywords'=>$config['PAGE_KEYWORDS'], 'description'=>$config['PAGE_DESCRIPTION'], 'print'=>false, 'extend'=>'extend_both', 'menu_text'=>array( 'menu_main'=>'%MENU%', 'menu_top'=>'%MENU%', 'menu_left'=>'%MENU%', 'menu_right'=>'%MENU%', 'menu_bottom'=>'%MENU%', ), ); if(profile('idx')){ $pgx['menu_main'] = array( array('id'=>'home', 'text'=>'Home', 'link'=>'/'), array('id'=>'member_org', 'text'=>'Member & Organization', 'link'=>'/member_list.html', 'items'=>array( array('id'=>'member_list', 'text'=>'Members'), array('id'=>'staff_list', 'text'=>'Staff Profile'), array('id'=>'organizations', 'text'=>'Organizations'), array('id'=>'attendance', 'text'=>'Attendance'), array('id'=>'visit_list', 'text'=>'Visiting Log'), ), ), array('id'=>'accounting', 'text'=>'Accounting', 'items'=>array( array('id'=>'offering_list', 'text'=>'Offering'), array('id'=>'online_offering_list', 'text'=>'Online Offering'), array('id'=>'check_list', 'text'=>'Check Issuance'), array('id'=>'check_preset_list', 'text'=>'Check Preset List'), array('id'=>'preset_category', 'text'=>'Preset Category'), array('id'=>'adjustment_list', 'text'=>'Adjustment List'), array('id'=>'financial_statement_list', 'text'=>'Financial Statement'), array('id'=>'bank_cleared_check_list', 'text'=>'Bank Cleared Check'), array('id'=>'bank_reconciliation_list', 'text'=>'Account Reconciliation'), ), ), array('id'=>'acctbook', 'text'=>'Accout Book Management', 'items'=>array( array('id'=>'acctbook_list', 'text'=>'Accout Book List'), array('id'=>'acctbook_close_list', 'text'=>'Accout Book Close'), ), ), array('id'=>'report', 'text'=>'Reports & Statistics', 'items'=>array( array('id'=>'report_member_list', 'text'=>'Member List'), array('id'=>'report_offering_sm_bymember', 'text'=>'Offering Summary By Members'), array('id'=>'report_offering_dt_bymember', 'text'=>'Offering Detail By Members'), array('id'=>'report_offering_sm_byacct', 'text'=>'Offering Summary By Accounts'), array('id'=>'report_offering_dt_byacct', 'text'=>'Offering Detail By Accounts'), array('id'=>'report_check_list', 'text'=>'Check Deposit List'), array('id'=>'report_offering_list', 'text'=>'Offering Data List'), array('id'=>'report_annualoffertory', 'text'=>'Annual Offering by Member'), array('id'=>'report_daily_balance', 'text'=>'Daily Balance Sheet'), ), ), array('id'=>'setup', 'text'=>'Setup & Tools', 'items'=>array( array('id'=>'vendor_list', 'text'=>'Vendor List'), array('id'=>'bank_list', 'text'=>'Bank List'), array('id'=>'acctchart', 'text'=>'Account Chart'), array('id'=>'settings', 'text'=>'Settings'), array('id'=>'user_list', 'text'=>'User List'), array('id'=>'orgduty_list', 'text'=>'Organization Duty List'), ), ), array('id'=>'help', 'text'=>'Help', 'items'=>array( array('about_CZCM'=>'about_CZCM', 'text'=>'About DongShin CMS'), ), ), array('id'=>'signout', 'text'=>'Sign out', 'link'=>'/signout'), ); } else { $pgx['menu_main'] = array( array('id'=>'home', 'text'=>'Home', 'link'=>'/'), array('id'=>'help', 'text'=>'Help', 'class'=>'help2nd', 'items'=>array( array('about_CZCM'=>'about_CZCM', 'text'=>'About Crazy Church Management'), ), ), ); } if(profile('idx')) { $tmp = array( array('id'=>'profile', 'text'=>'Profile'), array('id'=>'signout', 'text'=>'Sign out', 'link'=>'/signout'), ); } else { $tmp = array( //array('id'=>'signin', 'text'=>'Sign In'), ); } $pgx['menu_top'] = $tmp; $rqx['id'] = $_REQUEST['id']; $rqx['req'] = $_GET['l']; if($_GET['qstr']){ $path_tokens = explode('/', $_GET['qstr']); $last_token = $path_tokens[count($path_tokens)-1]; if($last_token==''){ array_pop($path_tokens); $last_token = $path_tokens[count($path_tokens)-1]; } if(preg_match("/(.+).html/i", $last_token)){ $rqx['req'] = substr($last_token, 0, strlen($last_token)-5); } else if(preg_match("/(.+).pdf/i", $last_token)){ $rqx['req'] = substr($last_token, 0, strlen($last_token)-4); } else { if(count($path_tokens)>1){ $rqx['req'] = $path_tokens[0]; $rqx['id'] = $path_tokens[1]; } else { $rqx['req'] = $last_token; //$rqx['id'] = ''; } } switch($path_tokens[0]){ case 'getdata': $rqx['req'] = 'getdata'; $rqx['mod'] = $path_tokens[1]; break; case 'member': if(''.$path_tokens[1]!=''){ $rqx['req'] = $path_tokens[0]; $rqx['id'] = $path_tokens[1]; $rqx['id_family'] = isset($path_tokens[2])?$path_tokens[2]:''; } else { $rqx['req'] = $path_tokens[0].'_list'; } break; case 'offering': $rqx['issuer'] = $path_tokens[2]; if($path_tokens[1]=='0') $rsx['go'] = '/'.$path_tokens[0].'/'.GetDateFmt(date('m/d/Y'), 'Y-m-d').($rqx['issuer']?'/'.$rqx['issuer']:''); break; case 'attendance': $rqx['req'] = $path_tokens[0]; $rqx['q_yeqr'] = $path_tokens[1]; $rqx['id'] = $path_tokens[2]; break; break; } if(count($path_tokens)>=1){ switch($path_tokens[0]){ } } } /* END: .htaccess:qstr to pageinfo */ $rqx['act'] = $_POST['a']; $rsx['id'] = $rqx['id']; if(strlen($rqx['req'])==0) $rqx['req'] = 'home'; $rqx['exec'] = $rqx['req']; if(strlen($rqx["act"])>3) die(); if(stripos($rqx["req"], '://')) die(); if(stripos($rqx["req"], '<')) die(); if(stripos($rqx["req"], '>')) die(); if(stripos($rqx["req"], '"')) die(); if(strlen($rqx["act"])) $rsx['disp_type'] = 7; $dont_read_filter = false; /* CLEAR PREVIOUS QRYSTR $tags = parse_url($_SERVER['HTTP_REFERER']); if($tags[query]){ parse_str($tags[query], $tags); if($tags[l] != $exec_l && $exec_l){ setcookie($exec_l, '', time()-3600, "/"); $dont_read_filter = true; } }*/ $rqx['filter'] = array(); if(strlen($rqx['req']) && !$dont_read_filter){ $rqx['filter'] = string_to_array($_COOKIE[$rqx['req']]); } switch($rqx['exec']){ case 'home': case 'acctbook': case 'acctbook_list': case 'acctbook_close': case 'acctbook_close_list': $rqx['body_class'] .= ' mbl'; break; } ?> '', 'stylesheet'=>'https://fonts.googleapis.com/css?family=Italianno'); break; case 'nexustree': $ret = array('script'=>'nexusTree.js', 'stylesheet'=>'nexusTree.css'); break; case 'jquery': $ret = array('script'=>'jquery-3.1.1.min.js', 'stylesheet'=>''); break; case 'underscore': $ret = array('script'=>'underscore-min.js', 'stylesheet'=>''); break; case 'actb': $ret = array('script'=>'actb.js', 'stylesheet'=>'actb.css'); break; case 'check': $ret = array('script'=>'check.js', 'stylesheet'=>'check.css'); break; case 'check_preset': $ret = array('script'=>'check_preset.js', 'stylesheet'=>'check_preset.css'); break; case 'msgbox': $ret = array('script'=>'msgbox.js', 'stylesheet'=>'msgbox.css'); break; case 'tabber': $ret = array('script'=>'tabber.js', 'stylesheet'=>'tabber.css'); break; case 'shadowbox': $ret = array('script'=>'', 'stylesheet'=>'shadowbox.css'); break; case 'popuplayer': $ret = array('script'=>'popuplayer.js', 'stylesheet'=>'popuplayer.css'); break; case 'emu_popup': $ret = array('script'=>'emu_popup.js', 'stylesheet'=>'emu_popup.css'); break; case 'popupimage': $ret = array('script'=>'popupimage.js', 'stylesheet'=>''); break; case 'file_upload': $ret = array('script'=>'file_upload.js', 'stylesheet'=>'file_upload.css'); break; case 'flashembed': $ret = array('script'=>'flashembed.js', 'stylesheet'=>''); break; case 'swfobject': $ret = array('script'=>'swfobject.js', 'stylesheet'=>''); break; case 'popuplayer': $ret = array('script'=>'popuplayer.js', 'stylesheet'=>'popuplayer.css'); break; case 'common_form': $ret = array('script'=>'common_form.js', 'stylesheet'=>''); break; case 'datepicker': $ret = array('script'=>'datepicker.js', 'stylesheet'=>'datepicker.css'); break; case 'fileattach': $ret = array('script'=>'fileattach.js', 'stylesheet'=>'fileattach.css'); break; case 'fckeditor': $ret = array('script'=>'fckeditor/fckeditor.js', 'stylesheet'=>''); break; case 'ckeditor': $ret = array('script'=>'ckeditor/ckeditor.js', 'stylesheet'=>''); break; case 'swapimage': $ret = array('script'=>'swapimage.js', 'stylesheet'=>''); break; case 'sifr': $ret = array('script'=>'sifr.js,sifr-config.js', 'stylesheet'=>'sifr.css'); break; case 'virtualearth': $ret = array('script'=>'https://dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=6.2&mkt=en-us', 'stylesheet'=>''); break; case 'yahoomap': $ret = array('script'=>'https://api.maps.yahoo.com/ajaxymap?v=3.8&appid=Tq0cnyLV34F_GEfc8iQ4.IyKuEy77A4Hth3EK5t3f1TyeZW12EC2SHPWDmMvBKdv4g--', 'stylesheet'=>''); break; case 'domprint': $ret = array('script'=>'', 'stylesheet'=>'domprint.css'); break; case 'bootstrap': $ret = array('script'=>'bootstrap.js', 'stylesheet'=>'bootstrap.css'); break; case 'querybuilder': $ret = array('script'=>'query-builder.standalone.js', 'stylesheet'=>'query-builder.default.css'); break; case 'framework7': $ret = array('script'=>'framework7.js', 'stylesheet'=>array('framework7.ios.css','framework7.ios.colors.css', 'framework7-icons.css')); break; case 'ztree': $ret = array('script'=>'jquery.ztree.all.js', 'stylesheet'=>array('zTreeStyle.css')); break; case 'jstree': $ret = array('script'=>'jstree.js', 'stylesheet'=>array('jstree/style.css')); break; case 'fileupload': $ret = array('script'=>'jquery.fileupload.js', 'stylesheet'=>array('jquery.fileupload.css')); break; case 'dropzone': $ret = array('script'=>'exif.js,dropzone.js', 'stylesheet'=>array('dropzone.css')); break; case 'jqplot': $ret = array('script'=>'jquery.jqplot.js,plugins/jqplot.pieRenderer.js,plugins/jqplot.enhancedPieLegendRenderer.js', 'stylesheet'=>array('jquery.jqplot.css')); break; case 'tablednd': $ret = array('script'=>'jquery.tablednd.js', 'stylesheet'=>''); break; case 'jquery.datepicker': $ret = array('script'=>'jquery.datepicker.js', 'stylesheet'=>'jquery.datepicker.css'); break; case 'jquery.menu': $ret = array('script'=>'jquery-menu.js', 'stylesheet'=>'jquery-menu.css'); break; default: $ret = array('script'=>'', 'stylesheet'=>''); } return $ret; } function read_menu($HTML_menuitem='%MENU%', $menu_array=null, $header='mm_', $menupath='', $menulevel=0){ $HTML = ''; $class_level = 'mv_'.$menulevel; if(is_array($menu_array)){ foreach($menu_array as $menu){ $target= ($menu['target']?' target="'.$menu['target'].'"':''); $use_menupath = false; $menu_id = $menu['id'] ? $menu['id']: 'home'; if($menu['link']){ $link = $menu['link']; } else { $link = $menu['id'] ? $menupath.'/'.$menu['id'].'.html': '/'; } $class = $header.$menu_id.' lv_'.$menulevel; $class .= $menu['selected'] ? ' selected': ''; $class .= ($HTML? '': ' first'); $class .= ($menu['class']?' '.$menu['class']:''); //onclick="menu_clicked(\''.$menu_id.'\', \''.$link.'\');" $items_HTML = ''; if($menu['items']){ $items_HTML = read_menu($HTML_menuitem, $menu['items'], $header, $menupath, $menulevel+1); } if($items_HTML || !$menu['id'] || check_security($menu['id'], constant('sec_read'))){ $menu_text = str_replace('%MENU%', htmlentities2($menu['text']), $HTML_menuitem); $menu_text = (!$items_HTML)? ''.$menu_text.'': ''; $HTML .= ($HTML? '
  • ':'
  • ') .'
  • '.$menu_text .$items_HTML; $HTML .= '
  • '; } } } return $HTML?'':''; } function include_menu($HTML_menuitem='%MENU%', $menu_array=null, $header='mm_'){ echo read_menu($HTML_menuitem, $menu_array); } function include_framepage($framepage, $with_header_footer=true, $with_framepage=true){ global $pgx; $framepage=$framepage?$framepage:'framepage'; if($with_header_footer) echo read_headers($framepage); $pgx[content_menu_top]=read_menu($pgx[menu_text][menu_top], $pgx[menu_top], 'mt_'); $pgx[content_menu_left]=read_menu($pgx[menu_text][menu_left], $pgx[menu_left], 'ml_'); $pgx[content_menu_right]=read_menu($pgx[menu_text][menu_right], $pgx[menu_right], 'mr_'); $pgx[content_menu_main]=read_menu($pgx[menu_text][menu_main], $pgx[menu_main]); $pgx[content_menu_bottom]=read_menu($pgx[menu_text][menu_bottom], $pgx[menu_bottom], 'mb_'); $pgx[directories] = get_directories(); if($with_framepage) { include_page($framepage.'.php'); } else { echo $pgx[content_page]; } if($with_header_footer) echo read_footers(); } function include_page($page=''){ global $abs_path, $rqx, $pgx; $page = $page? $page: $rqx['exec']; $subpath = '/module/'; include $abs_path.$subpath.$page; } function exec_page($page, $fullpath=false, $alt_content=false){ global $rqx, $pgx, $abs_path, $config; $contents =''; $real_path = ''; if($fullpath){ $real_path = $page; } else { $base_path = $abs_path."/module/"; $filename = $page; $filename_php = $filename.".php"; $real_path = $base_path.$filename_php; } ob_start(); if (@include $real_path) $contents = ob_get_contents(); else $contents = ($alt_content===false? 'Unable to open file "'.$filename.'"':$alt_content); ob_end_clean(); return $contents; } function read_headers($framepage){ global $pgx, $rqx; if($pgx[no_cache]){ header("Cache-Control: no-cache"); // HTTP/1.1 header("PRAGMA: NO-CACHE"); header("Expires: Sun, 19 Nov 1978 05:00:00 GMT"); header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); header("Cache-Control: no-store, no-cache, must-revalidate"); header("Cache-Control: post-check=0, pre-check=0", FALSE); } $HTML_styles =''; $HTML_scripts =''; if($pgx[library]){ foreach($pgx[library] as $key){ $item = get_library_info($key); if(!$pgx['domprint'] || $key=='domprint'){ if($item[script]){ $scripts = explode(',', $item[script]); foreach($scripts as $script){ if(substr($script, 0, 5)!='http:' && substr($script, 0, 6)!='https:') $script = '/js/'.$script; if($script) $HTML_scripts .=''."\n"; } } if($item[stylesheet]) { if(is_array($item[stylesheet])){ foreach($item[stylesheet] as $style){ if(substr($style, 0, 5)!='http:' && substr($style, 0, 6)!='https:') $style = '/css/'.$style; if($style) $HTML_styles .=''."\n"; } } else { $style = $item[stylesheet]; if(substr($style, 0, 5)!='http:' && substr($style, 0, 6)!='https:') $style = '/css/'.$style; $HTML_styles .= ''."\n"; } } } } } if(!$pgx['domprint'] && !$pgx['mobile']){ $HTML_styles = ''."\n" .''."\n" .$HTML_styles .''."\n"; $HTML_scripts = ''."\n" .$HTML_scripts .''."\n"; } if($pgx['mobile']){ $HTML_styles = ''."\n" .$HTML_styles .''."\n"; $HTML_scripts = ''."\n" .''."\n" .$HTML_scripts .''."\n"; } $HTML = ''."\n" .''."\n" .''."\n" .''.(strlen($pgx[title])?$pgx[title]." - ":"").$pgx[title_base].''."\n" .''."\n" .''."\n" .''."\n" .''."\n" .''."\n" //.''."\n" .'' .'' .'' .'' .'' .'' .'' .'' .''."\n" .''."\n" .''."\n" .''."\n" .''."\n" .''."\n" .$HTML_styles .''."\n" .''."\n" .$HTML_scripts .'
    '; return $HTML; } function read_footers(){ return "\n
    \n"; } function read_document($file){ global $abs_path; ob_start(); if (@include $abs_path."/doc/".$file) $contents = ob_get_contents(); else $contents = ($err_off)? '':'Unable to open template file "'.$file.'"'; ob_end_clean(); return $contents; } function template ($file, $vars=array(), $eval=1, $err_off=false) { global $abs_path; // htmlspecialchars($utf8_string, ENT_COMPAT, 'UTF-8') ob_start(); if (@include $abs_path."/template/".$file) $contents = ob_get_contents(); else $contents = ($err_off)? '':'Unable to open template file "'.$file.'"'; ob_end_clean(); $_NOW_ = date('m/d/Y'); foreach ($vars as $key => $val) ${$key} = $val; for ($i=0; $i)(.*)()(.*)/sim', '\1\5', $contents)) { $contents = ($hide[$i]!='')?str_replace("Start Hide ".$hide[$i]." //-->", "", $contents):$contents; $contents = ($hide[$i]!='')?str_replace("