示例#1
0
 /**
  * 버전정보 페이지입니다
  */
 public function index()
 {
     // 이벤트 라이브러리를 로딩합니다
     $eventname = 'event_admin_config_cbversion_index';
     $this->load->event($eventname);
     $view = array();
     $view['view'] = array();
     // 이벤트가 존재하면 실행합니다
     $view['view']['event']['before'] = Events::trigger('before', $eventname);
     Requests::register_autoloader();
     $headers = array('Accept' => 'application/json');
     $postdata = array('requesturl' => current_full_url(), 'package' => CB_PACKAGE, 'version' => CB_VERSION);
     $request = Requests::post(config_item('ciboard_check_latest_version'), $headers, $postdata);
     $view['view']['latest_versions'] = json_decode($request->body, true);
     if (strtolower(CB_PACKAGE) === 'premium') {
         $view['view']['latest_version_name'] = $view['view']['latest_versions']['premium_version'];
         $view['view']['latest_download_url'] = $view['view']['latest_versions']['premium_downloadurl'];
     } else {
         $view['view']['latest_version_name'] = $view['view']['latest_versions']['basic_version'];
         $view['view']['latest_download_url'] = $view['view']['latest_versions']['basic_downloadurl'];
     }
     // 이벤트가 존재하면 실행합니다
     $view['view']['event']['before_layout'] = Events::trigger('before_layout', $eventname);
     /**
      * 어드민 레이아웃을 정의합니다
      */
     $layoutconfig = array('layout' => 'layout', 'skin' => 'index');
     $view['layout'] = $this->managelayout->admin($layoutconfig, $this->cbconfig->get_device_view_type());
     $this->data = $view;
     $this->layout = element('layout_skin_file', element('layout', $view));
     $this->view = element('view_skin_file', element('layout', $view));
 }
示例#2
0
    public function render($label_template = '{title}', $back_url = NULL)
    {
        if (empty($this->mItems)) {
            return '<p>No records are found.</p>';
        } else {
            $html = modules::run('adminlte/widget/box_open', 'Sort Order', 'primary');
            // Render form with alert message
            $html .= '<form action="' . current_full_url() . '" method="POST">';
            $html .= $this->CI->system_message->render();
            $html .= '<p>Drag and drop below items to sort them in ascending order:</p>';
            // Generate item list by CodeIgniter Template Parser
            $template = '<ul class="sortable list-group">
				{items}
				<li class="list-group-item">
					<strong>' . $label_template . '</strong>
					<input type="hidden" name="' . $this->mPostName . '[]" value="{id}" />
				</li>
				{/items}
			</ul>';
            $data = array('items' => $this->mItems);
            $html .= $this->CI->parser->parse_string($template, $data, TRUE);
            if ($back_url != NULL) {
                $html .= modules::run('adminlte/widget/btn', 'Back', $back_url, 'reply', 'bg-purple') . ' ';
            }
            $html .= modules::run('adminlte/widget/btn_submit', 'Save');
            $html .= '</form>';
            $html .= modules::run('adminlte/widget/box_close');
            return $html;
        }
    }
