一区二区久久-一区二区三区www-一区二区三区久久-一区二区三区久久精品-麻豆国产一区二区在线观看-麻豆国产视频

apache+codeigniter 通過.htcaccess做動態(tài)二級域名解析

復(fù)制代碼 代碼如下:
AuthName "yousite Website Coming Soon..." //如果你想給你的網(wǎng)站加個權(quán)限訪問
AuthType Basic
AuthUserFile D:/xxx/.htpasswd #如果你想設(shè)置密碼訪問 如何生成.htpasswd可以訪問 http://www.htaccesstools.com/htpasswd-generator/
#AuthGroupFile /dev/null
require valid-user

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /

#Removes access to the system folder by users.
#Additionally this will allow you to create a System.php controller,
#previously this would not have been possible.
#'system' can be replaced if you have renamed your system folder.
RewriteCond %{REQUEST_URI} ^system.*
RewriteRule ^(.*)$ /index.php?/$1 [L]

#When your application folder isn't in the system folder
#This snippet prevents user access to the application folder
#Submitted by: Fabdrol
#Rename 'application' to your applications folder name.
RewriteCond %{REQUEST_URI} ^application.*
RewriteRule ^(.*)$ /index.php?/$1 [L]


<IfModule mod_proxy.c>
# Redirect to boutique (with any trailing path)
RewriteCond %{HTTP_HOST} !^www. [NC]
RewriteCond %{HTTP_HOST} ^([^.]+).yousite.com(.*)$ [NC]
RewriteRule ^(.*)$ http://www.yousite.com/boutique/$1$2 [P,L]
</IfModule>

<IfModule !mod_proxy.c>
# Redirect to boutique (with any trailing path)
RewriteCond %{HTTP_HOST} !^www. [NC]
RewriteCond %{HTTP_HOST} ^([^.]+).yousite.com(.*)$ [NC]
RewriteRule ^(.*)$ http://www.yousite.com/boutique/%1/$1 [R=301,L]
</IfModule>

## Otherwise, force www;
RewriteCond %{HTTP_HOST} ^yousite.com$ [NC]
RewriteRule ^(.*)$ http://www.yousite.com/$1 [R=301,L]

#Checks to see if the user is attempting to access a valid file,
#such as an image or css document, if this isn't true it sends the
#request to index.php
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]
</IfModule>

<IfModule !mod_rewrite.c>
# If we don't have mod_rewrite installed, all 404's
# can be sent to index.php, and everything works as normal.
# Submitted by: ElliotHaughin

ErrorDocument 404 /index.php
</IfModule>

出處:cnblogs 微博:@草根小胡

php技術(shù)apache+codeigniter 通過.htcaccess做動態(tài)二級域名解析,轉(zhuǎn)載需保留來源!

鄭重聲明:本文版權(quán)歸原作者所有,轉(zhuǎn)載文章僅為傳播更多信息之目的,如作者信息標(biāo)記有誤,請第一時間聯(lián)系我們修改或刪除,多謝。

主站蜘蛛池模板: 久久这里只有精品免费看青草 | 色呦| 精品国产福利 | 中文字幕在线网站 | 四虎影院久久 | 欧美一区二区三区视视频 | 精品国产免费久久久久久婷婷 | 色视频免费观看 | 久久亚洲私人国产精品 | 国产91精品一区二区麻豆网站 | 日韩天天摸天天澡天天爽视频 | www.欧美视频.com | 大尺度人体videosex | 国产精品成人免费视频 | 国产v综合v亚洲欧美大片 | 在线观看成人小视频 | 丁香五月好婷婷深深爱 | 91视频这里只有精品 | 日本久久免费大片 | 日本欧美一区二区三区视频麻豆 | 7777精品伊人久久久大香线蕉 | 五月婷婷狠狠 | 精品小视频| 99这里有精品视频 | 亚洲伊人久久综合 | 国产一区二区三区不卡观 | 欧美地区一二三区 | 99久久久精品免费观看国产 | 乱子伦免费视频中文字幕 | 午夜乩伦 | 日本乱中文字幕系列在线观看 | 亚洲国产激情一区二区三区 | 欧美日本综合一区二区三区 | 国产精品高清视亚洲一区二区 | a中文字幕1区 | 国产精自产拍久久久久久蜜 | 国产xxxxx在线观看 | www.一区二区三区 | 97青青草原国产免费观看 | 欧美色域 | 国产精品一区不卡 |