首先為何要把動態的php程式轉成靜態網址?
==>主要是為了搜尋引擎優化
只要使用.htaccess就可以囉!
EX : index.php?x=參數 要轉變成 index-1.html or index-2.html
.htaccess內容如下:
RewriteEngine on
RewriteRule ^product-([0-9]+).html$ product.php?id=$1

參考網址:http://roshanbh.com.np/2008/03/url-rewriting-examples-htaccess.html

-傑克老師網路創業顧問站內所有文章歡迎轉貼,但請註明出處及網址-
前一篇文章[SQL語法]如何依照特定條件隨機取得某一列?
下一篇文章解決windows 7無法使用telnet的問題?
我是傑克老師,目前在諸銘科技,熱愛演講與課程、分享網路上新知,包括海外購物資訊,像Amazon購物技巧。

回覆留言

Please enter your comment!
Please enter your name here