示例#3
0
                        validDrop=false;
                }
            }
            return validDrop;
        }
        
        custom_buttons = '<span class="fc-button fc-button-today fc-state-default fc-corner-left fc-corner-right fc-state-disabled" unselectable="on" style="-moz-user-select: none;">today</span>'
        $('.fc-button-today').after(custom_buttons);
        
        custom_buttons = '<span class="fc-button fc-button-eventcopy fc-state-default fc-corner-left" unselectable="on" style="-moz-user-select: none;">Event Copy</span>'
        $('.fc-button-agendaDay').after(custom_buttons);

        $('.fc-button-eventcopy').on('click', function () {
            var moment = $('#calendar').fullCalendar('getDate');
            var d = new Date(moment);
            var url = '<?= base_url() . 'webtv/eventCopy?url='.  current_full_url().'&playlist_id=' . $this->uri->segment(3).'&date='?>' + d.getUTCFullYear() + '-' + (d.getUTCMonth() + 1) + '-' + d.getUTCDate(); 
            bootbox.dialog({message: 'wait...', title: "Event Copy"});
            $.ajax({
                type: "GET",
                url: url,
                dataType: "html",
                success: function (response) {
                    $('.modal-dialog .modal-content .modal-body .bootbox-body').html(response);
                }
            });
        });
        
        function __saveEvent(event) {
            var subUrl = "<?= base_url() ?>webtv/saveevent";
            $('.loader').html('loading.....');
            $.ajax({
										  </table>
										</div><!-- /.box-body -->
										<div class="box-footer">
											<button class="btn btn-primary btn-sm" type="submit" name="submit" value="Save"><?php echo $welcome->loadPo('Save'); ?></button>										
										</div>
									</form>
									</div><!-- /.box -->
								</div>
								<?php } ?>
								<!-- Flavors section ends -->
								
								<!-- Player section starts -->
								<?php if($tab == 'Player') {?>
								<div class="tab-pane active" id="tab_Player">
									<form action="<?php echo base_url() ?>video/setting_player" id="playerSettingForm" method="post" accept-charset="utf-8" enctype="multipart/form-data" accept-charset="utf-8" onsubmit="upload_logo_video();" >
									<input type="hidden" id="redirect_url" name="redirect_url" value="<?php echo current_full_url(); ?>" />
										<div class="box-group" id="accordion">
										<?php  $data_player = @unserialize(strip_slashes($playerData)); ?>
										<input type="hidden" name="logo_imghiddennw" id="logo_imghiddennw" value="<?php echo $data_player['file']; ?>"/>
											<div class="panel box box-solid">
												<div class="box-header">
													<h4 class="box-title">
														<a data-toggle="collapse" data-parent="#accordion" href="#collapseOne">
															<?php echo $welcome->loadPo('General')." ".$welcome->loadPo('Settings'); ?>
														</a>
													</h4>
												</div>
												<div id="collapseOne" class="panel-collapse collapse in">
													<div class="box-body">
														<div class="row">
															<div class="form-group col-lg-6">
示例#5
0
 /**
  * render add CMS page panel
  */
 public function addCmsPage()
 {
     if ('get' == strtolower($this->input->server('REQUEST_METHOD'))) {
         $this->isAdminLoggedIn(current_full_url());
         // allow only if admin is logged in
         $this->templater->setTemplate();
         // set template
         $data = array('pageTitle' => ADMIN_PAGE_TITLE_PREFIX . 'Add CMS Page', 'pageHeader' => 'Add CMS Page', 'breadCrumbs' => array('Dashboard' => site_url('admin/dashboard'), 'CMS Page List' => site_url('/admin/cms/list'), 'Add CMS Page' => 'javscript:void(0)'));
         // set generic data to view data variable
         $data['referer'] = $referer = false !== $this->input->get('ref', true) ? base64_decode($this->input->get('ref', true)) : null;
         if (!$referer) {
             // conditional checks for required parameters
             log_message('error', 'Add URL tampered from IP : ' . $this->input->Server('REMOTE_ADDR'));
             // log message
             $referer ? redirect($referer) : redirect(site_url('admin/agent-type/list'));
         }
         if ($addCmsPageUserInput = $this->session->flashdata('addCmsPageUserInput')) {
             $data['addCmsPageUserInput'] = $this->utility->convertSessionDataArrayToObject($addCmsPageUserInput);
         }
         $this->prepareDataForView($data);
         // merge with any generic data present
         $this->templater->setViewData($this->viewData);
         // set data for view
         $this->templater->render('cms/add');
         // render view
     } else {
         $this->utility->handleInvalidRequestMethod($this->input->server('REMOTE_ADDR'), 'admin/cms/list');
     }
 }
<?php if(count($advance)!='0'){ ?>
<div class="tab-pane active" id="tab_1">
    <div class="box box-solid">
        <div class="box-body">
            <div class="row">
                   <form id="metadata" name="metadata" action="" method="post">
			<input type="hidden" name="cid" value="<?php echo $_REQUEST['action']?>"/>
			 <input type="hidden" name="curl" value="<?php echo current_full_url() ?>"> 
 			<?php  foreach($advance as $advance_val){
			    if(count($fvalue[$advance_val->field_id])!=0){
			     $value_field[$advance_val->field_id] = $fvalue[$advance_val->field_id][0]->value;
			    }else {
				$value_field[$advance_val->field_id] ="";
			    } 
			     
			?>
			<div class="form-group col-lg-12">
                            <label for="exampleInputEmail1"><?php echo $advance_val->field_title; ?></label>
                            <?php if($advance_val->field_type=="text"){?>
			    <input name="<?php echo $advance_val->field_id;?>" class="form-control" id="<?php echo $advance_val->field_name;?>" type="text" placeholder="<?php echo $advance_val->field_title; ?>"   value="<?php echo $value_field[$advance_val->field_id];?>" <?php if($advance_val->field_validate == 1){ echo "required";} ?> />
			 <?php } else if($advance_val->field_type=="textarea"){?>
			  <textarea class="textarea" placeholder="<?php echo $advance_val->field_title; ?>" style="width: 100%; height: 200px; font-size: 14px; line-height: 18px; border: 1px solid #dddddd; padding: 10px;" name="<?php echo $advance_val->field_id;?>" id="<?php echo $advance_val->field_name;?>"> </textarea>
                        <?php }  else if(($advance_val->field_type=="radio")||($advance_val->field_type=="checkbox")){
			$arrRadioOption  = explode(",", $advance_val->field_options);
			$count = count($arrRadioOption);
			 for($y=0;$y<$count;$y++){
			?>
	    &nbsp;&nbsp;<input <?php  if( $value_field[$advance_val->field_id]==$arrRadioOption[$y]){?> checked <?php }?> type="<?php echo $advance_val->field_type;?>" id="<?php echo $advance_val->field_name;?>"  name="<?php echo $advance_val->field_id;?>"  value="<?php echo $arrRadioOption[$y];?>"   <?php if($advance_val->field_validate == 1){ echo "required";} ?>/>&nbsp;&nbsp;<?php echo $arrRadioOption[$y];
			} 
			 ?>
			 <?php }  ?>
示例#7
0
                <?php 
echo form_close();
$attributes = array('name' => 'verifyemailform', 'id' => 'verifyemailform');
echo form_open(current_full_url(), $attributes);
?>
                    <input type="hidden" name="findtype" value="verifyemail" />
                    <h3 class="mt30">인증메일 재발송</h3>
                    <p class="text">회원가입이나, 이메일주소 변경 후 인증 메일을 받지 못한 경우 다시 받을 수 있습니다.</p>
                    <div class="group">
                        <input type="email" name="verify_email" id="verify_email" class="input" placeholder="Email Address" />
                        <button class="btn btn-black btn-sm" type="submit">인증메일 재발송</button>
                    </div>
                <?php 
echo form_close();
$attributes = array('name' => 'changeemailform', 'id' => 'changeemailform');
echo form_open(current_full_url(), $attributes);
?>
                    <input type="hidden" name="findtype" value="changeemail" />
                    <h3 class="mt30">이메일 주소 변경</h3>
                    <p class="text">인증메일이 도착하지 않아 어려움을 겪고 계시다면, 다른 이메일 주소로 변경해 인증해보세요.</p>
                    <div class="group">
                        <span>아이디</span>
                        <div class="form-text text-primary group">
                            <input type="text" name="change_userid" id="change_userid" class="input" placeholder="User ID" />
                        </div>
                    </div>
                    <div class="group">
                        <span>비밀번호</span>
                        <div class="form-text text-primary group">
                            <input type="password" name="change_password" id="change_password" class="input" placeholder="Password" />
                        </div>
示例#8
0
                                                <td  width="350"><a href="<?php echo base_url(); ?>video/detail/<?php echo $value->id; ?>"><?php echo strlen($value->title) > 40 ?  substr($value->title,0,40).'...' : $value->title; ?></td>
                                                <td><?php echo $value->description; ?></td>
                                                <td><?php echo $value->dimension; ?></td>
                                                <td><?php if ($value->status == 1) { ?>
                                                        <img src="<?php echo base_url(); ?>assets/img/test-pass-icon.png" alt="Active" />
                                                    <?php } else { ?>
                                                        <img src="<?php echo base_url(); ?>assets/img/test-fail-icon.png" alt="Active" />
                                                    <?php } ?></td>                                            
                                                <td style='text-align:center'>                                                
                                                    <a class="prev_video" href="#myModal" data-backdrop="static" data-toggle="modal" data-img-url="<?php echo base_url().$value->path; ?>">Preview</a>                                                   
                                                </td>
                                                <td  width="120"><?php echo date('M d,Y', strtotime($value->created)); ?></td>
                                                <td  width="150"> 
                                                    <a href="<?php echo base_url(); ?>video/videoOpr/Basic?action=<?php echo base64_encode($value->id) . '&'; ?>" class="btn btn-info btn-sm"><?php echo $welcome->loadPo('Edit') ?></a>
                                                    &nbsp;
                                                    <a class="confirm" onclick="return delete_video(<?php echo $value->id; ?>, '<?php echo base_url() . 'video/deletevideo' ?>', '<?php echo current_full_url(); ?>');" href="" ><button class="btn btn-danger btn-sm" data-toggle="modal" data-target=".bs-example-modal-sm" ><?php echo $welcome->loadPo('Delete') ?></button></a>                            </td>
                                            </tr>
                                        <?php } ?>
                                    </tbody>


                                </table>
                                <!-- Pagination start --->
                                <?php
                                if ($this->pagination->total_rows == '0') {
                                    echo "<tr><td colspan=\"7\"><h4>" . $welcome->loadPo('No Record Found') . "</td></tr></h4>";
                                } else {
                                    ?>
                                    </table>

                                    <div class="row pull-left">
示例#9
0
文件: Member.php 项目: smboy86/zzing
 /**
  * 로그인 기록을 남깁니다
  */
 public function update_login_log($mem_id = 0, $success = 0, $reason = '')
 {
     $success = $success ? 1 : 0;
     $mem_id = (int) $mem_id ? (int) $mem_id : 0;
     $reason = isset($reason) ? $reason : '';
     $referer = $this->CI->input->get_post('url', null, '');
     $loginlog = array('mll_success' => $success, 'mem_id' => $mem_id, 'mll_datetime' => cdate('Y-m-d H:i:s'), 'mll_ip' => $this->CI->input->ip_address(), 'mll_reason' => $reason, 'mll_useragent' => $this->CI->agent->agent_string(), 'mll_url' => current_full_url(), 'mll_referer' => $referer);
     $this->CI->Member_login_log_model->insert($loginlog);
     return true;
 }
示例#10
0
 /**
  * 프론트페이지 레이아웃관리합니다
  */
 function front($config = array(), $device_view_type = '')
 {
     $data = array();
     $CI =& get_instance();
     if ($CI->uri->segment(1) === config_item('uri_segment_admin') && $CI->uri->segment(2) === 'preview') {
         return $this->preview($config);
     }
     $searchconfig = array('{홈페이지제목}', '{현재주소}', '{회원아이디}', '{회원닉네임}', '{회원레벨}', '{회원포인트}');
     $replaceconfig = array($CI->cbconfig->item('site_title'), current_full_url(), $CI->member->item('mem_userid'), $CI->member->item('mem_nickname'), $CI->member->item('mem_level'), $CI->member->item('mem_point'));
     $page_title = element('page_title', $config) ? element('page_title', $config) : $CI->cbconfig->item('site_meta_title_default');
     $meta_description = element('meta_description', $config) ? element('meta_description', $config) : $CI->cbconfig->item('site_meta_description_default');
     $meta_keywords = element('meta_keywords', $config) ? element('meta_keywords', $config) : $CI->cbconfig->item('site_meta_keywords_default');
     $meta_author = element('meta_author', $config) ? element('meta_author', $config) : $CI->cbconfig->item('site_meta_author_default');
     $page_name = element('page_name', $config) ? element('page_name', $config) : $CI->cbconfig->item('site_page_name_default');
     $data['page_title'] = $page_title = str_replace($searchconfig, $replaceconfig, $page_title);
     $data['meta_description'] = $meta_description = str_replace($searchconfig, $replaceconfig, $meta_description);
     $data['meta_keywords'] = $meta_keywords = str_replace($searchconfig, $replaceconfig, $meta_keywords);
     $data['meta_author'] = $meta_author = str_replace($searchconfig, $replaceconfig, $meta_author);
     $data['page_name'] = $page_name = str_replace($searchconfig, $replaceconfig, $page_name);
     $layoutdirname = $device_view_type === 'mobile' ? element('mobile_layout_dir', $config) : element('layout_dir', $config);
     if (empty($layoutdirname)) {
         $layoutdirname = $device_view_type === 'mobile' ? $CI->cbconfig->item('mobile_layout_default') : $CI->cbconfig->item('layout_default');
     }
     if (empty($layoutdirname)) {
         $layoutdirname = 'basic';
     }
     $layout = '_layout/' . $layoutdirname;
     $data['layout_skin_path'] = $layout;
     $data['layout_skin_url'] = base_url(VIEW_DIR . $data['layout_skin_path']);
     $layout .= '/';
     if (element('layout', $config)) {
         $layout .= element('layout', $config);
     }
     $data['layout_skin_file'] = $layout;
     $skindir = $device_view_type === 'mobile' ? element('mobile_skin_dir', $config) : element('skin_dir', $config);
     if (empty($skindir)) {
         $skindir = $device_view_type === 'mobile' ? $CI->cbconfig->item('mobile_skin_default') : $CI->cbconfig->item('skin_default');
     }
     if (empty($skindir)) {
         $skindir = 'basic';
     }
     $skin = '';
     if (element('path', $config)) {
         $skin .= element('path', $config) . '/';
     }
     $skin .= $skindir;
     $data['view_skin_path'] = $skin;
     $data['view_skin_url'] = base_url(VIEW_DIR . $data['view_skin_path']);
     $skin .= '/';
     if (element('skin', $config)) {
         $skin .= element('skin', $config);
     }
     $data['view_skin_file'] = $skin;
     $user_sidebar = $device_view_type === 'mobile' ? element('use_mobile_sidebar', $config) : element('use_sidebar', $config);
     if ($user_sidebar === '1') {
         $data['use_sidebar'] = '1';
     } elseif ($user_sidebar === '2') {
         $data['use_sidebar'] = '';
     } else {
         $user_sidebar = $device_view_type === 'mobile' ? $CI->cbconfig->item('mobile_sidebar_default') : $CI->cbconfig->item('sidebar_default');
         if ($user_sidebar === '1') {
             $data['use_sidebar'] = '1';
         } elseif ($user_sidebar === '2') {
             $data['use_sidebar'] = '';
         } else {
             $data['use_sidebar'] = '';
         }
     }
     $cachename = 'latest_version_from_ciboard_api';
     $cachetime = 10800;
     if (!($result = $CI->cache->get($cachename))) {
         $CI->load->library('Requests');
         $requests = new Requests();
         $requests->register_autoloader();
         $headers = array('Accept' => 'application/json');
         $postdata = array('requesturl' => current_full_url(), 'package' => CB_PACKAGE, 'version' => CB_VERSION);
         $request = $requests->post(config_item('ciboard_check_latest_version'), $headers, $postdata);
         $result['latest_versions'] = json_decode($request->body, true);
         if (strtolower(CB_PACKAGE) === 'premium') {
             $result['latest_version_name'] = $result['latest_versions']['premium_version'];
             $result['latest_download_url'] = $result['latest_versions']['premium_downloadurl'];
         } else {
             $result['latest_version_name'] = $result['latest_versions']['basic_version'];
             $result['latest_download_url'] = $result['latest_versions']['basic_downloadurl'];
         }
         $CI->cache->save($cachename, $result, $cachetime);
     }
     $data['version_latest'] = $result;
     $mem_id = (int) $CI->member->item('mem_id');
     // 현재 접속자
     $CI->load->model('Currentvisitor_model');
     $currentpage = $page_name ? $page_name : $page_title;
     $currentpage = $currentpage ? $currentpage : $CI->cbconfig->item('site_title');
     $CI->Currentvisitor_model->add_visitor($CI->input->ip_address(), $mem_id, $CI->member->item('mem_nickname'), cdate('Y-m-d H:i:s'), $currentpage, current_full_url(), $CI->agent->referrer(), $CI->agent->agent_string());
     if ($CI->cbconfig->item('open_currentvisitor') or $CI->member->is_admin() === 'super') {
         $minute = (int) $CI->cbconfig->item('currentvisitor_minute');
         if ($minute < 1) {
             $minute = 10;
         }
         $curdatetime = cdate('Y-m-d H:i:s', ctimestamp() - $minute * 60);
         $data['current_visitor_num'] = $CI->Currentvisitor_model->get_current_count($curdatetime);
     }
     // 알림
     $data['notification_num'] = 0;
     if ($CI->cbconfig->item('use_notification')) {
         if ($CI->member->is_member()) {
             $CI->load->model('Notification_model');
             $data['notification_num'] = $CI->Notification_model->unread_notification_num($mem_id);
         }
     }
     // 메뉴관리
     $CI->load->model('Menu_model');
     $data['menu'] = $CI->Menu_model->get_all_menu($device_view_type);
     //팝업관리
     $CI->load->library('popuplib');
     $data['popup'] = $CI->popuplib->display_popup();
     return $data;
 }
                                         <td  width="350"><a href="<?php echo base_url(); ?>video/detail/<?php echo $value->id; ?>"><?php echo strlen($value->title) > 40 ?  substr($value->title,0,40).'...' : $value->title; ?></td>
                                         <td><?php echo $value->category; ?></td>
                                                                                         <td style='text-align:center'>
                                             <?php if(in_array($value->minetype,array('video/wmv','video/avi'))) { ?>
                                             --
                                             <?php } else { ?>
                                             <a class="prev_video" href="#myModal" data-backdrop="static" data-toggle="modal" data-img-url="<?php echo baseurl.serverVideoRelPath.$value->file; ?>">Preview</a>
                                             <?php } ?>
                                         </td>
                                         <td  width="120"><?php echo date('M d,Y', strtotime($value->created)); ?></td>
                                         <td><a href="#" class="link" links="<?php echo base_url(); ?>webtv/unlink/<?php echo $value->vpid; ?>" ><?php echo $welcome->loadPo('Delete') ?></a></td>
                                         <td>
                                             <?php if ($value->status == '1') { ?>
                                             <a href="<?php echo base_url(); ?>webtv/changeStatus/<?php echo $value->id; ?>/0/<?= $this->uri->segment(3)?>?url=<?= current_full_url() ?>"><img src="<?php echo base_url(); ?>assets/img/test-pass-icon.png" alt="Active" /></a>
                                             <?php } else { ?>
                                                 <a href="<?php echo base_url(); ?>webtv/changeStatus/<?php echo $value->id; ?>/1/<?= $this->uri->segment(3)?>?url=<?= current_full_url() ?>"><img src="<?php echo base_url(); ?>assets/img/test-fail-icon.png" alt="Inactive" /></a>
 <?php } ?>
                                         </td>
                                         </tr>
                                 <?php } ?>
                             </tbody>
                         </table>
                         <br>
                         <a href="<?php echo base_url()."webtv/addVideo/".$this->uri->segment(3).'/'.$this->uri->segment(4) ?>" class="btn btn-success">Add Video</a>
                         <a class="btn btn-warning" href="<?php echo base_url()."webtv/playlist/".$this->uri->segment(4) ?>"><i class="fa fa-mail-reply"></i> Back</a>
                     </div>		
                     <!-- Pagination end -->
                 </div><!-- /.box-body -->
             </div><!-- /.box -->
         </div>
     </div>
示例#12
0
function ca_list($p, $data)
{
    $return = '';
    if ($p && is_array($p)) {
        foreach ($p as $result) {
            $exp = explode('.', element('bca_key', $result));
            $len = element(1, $exp) ? strlen(element(1, $exp)) : '';
            $margin = $len * 20;
            $attributes = array('class' => 'form-inline', 'name' => 'fcategory');
            $return .= '<li class="list-group-item">
                                            <div class="form-horizontal">
                                                <div class="form-group" style="margin-bottom:0;">';
            if ($len) {
                $return .= '<div style="width:10px;float:left;margin-left:' . $margin . 'px;margin-right:10px;"><span class="fa fa-arrow-right"></span></div>';
            }
            $return .= '<div class="pl10">
                            <div class="cat-bca-id-' . element('bca_id', $result) . '">
                                ' . html_escape(element('bca_value', $result)) . ' (' . html_escape(element('bca_order', $result)) . ')
                                <button class="btn btn-primary btn-xs" onClick="cat_modify(\'' . element('bca_id', $result) . '\')"><span class="glyphicon glyphicon-edit"></span></button>';
            if (!element(element('bca_key', $result), $data)) {
                $return .= '<button class="btn btn-danger btn-xs btn-one-delete" data-one-delete-url = "' . admin_url('board/boards/write_category_delete/' . element('brd_id', $data) . '/' . element('bca_id', $result)) . '"><span class="glyphicon glyphicon-trash"></span></button>';
            }
            $return .= '                </div>
                                                        <div class="form-inline mod-bca-id-' . element('bca_id', $result) . '" style="display:none;">';
            $return .= form_open(current_full_url(), $attributes);
            $return .= '
                                                            <input type="hidden" name="brd_id"    value="' . element('brd_id', $data) . '" />
                                                            <input type="hidden" name="bca_id"    value="' . element('bca_id', $result) . '" />
                                                            <input type="hidden" name="type" value="modify">
                                                            <div class="form-group" style="margin-left:0;">
                                                                카테고리명 <input type="text" class="form-control" name="bca_value" value="' . html_escape(element('bca_value', $result)) . '" />
                                                                정렬순서 <input type="number" class="form-control" name="bca_order" value="' . html_escape(element('bca_order', $result)) . '"/>
                                                                <button class="btn btn-primary btn-xs" type="submit" >저장</button>
                                                                <a href="javascript:;" class="btn btn-default btn-xs" onClick="cat_cancel(\'' . element('bca_id', $result) . '\')">취소</a>
                                                            </div>';
            $return .= form_close();
            $return .= '                </div>
                                                    </div>
                                                    </div>
                                                </div>
                                            </li>';
            $parent = element('bca_key', $result);
            $return .= ca_list(element($parent, $data), $data);
        }
    }
    return $return;
}
 </tr>
 <?php
 // echo '<pre>'; print_r($setting);
 foreach ($setting as $value2) {
     ?>
     <tr>
         <td><?php echo $value2->device_name; ?></td>
         <td><?php echo $value2->flavor_name; ?></td>
         <td><?php echo $value2->bitrate; ?></td>
         <td><?php echo $value2->video_bitrate; ?></td>
         <td><?php echo $value2->audio_bitrate; ?></td>
         <td><?php echo $value2->width . ' * ' . $value2->height; ?></td>
         <td><?php echo $value2->frame_rate; ?></td>
         <td><?php echo $value2->keyframe_rate; ?></td>
         <?php
         $curr_url = current_full_url();
         $contectid = base64_decode($_GET['action']);
         switch ($value2->status) {
             case 'inprocess' :
                 echo sprintf('<td><span class="%s">inprocess</span></td>', 'label label-info');
                 echo sprintf('<td><a href="%s" class="%s">Cancel</a></td>', base_url() . 'video/changeStatus?flavor_id=' . $value2->id. '&content_id='.$contectid. '&status=inprocess'. '&redirecturl=' . $curr_url, 'btn btn-warning btn-sm');
                 break;
             case 'completed' :
                 echo sprintf('<td><span class="%s">complete</span></td>', 'label label-success');
                 echo sprintf('<td><a href="%s"  class="%s">Delete</a></td>', base_url() . 'video/changeStatus?flavor_id=' . $value2->id. '&content_id='.$contectid. '&status=complete'. '&redirecturl=' . $curr_url, 'btn btn-danger btn-sm');
                 break;
             case 'pending' :
             default :
                 echo sprintf('<td><span class="%s">Pending</span></td>', 'label label-warning');
                 echo sprintf('<td><a href="%s" class="%s">Convert</a></td>', base_url() . 'video/changeStatus?flavor_id=' . $value2->id . '&content_id='.$contectid. '&status=pending'. '&redirecturl=' . $curr_url, 'btn btn-primary btn-sm');
                 break;
示例#14
0
文件: write.php 项目: smboy86/zzing
<?php

$this->managelayout->add_css(element('view_skin_url', $layout) . '/css/style.css');
echo element('headercontent', element('board', $view));
?>

<div class="board">
    <h3><?php 
echo html_escape(element('board_name', element('board', $view)));
?>
 글쓰기</h3>
    <?php 
echo validation_errors('<div class="alert alert-warning" role="alert">', '</div>');
echo show_alert_message(element('message', $view), '<div class="alert alert-auto-close alert-dismissible alert-info"><button type="button" class="close alertclose" >&times;</button>', '</div>');
$attributes = array('class' => 'form-horizontal', 'name' => 'fwrite', 'id' => 'fwrite', 'onsubmit' => 'return submitContents(this)');
echo form_open_multipart(current_full_url(), $attributes);
?>
        <input type="hidden" name="<?php 
echo element('primary_key', $view);
?>
"    value="<?php 
echo element(element('primary_key', $view), element('post', $view));
?>
" />
        <div class="writeform">
        <?php 
if (element('is_post_name', element('post', $view))) {
    ?>
            <li>
                <span>이름</span>
                <input type="text" class="input per95" name="post_nickname" id="post_nickname" value="<?php 
示例#15
0
                                    <a href="<?php 
        echo $deleteUrl;
        ?>
" class="btn btn-xs btn-bricky tooltips" data-placement="top" data-original-title="Delete"><i class="clip-close"></i></a>
                                    <input type="hidden" name="multi_cms_page_delete_url" value="<?php 
        echo site_url('/admin/cms/deleteMultipleCmsPage?rec_on_page=' . count($cmsPages) . '&cur_page=' . $this->pagination->cur_page . '&tot_rec=' . $this->pagination->total_rows . '&per_page=' . $this->pagination->per_page . '&ref=' . base64_encode(current_full_url()));
        ?>
" ng-model="multiRecordDeleteUrl" ng-init="multiRecordDeleteUrl='<?php 
        echo site_url('/admin/cms/deleteMultipleCmsPage?rec_on_page=' . count($cmsPages) . '&cur_page=' . $this->pagination->cur_page . '&tot_rec=' . $this->pagination->total_rows . '&per_page=' . $this->pagination->per_page . '&ref=' . base64_encode(current_full_url()));
        ?>
'"/>
                                    <input type="hidden" name="multi_cms_page_status_toggle_url" value="<?php 
        echo site_url('/admin/cms/toggleMultipleCmsPageStatus?ref=' . base64_encode(current_full_url()));
        ?>
" ng-model="multiRecordStausToggleUrl" ng-init="multiRecordStausToggleUrl='<?php 
        echo site_url('/admin/cms/toggleMultipleCmsPageStatus?ref=' . base64_encode(current_full_url()));
        ?>
'"/>
                                </td>
                            </tr>
                            <?php 
    }
} else {
    ?>
                            <tr>
                                <td colspan="10" align='center'><strong>You have not added any CMS page yet!</strong></td>
                            </tr>
                            <?php 
}
?>
                        </tbody>
示例#16
0
 /**
  * render change password page
  */
 public function changePassword()
 {
     if ('get' === strtolower($this->input->server('REQUEST_METHOD'))) {
         $this->isAdminLoggedIn(current_full_url());
         // allow only if admin is logged in
         $this->templater->setTemplate();
         // set template
         $data = array('pageTitle' => ADMIN_PAGE_TITLE_PREFIX . 'Change Password', 'pageHeader' => 'Change Password', 'breadCrumbs' => array('Dashboard' => site_url('admin/dashboard'), 'Edit Profile' => site_url('/admin/profile'), 'Change Password' => site_url('/admin/profile/change-password')));
         // set generic data to view data variable
         $data['userId'] = $this->viewData['adminSessionData'][ADMIN_DETAILS]['id'];
         // get logged in user id from session
         if ($changedPasswordUserInput = $this->session->flashdata('changePasswordUserInput')) {
             $data['changedPasswordUserInput'] = $this->utility->convertSessionDataArrayToObject($changedPasswordUserInput);
         }
         $this->prepareDataForView($data);
         // merge with any generic data present
         $this->templater->setViewData($this->viewData);
         // set data for view
         $this->templater->render('profile/change_password');
         // render view
     } else {
         $this->utility->handleInvalidRequestMethod($this->input->server('REMOTE_ADDR'), 'admin/dashboard');
     }
 }
示例#17
0
                                    <a href="<?php 
        echo $deleteUrl;
        ?>
" class="btn btn-xs btn-bricky tooltips" data-placement="top" data-original-title="Delete"><i class="clip-close"></i></a>
                                    <input type="hidden" name="multi_agent_type_delete_url" value="<?php 
        echo site_url('/admin/agent_type/deleteMultipleAgentType?rec_on_page=' . count($agentTypes) . '&cur_page=' . $this->pagination->cur_page . '&tot_rec=' . $this->pagination->total_rows . '&per_page=' . $this->pagination->per_page . '&ref=' . base64_encode(current_full_url()));
        ?>
" ng-model="multiRecordDeleteUrl" ng-init="multiRecordDeleteUrl='<?php 
        echo site_url('/admin/agent_type/deleteMultipleAgentType?rec_on_page=' . count($agentTypes) . '&cur_page=' . $this->pagination->cur_page . '&tot_rec=' . $this->pagination->total_rows . '&per_page=' . $this->pagination->per_page . '&ref=' . base64_encode(current_full_url()));
        ?>
'"/>
                                    <input type="hidden" name="multi_agent_type_status_toggle_url" value="<?php 
        echo site_url('/admin/agent_type/toggleMultipleAgentTypeStatus?ref=' . base64_encode(current_full_url()));
        ?>
" ng-model="multiRecordStausToggleUrl" ng-init="multiRecordStausToggleUrl='<?php 
        echo site_url('/admin/agent_type/toggleMultipleAgentTypeStatus?ref=' . base64_encode(current_full_url()));
        ?>
'"/>
                                </td>
                            </tr>
                            <?php 
    }
} else {
    ?>
                            <tr>
                                <td colspan="9" align='center'><strong>You have not added any agent type yet!</strong></td>
                            </tr>
                            <?php 
}
?>
                        </tbody>
示例#18
0
/**
 * Checks whether to remove or not the author name
 */
function show_hide_author()
{
    $url = current_full_url();
    // Get post id
    global $post;
    $ID = $post->ID;
    // Get and prepare current url
    $replace = array('/http:\\/\\/www./', '/https:\\/\\/www./', '/www./', '/\\n\\r/');
    $with = array('', '', '', '\\n');
    $current_url_nohttp = preg_replace($replace, $with, $url);
    $options_array = get_option('show_author_options');
    // Get and prepare Show url
    $option_urls_show_nohttp = preg_replace($replace, $with, $options_array['option_url_show']);
    $urls_show_array = explode("\n", $option_urls_show_nohttp);
    // Get and prepare Hide url
    $option_urls_hide_nohttp = preg_replace($replace, $with, $options_array['option_url_hide']);
    $urls_hide_array = explode("\n", $option_urls_hide_nohttp);
    // If nothing submitted, hide the name everywhere
    if (!is_array($options_array)) {
        remove_author();
    } else {
        if (in_array($current_url_nohttp, $urls_show_array)) {
            // Show Author
        } else {
            if (in_array($current_url_nohttp, $urls_hide_array)) {
                remove_author();
            } else {
                if (in_array('individual', $options_array) && get_post_meta($ID, '_show_author_inthis_post', true) == 'inthis_post') {
                    // Show Author
                } else {
                    if (in_array('individual', $options_array) && get_post_meta($ID, '_show_author_inthis_post', true) == 'not_inthis_post') {
                        remove_author();
                    } else {
                        if (empty($options_array) || !in_array(get_post_type($ID), $options_array)) {
                            remove_author();
                        } else {
                            // Show Author
                        }
                    }
                }
            }
        }
    }
}
                                    <td><?php echo $promo_val->start_time; ?>  </td>
                                    <td><?php echo $promo_val->end_time; ?>  </td>
                                    <td><?php echo $promo_val->default; ?>  </td>
                                    <td><?php echo $promo_val->status; ?>  </td>
                                    <td>
                                        <a class="btn btn-info btn-sm <?php if ($promo_val->default_thumbnail == '1') {
                                echo "disabled";
                            } else {
                                
                            } ?>" href="<?php echo base_url(); ?>video/set_defltimage?cid=<?php echo $content_id; ?>&fid=<?php echo $promo_val->id; ?>&redirect_url=<?php echo current_full_url(); ?>"><?php echo $welcome->loadPo('Set as Default'); ?></a>
                                        <a class="btn btn-success btn-sm" href="<?php echo base_url(); ?>video/download_thumb?fileName=<?php echo $promo_val->name; ?>&redirect_url=<?php echo current_full_url(); ?>"><?php echo $welcome->loadPo('Download'); ?></a>
                                        <a class="confirm_delete btn btn-danger btn-sm <?php if ($promo_val->default_thumbnail == '1') {
                                echo "disabled";
                            } else {
                                
                            } ?>" href="<?php echo base_url(); ?>video/delele_thumbimage?cid=<?php echo $content_id; ?>&fid=<?php echo $promo_val->id; ?>&redirect_url=<?php echo current_full_url(); ?>" ><?php echo $welcome->loadPo('Delete'); ?></a></td>
                                </tr>
								<?php $i++;
							} 
							?>
                        </tbody>
                    </table>
                </div><!-- /.box-body -->
            </div><!-- box box-solid -->
        </div><!-- col-md-12 -->
    </div><!-- row -->
