<?php
/**
* URL解析規(guī)則
* 例如: 114.html 對(duì)應(yīng) index.php?s=demo&c=show&id=114
* 可以解析: "114.html" => 'index.php?s=demo&c=show&id=114',
* 動(dòng)態(tài)id解析: "([0-9]+).html" => 'index.php?s=demo&c=show&id=$1',
*/
return [
// 共享模塊---產(chǎn)品---URL解析
"([\w\\/]+)\/p([0-9]+)\.html" => "index.php?c=category&dir=$1&page=$2", // 欄目分頁(yè)
"([\w\\/]+)" => "index.php?c=category&dir=$1", // 欄目頁(yè)
"([\w\\/]+)\/\?(.*)" => "index.php?c=category&dir=$1", // 欄目頁(yè)
"([A-za-z0-9 \-\_]+)\/([0-9]+)\.html" => "index.php?c=show&id=$2", // 內(nèi)容頁(yè)
// 自定義頁(yè)面---URL偽靜態(tài)規(guī)則----
"([A-za-z0-9 \-\_]+).html" => "index.php?s=page&dir=$1",
// 獨(dú)立模塊---新聞與案例---URL解析
, // 模塊首頁(yè)
, // 欄目分頁(yè)
, // 欄目頁(yè)
, // 內(nèi)容頁(yè)
, // 搜索頁(yè)
];xxxx.com/index.php?c=category&id=73 xxx.com/index.php?c=show&id=269
您好,我想問下新聞頁(yè)的 新聞首頁(yè),新聞欄目頁(yè) 新聞內(nèi)容頁(yè) url解析如何寫哦
這種是動(dòng)態(tài)地址,不需要寫解析規(guī)則,直接訪問就行了,
只有自定義url才會(huì)寫解析規(guī)則
開源是一種精神,但不是義務(wù),幫忙是情分,不幫也不要抱怨,建議大家多研究代碼、多閱讀代碼、多翻閱社區(qū)歷史問題!
開源是一種精神,但不是義務(wù),幫忙是情分,不幫也不要抱怨,建議大家多研究代碼、多閱讀代碼、多翻閱社區(qū)歷史問題!