好的,我試圖將一個網站從客戶端的1and1移動到他們自己的服務器。這是一個PHP網站。我移動了所有文件,移動了數據庫(包括指向新數據庫的文件),並且首頁工作正常(包括點擊數據庫)。默認文檔
但是,沒有鏈接工作。他們都指向不存在的文件夾。該網站是某種CMS,也許是WordPress的,也許不是。但很顯然,鏈接中的文件夾並不是真正的文件夾,而是程序爲了顯示正確內容而鍵入的內容。
我說Wordpress是因爲有一箇舊的Wordpress數據庫,但據我所知,沒有任何對話。
我可以在DB中看到一個稱爲文件夾的表,其中包含所有不存在的文件夾名稱。
我猜測這是一個網站設置問題。也許在PHP.ini或其他配置中。
對不起,如果這聽起來有點模糊。客戶端不知道它是什麼軟件,只知道如何使用它。如果您有任何問題,我可以更詳細地告訴我,請告訴我。
感謝
的index.php
<?php
/*
Lite MVC Implementation
HTTP requests should be redirected to this file if Apache can't find the page in the filesystem hierarchy.
EDITING APP PAGES:
PHP Page logic in /controller/
HTML rendering in /views/
Additional PHP classes autoloaded from /model/
Edit URI path routes (mapping URL to page logic) by editing /application/router.class.php, function getController
Hosting Requirements for CMS:
* PHP 5.2.x and later as of February 2010
* PECL Extension : HTTP (pecl_http)
* /protected/uploads should be writable by Apache
*/
$site_path = realpath(dirname(__FILE__));
define("__SITE_PATH__", $site_path);
include("global/init.php");
$registry->router = new Router($registry);
$registry->router->setPath(__SITE_PATH__ . "/controller");
$registry->router->loader();
?>
樣本文件夾將是 '服務'。此文件夾中的表中的記錄是:
3 0 Services services Manage Services Content 0 2 2 1 0 2 0 2010-02-22 05:50:39 2010-03-09 13:26:13
的.htaccess
AddHandler x-mapp-php5 .php
#php_flag session.auto_start "On"
#php_flag display_errors "On"
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php?rt=$1 [L,QSA]
數據庫表的列表並沒有幫助真的。你能否顯示主頁PHP的一個片段,其中包括一個不起作用的鏈接?另外,是的,PHP.ini文件可能不正確,但也不要忘記.htaccess文件。 – 2013-03-13 00:45:03
那些不是Wordpress表格。 – Lock 2013-03-13 01:00:35
假設Apache,是mod_rewrite啓用/你能確認所有對不存在的文件和目錄的請求被重定向到'index.php'嗎? – jeroen 2013-03-13 01:42:19