</div><!-- /.tab-4 -->
</div><!-- /.tab-content -->
</div><!-- nav-tabs-custom -->
</div><!-- /.col -->
</div> <!-- /.row -->
示例#20
0
function refresh()
{
    redirect(current_full_url(), 'refresh');
}
示例#21
0
										if($field)
										{
											foreach($field as $cat) { ?>
											<tr id="categ_<?php echo $cat->id;?>">
												<td><?php echo $cat->field_title; ?></td>
												<td><?php echo $cat->field_type; ?></td>
												<td>
													<?php if($cat->status == 1){?>
														<img src="<?php echo base_url();?>assets/img/test-pass-icon.png" alt="Active" />
													<?php }else{?>
														<img src="<?php echo base_url();?>assets/img/test-fail-icon.png" alt="Inactive" />
													<?php }?>
												</td>
												<td>
													<a href="<?php echo base_url(); ?>dform/addFields?action=<?php echo base64_encode($cat->id);?>&id=<?php echo $_GET['id'] ?>" class="btn btn-info btn-sm"><?php echo $welcome->loadPo('Edit'); ?></a>&nbsp;
													<a class="confirm" onclick="return delete_field(<?php echo $cat->id; ?>, '<?php echo base_url() . 'dform/deletefield' ?>', '<?php echo current_full_url(); ?>');" href="" ><button class="btn btn-danger btn-sm" data-toggle="modal" data-target=".bs-example-modal-sm" ><?php echo $welcome->loadPo('Delete'); ?></button></a>
																									
												</td>
											</tr>
										<?php }}else{?>
											<tr >
												<td colspan="10"><?php echo $welcome->loadPo('No Records Found'); ?></td>
											</tr>
										<?php } ?>
									</tbody>
								</table>
								<!-- Pagination start --->
								<div class="row pull-right">
									<div class="col-xs-12">
										<div class="dataTables_paginate paging_bootstrap">
											<ul class="pagination"><li><?php echo $links ?></li></ul> 
