Laravel 之October Pages
来源:互联网 发布:淘宝开店认证需要等吗? 编辑:程序博客网 时间:2024/06/05 00:38
Pages 模板文件通常位于某一个主题目录底下的/pages 文件夹下,其命名不影响route。 这些文件都以 .htm 为拓展名。
Pages的三部分
1. Page Configration:定义了页面的一些属性
PARAMETER DESCRIPTION
default
.descriptionthe page description for the back-end interface, optional.URL的使用:
(1)通过url传递参数:
This is how you can access the URL parameter from the page PHP section
url = "/blog/post/:post_id"==function onStart(){ $post_id = $this->param('post_id');}==
(2)使用表达式
url = "/blog/:post_id|^[0-9]+$/comments" - this will match /blog/post/10/comments...url = "/blog/:post_id|^[0-9]+$" - this will match /blog/post/3...url = "/blog/:post_name?|^[a-z0-9\-]+$" - this will match /blog/my-blog-post
-blog-post
(3)使用通配符
For example, a URL like /color/:color/make/:make*/edit
will match /color/brown/make/volkswagen/beetle/retro/edit
and extract the following parameter values:
- color:
brown
- make:
volkswagen/beetle/retro
2. PHP code
这一部分存在三个特殊的函数:onInit() onStart() onEnd()
(1)onInit() is executed when all components are initialized and before AJAX requests are handled
(2)onStart() is executed in the beginning of the page execution
(3)onEnd() is executed before the page is rendered and after the page components are executed.
他们的执行先后顺序如下:
- Layout
onInit()
function. - Page
onInit()
function. - Layout
onStart()
function. - Layout components
onRun()
method. - Layout
onBeforePageStart()
function. - Page
onStart()
function. - Page components
onRun()
method. - Page
onEnd()
function. - Layout
onEnd()
function.
- Laravel 之October Pages
- Laravel之October Themes
- Roy&October之取石子
- 给大家推荐一个很好用的Laravel框架的源码,October CMS
- laravel october 的安装以及配置,官网翻译、实践、分析、总结
- ASP.NET之Web Pages
- 翻译github help之Github Pages《what-is-github-pages》
- Laravel学习之Composer安装Laravel
- laravel框架之视图
- Laravel使用之旅
- Laravel使用之旅
- laravel之Qiniu
- laravel之发送邮件
- laravel之模板使用
- Laravel 之Service Providers
- laravel之助手函数
- laravel之批量删除
- laravel之文件上传
- hdu2066 一个人的旅行
- 网页内容宽高适配
- nyoj 746整数划分(四) 区间DP
- Android开发出现ScrollView can host only one direct child
- 关于spark的一些资料总结
- Laravel 之October Pages
- [文章摘要]Studying commuting behaviours using collaborative visual analytics
- mybatis入门教程之错误收集
- Android中屏蔽 电源键长按、Home键、Home长按
- SWIFT推送之本地推送(UILocalNotification)之二带按钮的消息
- SpringMVC拦截器---解决乱码例子(一)
- 建造你自己的四旋翼无人机--核心技术介绍
- solr:基于lucene的全文检索解决方案
- CAShapeLayer的优点