首页 > 解决方案 > 请帮助 致命错误:未捕获的错误:在 /antivirus_scan.php:1 中不在对象上下文中时使用 $this 堆栈跟踪:#0 {main} 抛出

问题描述

请帮助我有一个问题:

致命错误:未捕获的错误:当不在 D:\xampp\htdocs\admin\antivirus\antivirus_scan.php:1 的对象上下文中时使用 $this
堆栈跟踪:
#0 {main} 在 D:\xampp\htdocs\admin\ 中抛出第 1 行的 antivirus\antivirus_scan.php

<?php $this->load->view('admin/theme/message'); ?>
<section class="content-header">
    <h1 class = 'text-info'><i class="fa fa-shield"></i> <?php echo $this->lang->line("malware scan");?></h1>
</section>
<section class="content">  
    <div class="row" >
        <div class="col-xs-12">
            <div class="grid_container" style="width:100%; height:720px;">
                <table 
                id="tt"  
                class="easyui-datagrid" 
                url="<?php echo base_url()."antivirus/scan_data"; ?>" 

                pagination="true" 
                rownumbers="true" 
                toolbar="#tb" 
                pageSize="10" 
                pageList="[5,10,15,20,50,100]"  
                fit= "true" 
                fitColumns= "true" 
                nowrap= "true" 
                view= "detailview"
                idField="id"
                >

消息.php

    <?php 
    if($this->session->flashdata('success_message')==1)
    {       
        echo "<div class='alert alert-success text-center'><h4 style='margin:0;'><i class='fa fa-check-circle'></i> ".$this->lang->line("your data has been successfully stored into the database.")."</h4></div>";
    }

    if($this->session->flashdata('warning_message')==1)
    echo "<div class='alert alert-warning text-center'><h4 style='margin:0;'><i class='fa fa-warning'></i> ".$this->lang->line("'something went wrong, please try again.")."</h4></div>";

    if($this->session->flashdata('error_message')==1)
    echo "<div class='alert alert-danger text-center'><h4 style='margin:0;'><i class='fa fa-remove'></i> ".$this->lang->line("your data has been failed to stored into the database.")."</h4></div>";

        
    if($this->session->flashdata('delete_success_message')==1)
    echo "<div class='alert alert-success text-center'><h4 style='margin:0;'><i class='fa fa-check-circle'></i> ".$this->lang->line("your data has been successfully deleted from the database.")."</h4></div>";
    
    if($this->session->flashdata('delete_error_message')==1)
    echo "<div class='alert alert-success text-center'><h4 style='margin:0;'><i class='fa fa-check-circle'></i> ".$this->lang->line("your data has been failed to delete from the database.")."</h4></div>";
    

    if($this->session->flashdata('not_exist_message')==1)
    echo "<div class='alert alert-warning text-center'><h4 style='margin:0;'><i class='fa fa-check-circle'></i> ".$this->lang->line("sorry! your data does not exist.")."</h4></div>";

    if($this->session->flashdata('available_error')==1)
    echo "<div class='alert alert-danger text-center'><h4 style='margin:0;'><i class='fa fa-check-circle'></i> ".$this->lang->line("this book isn't available right now.")."</h4></div>";


?>

标签: javascriptphphtml

解决方案


推荐阅读