歡迎光臨, 訪客. 請先 登入註冊一個帳號.
四月 29, 2024, 03:13:32 下午
19595 文章 在 3865 主題 由 4580 會員
最新註冊會員: aa123aa1
LifeType 中文開發論壇  |  支援  |  安裝與設定  |  URL设置出现问题 恳请帮助 « 上篇主題 下篇主題 »
頁: [1] 2
作者 主題: URL设置出现问题 恳请帮助  (閱讀 31982 次)
blackfoxz
新手見習
*
文章: 17


檢視個人資料
« 於: 七月 02, 2006, 10:45:42 上午 »

虚拟主机中lifetype1.05中URL设置出现问题
我在购买的虚拟主机中安装了lifetype1.05,同时设置二级域名http://blog.xxxx.com指向lt安装目录
然後在全域設定中base_url
設定為http://blog.xxx.com
然後subdomains_base_url关闭
.htaccess分别设置为
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
and
ErrorDocument 401 /error.php
ErrorDocument 403 /error.php
ErrorDocument 404 /error.php
开启mod_rewrite 模式,summy页面正常,也生成了http://blog.xxx..com/2_blogname/的格式,可以正常访问首页,但是却发现资源中心/ 一般分类 /文章归档/回复等都不能正常,无论点任何连接,出现的都是blog首页,把url模式改为简单模式,一切正常,自选和适宜搜索模式都不能正常显示,

r认真的翻阅了整个论坛,.htaccess尝试改过很多次,没有办法,所以发文请教
请LT前辈帮助我
已記錄
markwu
系統管理員
超級會員
*****
文章: 3928


Mark Wu


檢視個人資料 個人網站
« 回覆文章 #1 於: 七月 03, 2006, 02:08:48 下午 »

你的網站在哪?可以讓我們看一下嗎?

Mark
已記錄

blackfoxz
新手見習
*
文章: 17


檢視個人資料
« 回覆文章 #2 於: 七月 05, 2006, 09:16:37 下午 »

已经给您短信,网址在其中
感谢您的帮助
已記錄
blackfoxz
新手見習
*
文章: 17


檢視個人資料
« 回覆文章 #3 於: 七月 10, 2006, 02:54:02 上午 »

mark,烦请有空帮我看看啊
已記錄
lss
我不是被~拉~~出來的,不要叫我大大!
總版主
超級會員
*****
文章: 1511



檢視個人資料 個人網站
« 回覆文章 #4 於: 七月 10, 2006, 07:27:15 上午 »

你該不會把 .htaccess 裡面的 rewrite rule 刪了吧  挑眉質疑

就是在 RewriteBase 底下,那些以 RewriteRule 開頭的規則,那些可是讓 apache 幫你解析 mod_rewrite 網址的重要設定。

lss
已記錄

沒找過 常見問題集或不知道 如何在 LifeType 中文開發論壇發問的人,恕不回答問題
blackfoxz
新手見習
*
文章: 17


檢視個人資料
« 回覆文章 #5 於: 七月 11, 2006, 10:00:19 下午 »

lss 我的.htaccess如下:
<Files .htaccess>
deny from all
</Files>

<Files config.properties.php>
deny from all
</Files>

Options -Indexes
Options +FollowSymLinks

<IfModule mod_rewrite.c>
RewriteBase /

# Permalink to the blog entry (i.e. /blog/1_userfoo/archive/3_title-foo-bar.html)
RewriteRule ^([0-9]+)_[^/]+/archive/([0-9]+)_[^.]+\.html$ index.php?op=ViewArticle&blogId=$1&articleId=$2 [L,NC]

# Monthly archive (i.e. /blog/1_userfoo/archive/200401.html)
RewriteRule ^([0-9]+)_[^/]+/archive/([0-9]{6})\.html$ index.php?blogId=$1&Date=$2 [L,NC]

# Daily archive (i.e. /blog/1_blogfoo/archive/20040101.html)
RewriteRule ^([0-9]+)_[^/]+/archive/([0-9]{8})\.html$ index.php?blogId=$1&Date=$2 [L,NC]

# Album (i.e. /blog/88_userfoo/albums/34_title-foo-bar.html)
RewriteRule ^([0-9]+)_[^/]+/albums/([0-9]+)_[^.]+\.html$ index.php?op=ViewAlbum&blogId=$1&albumId=$2 [L,NC]

# Albums (i.e. /blog/88_userfoo/albums/)
RewriteRule ^([0-9]+)_[^/]+/albums/$ index.php?op=ViewAlbum&blogId=$1&albumId=0 [L,NC]

# Category view (i.e. /blog/88_userfoo/categories/4_cat-foobar.html)
RewriteRule ^([0-9]+)_[^/]+/categories/([0-9]+)_[^.]+\.html$ index.php?blogId=$1&postCategoryId=$2 [L,NC]

