Laravel Blog

WBOY
Release: 2016-06-23 13:23:03
Original
795 people have browsed it

  • 建立articlesController

$article = Article::findorfail($id);
Copy after login

推荐的调试方法:

dd($article);  //die and dump_var
Copy after login

.env中可以将APP_DEBUG改为false,然后判断显示abort('404');

  • 三种链接方法:

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!