Error

PHP Notice万博manbext官网_ManBetX官网登录_万博manbetx官网网址

Trying to get property of non-object

  • 1. in /data/home/hyu7465740001/htdocs/frontend/views/cn/product/single.php at line 62
    53545556575859606162636465666768697071
                        <?php }?>
                        <?php }?>
                    </div>
                    <?php }?>
                </div>
            </div>
     
            <div class="flex-box">
                <div class="img-box">
                    <img src="<?=ImageHelper::imgUrl($categoryInfo->thumb)?>" alt="">
                </div>
                <div class="text-box" style="background-image:url('<?=ImageHelper::imgUrl($categoryInfo->face)?>');">
                    <div class="name" style="font-size: 50px;"><?=$categoryInfo->cate_title?></div>
                    <div class="d"><?=$categoryInfo->cate_content?></div>
                </div>
            </div>
        </div>
     
        <div class="box2">
    
  • 2. in /data/home/hyu7465740001/htdocs/frontend/views/cn/product/single.php at line 62 yii\base\ErrorHandler::handleError(8, 'Trying to get property of non-ob...', '/data/home/hyu7465740001/htdocs/...', 62, ...)
    56575859606162636465666768
                    <?php }?>
                </div>
            </div>
     
            <div class="flex-box">
                <div class="img-box">
                    <img src="<?=ImageHelper::imgUrl($categoryInfo->thumb)?>" alt="">
                </div>
                <div class="text-box" style="background-image:url('<?=ImageHelper::imgUrl($categoryInfo->face)?>');">
                    <div class="name" style="font-size: 50px;"><?=$categoryInfo->cate_title?></div>
                    <div class="d"><?=$categoryInfo->cate_content?></div>
                </div>
            </div>
    
  • 3. in /data/home/hyu7465740001/htdocs/vendor/yiisoft/yii2/base/View.php at line 325 – require('/data/home/hyu7465740001/htdocs/...')
    319320321322323324325326327328329330331
         */
        public function renderPhpFile($_file_, $_params_ = [])
        {
            ob_start();
            ob_implicit_flush(false);
            extract($_params_, EXTR_OVERWRITE);
            require($_file_);
     
            return ob_get_clean();
        }
     
        /**
         * Renders dynamic content returned by the given PHP statements.
    
  • 4. in /data/home/hyu7465740001/htdocs/vendor/yiisoft/yii2/base/View.php at line 247 yii\base\View::renderPhpFile('/data/home/hyu7465740001/htdocs/...', ['category' => [common\models\Category, common\models\Category, common\models\Category, common\models\Category], 'categoryCount' => '4', 'categoryInfo' => null, 'product' => []])
    241242243244245246247248249250251252253
                        $this->renderers[$ext] = Yii::createObject($this->renderers[$ext]);
                    }
                    /* @var $renderer ViewRenderer */
                    $renderer = $this->renderers[$ext];
                    $output = $renderer->render($this, $viewFile, $params);
                } else {
                    $output = $this->renderPhpFile($viewFile, $params);
                }
                $this->afterRender($viewFile, $params, $output);
            }
     
            array_pop($this->_viewFiles);
            $this->context = $oldContext;
    
  • 5. in /data/home/hyu7465740001/htdocs/vendor/yiisoft/yii2/base/View.php at line 149 yii\base\View::renderFile('/data/home/hyu7465740001/htdocs/...', ['category' => [common\models\Category, common\models\Category, common\models\Category, common\models\Category], 'categoryCount' => '4', 'categoryInfo' => null, 'product' => []], frontend\controllers\ProductController)
    143144145146147148149150151152153154155
         * @throws InvalidParamException if the view cannot be resolved or the view file does not exist.
         * @see renderFile()
         */
        public function render($view, $params = [], $context = null)
        {
            $viewFile = $this->findViewFile($view, $context);
            return $this->renderFile($viewFile, $params, $context);
        }
     
        /**
         * Finds the view file based on the given view name.
         * @param string $view the view name or the path alias of the view file. Please refer to [[render()]]
         * on how to specify this parameter.
    
  • 6. in /data/home/hyu7465740001/htdocs/vendor/yiisoft/yii2/base/Controller.php at line 379 yii\base\View::render('single', ['category' => [common\models\Category, common\models\Category, common\models\Category, common\models\Category], 'categoryCount' => '4', 'categoryInfo' => null, 'product' => []], frontend\controllers\ProductController)
    373374375376377378379380381382383384385
         * These parameters will not be available in the layout.
         * @return string the rendering result.
         * @throws InvalidParamException if the view file or the layout file does not exist.
         */
        public function render($view, $params = [])
        {
            $content = $this->getView()->render($view, $params, $this);
            return $this->renderContent($content);
        }
     
        /**
         * Renders a static string by applying a layout.
         * @param string $content the static string being rendered
    
  • 7. in /data/home/hyu7465740001/htdocs/frontend/controllers/ProductController.php at line 59 yii\base\Controller::render('single', ['category' => [common\models\Category, common\models\Category, common\models\Category, common\models\Category], 'categoryCount' => '4', 'categoryInfo' => null, 'product' => []])
    53545556575859606162636465
            }
            $data['categoryInfo']=Category::findOne($cate);
            $data['product']=News::find()->where(['enabled'=>1,'news_p_cate'=>$cate])->orderBy('sort desc,news_id desc')->all();
            if($cate=='126'||$cate==136){
                return $this->render('diban',$data);
            }else{
                return $this->render('single',$data);
            }
     
        }
        public function actionInfo(){
            $result = array();
            $result['result'] = true;
    
  • 8. frontend\controllers\ProductController::actionIndex()
  • 9. in /data/home/hyu7465740001/htdocs/vendor/yiisoft/yii2/base/InlineAction.php at line 55 – call_user_func_array([frontend\controllers\ProductController, 'actionIndex'], [])
    495051525354555657
            $args = $this->controller->bindActionParams($this, $params);
            Yii::trace('Running action: ' . get_class($this->controller) . '::' . $this->actionMethod . '()', __METHOD__);
            if (Yii::$app->requestedParams === null) {
                Yii::$app->requestedParams = $args;
            }
     
            return call_user_func_array([$this->controller, $this->actionMethod], $args);
        }
    }
    
  • 10. in /data/home/hyu7465740001/htdocs/vendor/yiisoft/yii2/base/Controller.php at line 155 yii\base\InlineAction::runWithParams(['cate' => '128', '/product/128_html' => ''])
    149150151152153154155156157158159160161
            }
     
            $result = null;
     
            if ($runAction && $this->beforeAction($action)) {
                // run the action
                $result = $action->runWithParams($params);
     
                $result = $this->afterAction($action, $result);
     
                // call afterAction on modules
                foreach ($modules as $module) {
                    /* @var $module Module */
    
  • 11. in /data/home/hyu7465740001/htdocs/vendor/yiisoft/yii2/base/Module.php at line 454 yii\base\Controller::runAction('index', ['cate' => '128', '/product/128_html' => ''])
    448449450451452453454455456457458459460
            $parts = $this->createController($route);
            if (is_array($parts)) {
                /* @var $controller Controller */
                list($controller, $actionID) = $parts;
                $oldController = Yii::$app->controller;
                Yii::$app->controller = $controller;
                $result = $controller->runAction($actionID, $params);
                Yii::$app->controller = $oldController;
     
                return $result;
            } else {
                $id = $this->getUniqueId();
                throw new InvalidRouteException('Unable to resolve the request "' . ($id === '' ? $route : $id . '/' . $route) . '".');
    
  • 12. in /data/home/hyu7465740001/htdocs/vendor/yiisoft/yii2/web/Application.php at line 84 yii\base\Module::runAction('product/index', ['cate' => '128', '/product/128_html' => ''])
    78798081828384858687888990
                $params = $this->catchAll;
                unset($params[0]);
            }
            try {
                Yii::trace("Route requested: '$route'", __METHOD__);
                $this->requestedRoute = $route;
                $result = $this->runAction($route, $params);
                if ($result instanceof Response) {
                    return $result;
                } else {
                    $response = $this->getResponse();
                    if ($result !== null) {
                        $response->data = $result;
    
  • 13. in /data/home/hyu7465740001/htdocs/vendor/yiisoft/yii2/base/Application.php at line 375 yii\web\Application::handleRequest(yii\web\Request)
    369370371372373374375376377378379380381
            try {
     
                $this->state = self::STATE_BEFORE_REQUEST;
                $this->trigger(self::EVENT_BEFORE_REQUEST);
     
                $this->state = self::STATE_HANDLING_REQUEST;
                $response = $this->handleRequest($this->getRequest());
     
                $this->state = self::STATE_AFTER_REQUEST;
                $this->trigger(self::EVENT_AFTER_REQUEST);
     
                $this->state = self::STATE_SENDING_RESPONSE;
                $response->send();
    
  • 14. in /data/home/hyu7465740001/htdocs/index.php at line 17 yii\base\Application::run()
    1112131415161718
        require(__DIR__ . '/common/config/main.php'),
        require(__DIR__ . '/common/config/main-local.php'),
        require(__DIR__ . '/frontend/config/main.php'),
        require(__DIR__ . '/frontend/config/main-local.php')
    );
    $application = new yii\web\Application($config);
    $application->run();
    ?>
    
  • $_GET = [
        'cate' => '128',
        '/product/128_html' => '',
    ];