# Category-Feeds (i.e. /blog/3_userfoo/feeds/categories/2_category/atom)
RewriteRule ^([0-9]+)_[^/]+/feeds/categories/([0-9]+)_[^.]+/(.*)$ rss.php?blogId=$1&categoryId=$2&profile=$3 [L,NC]

# Feeds (i.e. /blog/3_userfoo/feeds/atom)
RewriteRule ^([0-9]+)_[^/]+/feeds/(.*)$ rss.php?blogId=$1&profile=$2 [L,NC]

# Trackbacks (i.e. /blog/3_userfoo/trackbacks/34_title-foo-bar.html)
RewriteRule ^([0-9]+)_[^/]+/trackbacks/([0-9]+)_[^.]+\.html$ index.php?op=Trackbacks&blogId=$1&articleId=$2 [L,NC]

# Comment form (i.e. /blog/88_userfoo/comment/34_title-foo-bar.html)
RewriteRule ^([0-9]+)_[^/]+/comment/([0-9]+)_[^.]+\.html$ index.php?op=Comment&blogId=$1&articleId=$2 [L,NC]

# Resources (i.e. /blog/88_userfoo/resources/this-is-a-resource-name.pdf.html)
RewriteRule ^([0-9]+)_[^/]+/resources/([^.]+)\.([^.]+)\.html$ index.php?op=ViewResource&blogId=$1&resource=$2.$3 [L,NC]

# Download a resource (i.e. /blog/88_userfoo/get/this-is-a-resource-name.pdf)
RewriteRule ^([0-9]+)_[^/]+/get/(.+)$ resserver.php?blogId=$1&resource=$2 [L,NC]

# Static Pages (i.e /blog/3_userfoo/demosites)
RewriteRule ^([0-9]+)_[^/]+/(.+)$ index.php?op=Template&blogId=$1&show=$2 [NC]

# A non-default blog (i.e. /blog/88_userfoo)
RewriteRule ^([0-9]+)(_[^/]+)?$ index.php?blogId=$1 [L,NC]

# Daily archive (i.e. /blog/1_userfoo/archive/20040101.html)
RewriteRule ^([0-9]+)_[^/]+/archive/([0-9]{8})\.html$ index.php?blogId=$1&Date=$2 [L,NC]

</IfModule>



<Files post>
 ForceType application/x-httpd-php
</Files>

<Files archives>
 ForceType application/x-httpd-php
</Files>

<Files static>
 ForceType application/x-httpd-php
</Files>

<Files rss>
 ForceType application/x-httpd-php
</Files>

<Files category>
 ForceType application/x-httpd-php
</Files>

<Files trackbacks>
 ForceType application/x-httpd-php
</Files>

<Files comment>
 ForceType application/x-httpd-php
</Files>

<Files resource>
 ForceType application/x-httpd-php
</Files>

<Files get>
 ForceType application/x-httpd-php
</Files>

<Files album>
 ForceType application/x-httpd-php
</Files>

<Files blog>
 ForceType application/x-httpd-php
</Files>

<Files user>
 ForceType application/x-httpd-php
</Files>

DirectoryIndex summary.php

ErrorDocument 401 /error.php
ErrorDocument 403 /error.php
ErrorDocument 404 /error.php

网址短信给你,也请你帮我看看
已記錄
blackfoxz
新手見習
*
文章: 17


檢視個人資料
« 回覆文章 #6 於: 七月 11, 2006, 10:02:48 下午 »

你該不會把 .htaccess 裡面的 rewrite rule 刪了吧  挑眉質疑

就是在 RewriteBase 底下,那些以 RewriteRule 開頭的規則,那些可是讓 apache 幫你解析 mod_rewrite 網址的重要設定。

lss
你这么解释倒是好像让我朦朦胧胧明白了一点点
已記錄
lss
我不是被~拉~~出來的,不要叫我大大!
總版主
超級會員
*****
文章: 1511



檢視個人資料 個人網站
« 回覆文章 #7 於: 七月 11, 2006, 10:38:17 下午 »

....
网址短信给你,也请你帮我看看
短信裡只有
引用
关于URL问题,烦请帮忙看看是怎么回事。多谢
  疑惑

lss
已記錄

沒找過 常見問題集或不知道 如何在 LifeType 中文開發論壇發問的人,恕不回答問題
markwu
系統管理員
超級會員
*****
文章: 3928


Mark Wu


檢視個人資料 個人網站
« 回覆文章 #8 於: 七月 11, 2006, 10:51:50 下午 »

不好意思!看到你的網址了!

你是用 mod_rewrite ...