示例#22
0
文件: index.php 项目: smboy86/zzing
echo element('paging', $view);
?>
                <div class="pull-left ml20"><?php 
echo admin_listnum_selectbox();
?>
</div>
                <?php 
echo $buttons;
?>
            </div>
        <?php 
echo form_close();
?>
    </div>
    <form name="fsearch" id="fsearch" action="<?php 
echo current_full_url();
?>
" method="get">
    <input type="hidden" name="fgr_id" value="<?php 
echo $this->input->get('fgr_id');
?>
" />
        <div class="box-search">
            <div class="row">
                <div class="col-md-6 col-md-offset-3">
                    <select class="form-control" name="sfield" >
                        <?php 
echo element('search_option', $view);
?>
                    </select>
                    <div class="input-group">
示例#23
0
文件: Common.php 项目: smboy86/zzing
 function init()
 {
     $CI =& get_instance();
     if ($CI->uri->segment(1) === 'install') {
         return;
     }
     if (config_item('use_lock_ip') && $CI->cbconfig->item('site_ip_whitelist')) {
         $whitelist = $CI->cbconfig->item('site_ip_whitelist');
         $whitelist = preg_replace("/[\r|\n|\r\n]+/", ',', $whitelist);
         $whitelist = preg_replace("/\\s+/", '', $whitelist);
         if (preg_match('/(<\\?|<\\?php|\\?>)/xsm', $whitelist)) {
             $whitelist = '';
         }
         if ($whitelist) {
             $whitelist = explode(',', trim($whitelist, ','));
             $whitelist = array_unique($whitelist);
             if (is_array($whitelist)) {
                 $CI->load->library('Ipfilter');
                 $ipfilter = new Ipfilter();
                 if (!$ipfilter->filter($whitelist)) {
                     $title = $CI->cbconfig->item('site_blacklist_title') ? $CI->cbconfig->item('site_blacklist_title') : 'Maintenance in progress...';
                     $message = $CI->cbconfig->item('site_blacklist_content');
                     show_error($message, '500', $title);
                     exit;
                 }
             }
         }
     }
     if (config_item('use_lock_ip') && $CI->cbconfig->item('site_ip_blacklist')) {
         $blacklist = $CI->cbconfig->item('site_ip_blacklist');
         $blacklist = preg_replace("/[\r|\n|\r\n]+/", ',', $blacklist);
         $blacklist = preg_replace("/\\s+/", '', $blacklist);
         if (preg_match('/(<\\?|<\\?php|\\?>)/xsm', $blacklist)) {
             $blacklist = '';
         }
         if ($blacklist) {
             $blacklist = explode(',', trim($blacklist, ','));
             $blacklist = array_unique($blacklist);
             if (is_array($blacklist)) {
                 $CI->load->library('Ipfilter');
                 $ipfilter = new Ipfilter();
                 if ($ipfilter->filter($blacklist)) {
                     $title = $CI->cbconfig->item('site_blacklist_title') ? $CI->cbconfig->item('site_blacklist_title') : 'Maintenance in progress...';
                     $message = $CI->cbconfig->item('site_blacklist_content');
                     show_error($message, '500', $title);
                     exit;
                 }
             }
         }
     }
     if ($CI->input->get('device') === 'desktop' or $CI->input->get('device') === 'mobile') {
         $cookie_name = 'device_view_type';
         $cookie_value = $CI->input->get('device');
         $cookie_expire = 3600;
         // 1일간 저장
         set_cookie($cookie_name, $cookie_value, $cookie_expire);
     }
     $CI->load->library('Mobile_detect');
     $detect = new Mobile_detect();
     $device_view_type = ($CI->input->get('device') === 'desktop' or $CI->input->get('device') === 'mobile') ? $CI->input->get('device') : '';
     if (empty($device_view_type)) {
         $device_view_type = (get_cookie('device_view_type') === 'desktop' or get_cookie('device_view_type') === 'mobile') ? get_cookie('device_view_type') : '';
     }
     if (empty($device_view_type)) {
         $device_view_type = $detect->isMobile() ? 'mobile' : 'desktop';
     }
     $CI->cbconfig->set_device_view_type($device_view_type);
     $device_type = $detect->isMobile() ? 'mobile' : 'desktop';
     $CI->cbconfig->set_device_type($device_type);
     if (get_cookie('autologin') && !$CI->session->userdata('mem_id')) {
         $CI->load->model('Autologin_model');
         $where = array('aul_key' => get_cookie('autologin'));
         $autodata = $CI->Autologin_model->get_one('', '', $where);
         if (!element('mem_id', $autodata)) {
             delete_cookie('autologin');
         } elseif (!element('aul_datetime', $autodata) or strtotime(element('aul_datetime', $autodata)) < ctimestamp() * 86400 * 30) {
             $CI->Autologin_model->delete(element('aul_id', $autodata));
             delete_cookie('autologin');
         } elseif ($CI->input->ip_address() !== element('aul_ip', $autodata)) {
             $CI->Autologin_model->delete(element('aul_id', $autodata));
             delete_cookie('autologin');
         } else {
             $tmpmember = $CI->Member_model->get_by_memid(element('mem_id', $autodata), 'mem_id, mem_denied, mem_is_admin');
             if (!element('mem_id', $tmpmember)) {
                 $CI->Autologin_model->delete(element('aul_id', $autodata));
                 delete_cookie('autologin');
             } elseif (element('mem_denied', $tmpmember)) {
                 $CI->Autologin_model->delete(element('aul_id', $autodata));
                 delete_cookie('autologin');
             } elseif (element('mem_is_admin', $tmpmember)) {
                 $CI->Autologin_model->delete(element('aul_id', $autodata));
                 delete_cookie('autologin');
             } else {
                 $CI->session->set_userdata('mem_id', element('mem_id', $autodata));
             }
         }
     }
     if ($CI->member->is_member()) {
         if ($CI->member->item('mem_id') === false) {
             unset($CI->member);
             $CI->session->sess_destroy();
             redirect(current_full_url(), 'refresh');
         }
         $mem_id = (int) $CI->member->item('mem_id');
         if ($CI->member->item('mem_denied')) {
             unset($CI->member);
             $CI->session->sess_destroy();
             redirect(current_full_url(), 'refresh');
         } else {
             if (substr($CI->member->item('mem_lastlogin_datetime'), 0, 10) !== cdate('Y-m-d')) {
                 if ($CI->cbconfig->item('point_login')) {
                     $CI->load->library('point');
                     $CI->point->insert_point($mem_id, $CI->cbconfig->item('point_login'), cdate('Y-m-d') . ' 첫로그인', 'login', $mem_id, cdate('Y-m-d') . ' 로그인');
                 }
                 $updatedata = array('mem_lastlogin_datetime' => cdate('Y-m-d H:i:s'), 'mem_lastlogin_ip' => $CI->input->ip_address());
                 $CI->Member_model->update($mem_id, $updatedata);
             }
         }
     }
     // 관리자 페이지
     if ($CI->member->is_admin() !== 'super' && $CI->uri->segment(1) === config_item('uri_segment_admin')) {
         redirect('login?url=' . $CI->uri->uri_string());
     }
     if (config_item('use_lock_ip') && $CI->uri->segment(1) === config_item('uri_segment_admin') && $CI->cbconfig->item('admin_ip_whitelist')) {
         $whitelist = $CI->cbconfig->item('admin_ip_whitelist');
         $whitelist = preg_replace("/[\r|\n|\r\n]+/", ',', $whitelist);
         $whitelist = preg_replace("/\\s+/", '', $whitelist);
         if (preg_match('/(<\\?|<\\?php|\\?>)/xsm', $whitelist)) {
             $whitelist = '';
         }
         if ($whitelist) {
             $whitelist = explode(',', trim($whitelist, ','));
             $whitelist = array_unique($whitelist);
             if (is_array($whitelist)) {
                 $CI->load->library('Ipfilter');
                 if (!Ipfilter::filter($whitelist)) {
                     $title = '관리자 페이지';
                     $message = '현재 접속하신 아이피는 관리자 페이지 접근이 차단되었습니다';
                     show_error($message, '500', $title);
                     exit;
                 }
             }
         }
     }
 }