throw new NotFoundHttpException('The requested page does not exist.'); } protected function findProduct($slug) { if (($model = Products::findOne(['slug' => $slug])) !== null) { return $model; } throw new NotFoundHttpException('The requested page does not exist.'); } }
$_GET = [ 'slug' => 'cua-cuon-nhanh-binh-duong-cua-cuon-toc-do-cao-o-binh-duong-cua-cuon-nhap-khau-di-an-binh-duong', ];