我會建議你改用pretty url 或是用 custom url ... 原因是 {blogname} 在中文會有問題。

另外,你應該是改成 plain url 了吧?看不到 這樣的 http://blog.xxx..com/2_blogname/ 網址格式。

Mark
已記錄

blackfoxz
新手見習
*
文章: 17


檢視個人資料
« 回覆文章 #9 於: 七月 12, 2006, 12:03:51 上午 »

不好意思!看到你的網址了!

你是用 mod_rewrite ...

我會建議你改用pretty url 或是用 custom url ... 原因是 {blogname} 在中文會有問題。

另外,你應該是改成 plain url 了吧?看不到 這樣的 http://blog.xxx..com/2_blogname/ 網址格式。

Mark

mark 我又改成mod_rewrite了,请你再看看是怎么回事。
custom url我是没法用,现在只能用 plain url和mod_rewrite ,个人怀疑是不是.htaccess哪里有什么问题。
我将域名设置成为http://blog.XXXX.com用plain url模式都是正常的,而mod_rewrite模式有些链接不正常是不是.htaccess中哪里有没有设置到的呢?请指教
已記錄
blackfoxz
新手見習
*
文章: 17


檢視個人資料
« 回覆文章 #10 於: 七月 12, 2006, 12:10:38 上午 »

....
网址短信给你,也请你帮我看看
短信裡只有
引用
关于URL问题,烦请帮忙看看是怎么回事。多谢
  疑惑

lss
我也不知道怎么回事,又发了一遍
已記錄
blackfoxz
新手見習
*
文章: 17


檢視個人資料
« 回覆文章 #11 於: 七月 12, 2006, 12:45:11 上午 »

奇怪,我下载了lifetype-1.0.5-upgrade-lifetype-1.0.6.zip,然后升级了LT,我可以用mod_rewrite模式了,但是评论出线错误信息:参数不全。
适宜搜索引擎模式可以出http://blog.XXXX.com/1  http://blog.xxx.com/2 ,但是点击其他链接都出线了http500错误。
 custom url完全不能用,不知道到底是怎么回事
« 最後編輯時間: 七月 12, 2006, 12:47:19 上午 由 blackfoxz » 已記錄
lss
我不是被~拉~~出來的,不要叫我大大!
總版主
超級會員
*****
文章: 1511



檢視個人資料 個人網站
« 回覆文章 #12 於: 七月 12, 2006, 10:37:13 上午 »

我也不知道怎么回事,又发了一遍
還是沒有網址哦!  微笑

綜合以上症狀判斷,可能你的虛擬主機不支援 .htaccess 覆寫設定值,也就是沒有 AllowOverRide All 。

在這種情形下,有三個方法:
1.心不甘情不願的使用一般網址模式。
2.使用自訂網址模式,但是將自訂網址設定裡所有的 blog 換成 blog.php 。這個可以參考這裡: http://blog.nlhs.tyc.edu.tw/post/2/130
3.換個有支援的虛擬主機商吧。

lss
已記錄

沒找過 常見問題集或不知道 如何在 LifeType 中文開發論壇發問的人,恕不回答問題
blackfoxz
新手見習
*
文章: 17


檢視個人資料
« 回覆文章 #13 於: 七月 12, 2006, 05:01:47 下午 »

我也不知道怎么回事,又发了一遍
還是沒有網址哦!  微笑

綜合以上症狀判斷,可能你的虛擬主機不支援 .htaccess 覆寫設定值,也就是沒有 AllowOverRide All 。

在這種情形下,有三個方法:
1.心不甘情不願的使用一般網址模式。
2.使用自訂網址模式,但是將自訂網址設定裡所有的 blog 換成 blog.php 。這個可以參考這裡: http://blog.nlhs.tyc.edu.tw/post/2/130
3.換個有支援的虛擬主機商吧。

lss
非常感谢LSS,我今早用1.06升级了1.05,不知道为什么什么都没有变,居然可以了。另外我的虚拟主机的确不支持AllowOverRide All 。
我再次给你发送网址,有时间你可以看看到底是怎么回事。我现在都一头雾水,1.05不可以,升级为1.06居然可以了
已記錄
lss
我不是被~拉~~出來的,不要叫我大大!
總版主
超級會員
*****
文章: 1511



檢視個人資料 個人網站
« 回覆文章 #14 於: 七月 12, 2006, 07:09:01 下午 »

我只能說恭喜你一切正常  傷心

lss
已記錄

沒找過 常見問題集或不知道 如何在 LifeType 中文開發論壇發問的人,恕不回答問題
頁: [1] 2
LifeType 中文開發論壇  |  支援  |  安裝與設定  |  URL设置出现问题 恳请帮助 « 上篇主題 下篇主題 »
    前往: