Commit 14d0f823 by Scott

Move page controllers into subdirectory

parent c37a8a02
......@@ -30,7 +30,7 @@
}
require_once QA_INCLUDE_DIR.'qa-app-limits.php';
require_once QA_INCLUDE_DIR.'qa-page-question-submit.php';
require_once QA_INCLUDE_DIR.'pages/question-submit.php';
$code=qa_post_text('code');
......
......@@ -35,7 +35,7 @@
require_once QA_INCLUDE_DIR.'qa-util-sort.php';
require_once QA_INCLUDE_DIR.'qa-util-string.php';
require_once QA_INCLUDE_DIR.'qa-app-captcha.php';
require_once QA_INCLUDE_DIR.'qa-page-question-view.php';
require_once QA_INCLUDE_DIR.'pages/question-view.php';
require_once QA_INCLUDE_DIR.'qa-app-updates.php';
$questionid=qa_request_part(0);
......@@ -162,7 +162,7 @@
}
if (qa_is_http_post() || strlen($pagestate))
require QA_INCLUDE_DIR.'qa-page-question-post.php';
require QA_INCLUDE_DIR.'pages/question-post.php';
$formrequested=isset($formtype);
......
......@@ -60,26 +60,26 @@
switch (qa_request_part(2)) {
case 'wall':
qa_set_template('user-wall');
$qa_content = include QA_INCLUDE_DIR.'qa-page-user-wall.php';
$qa_content = include QA_INCLUDE_DIR.'pages/user-wall.php';
break;
case 'activity':
qa_set_template('user-activity');
$qa_content = include QA_INCLUDE_DIR.'qa-page-user-activity.php';
$qa_content = include QA_INCLUDE_DIR.'pages/user-activity.php';
break;
case 'questions':
qa_set_template('user-questions');
$qa_content = include QA_INCLUDE_DIR.'qa-page-user-questions.php';
$qa_content = include QA_INCLUDE_DIR.'pages/user-questions.php';
break;
case 'answers':
qa_set_template('user-answers');
$qa_content = include QA_INCLUDE_DIR.'qa-page-user-answers.php';
$qa_content = include QA_INCLUDE_DIR.'pages/user-answers.php';
break;
case null:
$qa_content = include QA_INCLUDE_DIR.'qa-page-user-profile.php';
$qa_content = include QA_INCLUDE_DIR.'pages/user-profile.php';
break;
default:
......
......@@ -47,8 +47,8 @@
require_once QA_INCLUDE_DIR.'qa-app-format.php';
require_once QA_INCLUDE_DIR.'qa-app-post-create.php';
require_once QA_INCLUDE_DIR.'qa-app-cookies.php';
require_once QA_INCLUDE_DIR.'qa-page-question-view.php';
require_once QA_INCLUDE_DIR.'qa-page-question-submit.php';
require_once QA_INCLUDE_DIR.'pages/question-view.php';
require_once QA_INCLUDE_DIR.'pages/question-submit.php';
// Try to create the new answer
......
......@@ -28,8 +28,8 @@
require_once QA_INCLUDE_DIR.'qa-app-format.php';
require_once QA_INCLUDE_DIR.'qa-app-users.php';
require_once QA_INCLUDE_DIR.'qa-db-selects.php';
require_once QA_INCLUDE_DIR.'qa-page-question-view.php';
require_once QA_INCLUDE_DIR.'qa-page-question-submit.php';
require_once QA_INCLUDE_DIR.'pages/question-view.php';
require_once QA_INCLUDE_DIR.'pages/question-submit.php';
// Load relevant information about this answer
......
......@@ -28,8 +28,8 @@
require_once QA_INCLUDE_DIR.'qa-app-format.php';
require_once QA_INCLUDE_DIR.'qa-app-users.php';
require_once QA_INCLUDE_DIR.'qa-db-selects.php';
require_once QA_INCLUDE_DIR.'qa-page-question-view.php';
require_once QA_INCLUDE_DIR.'qa-page-question-submit.php';
require_once QA_INCLUDE_DIR.'pages/question-view.php';
require_once QA_INCLUDE_DIR.'pages/question-submit.php';
// Load relevant information about this comment
......
......@@ -53,8 +53,8 @@
require_once QA_INCLUDE_DIR.'qa-app-format.php';
require_once QA_INCLUDE_DIR.'qa-app-post-create.php';
require_once QA_INCLUDE_DIR.'qa-app-cookies.php';
require_once QA_INCLUDE_DIR.'qa-page-question-view.php';
require_once QA_INCLUDE_DIR.'qa-page-question-submit.php';
require_once QA_INCLUDE_DIR.'pages/question-view.php';
require_once QA_INCLUDE_DIR.'pages/question-submit.php';
require_once QA_INCLUDE_DIR.'qa-util-sort.php';
......
......@@ -28,7 +28,7 @@
require_once QA_INCLUDE_DIR.'qa-app-users.php';
require_once QA_INCLUDE_DIR.'qa-app-cookies.php';
require_once QA_INCLUDE_DIR.'qa-app-format.php';
require_once QA_INCLUDE_DIR.'qa-page-question-view.php';
require_once QA_INCLUDE_DIR.'pages/question-view.php';
require_once QA_INCLUDE_DIR.'qa-util-sort.php';
......
......@@ -212,11 +212,11 @@
} elseif (is_numeric($requestparts[0])) {
qa_set_template('question');
$qa_content=require QA_INCLUDE_DIR.'qa-page-question.php';
$qa_content=require QA_INCLUDE_DIR.'pages/question.php';
} else {
qa_set_template(strlen($firstlower) ? $firstlower : 'qa'); // will be changed later
$qa_content=require QA_INCLUDE_DIR.'qa-page-default.php'; // handles many other pages, including custom pages and page modules
$qa_content=require QA_INCLUDE_DIR.'pages/default.php'; // handles many other pages, including custom pages and page modules
}
if ($firstlower=='admin') {
......@@ -395,52 +395,52 @@
if (qa_to_override(__FUNCTION__)) { $args=func_get_args(); return qa_call_override(__FUNCTION__, $args); }
return array(
'account' => 'qa-page-account.php',
'activity/' => 'qa-page-activity.php',
'admin/' => 'qa-page-admin-default.php',
'admin/approve' => 'qa-page-admin-approve.php',
'admin/categories' => 'qa-page-admin-categories.php',
'admin/flagged' => 'qa-page-admin-flagged.php',
'admin/hidden' => 'qa-page-admin-hidden.php',
'admin/layoutwidgets' => 'qa-page-admin-widgets.php',
'admin/moderate' => 'qa-page-admin-moderate.php',
'admin/pages' => 'qa-page-admin-pages.php',
'admin/plugins' => 'qa-page-admin-plugins.php',
'admin/points' => 'qa-page-admin-points.php',
'admin/recalc' => 'qa-page-admin-recalc.php',
'admin/stats' => 'qa-page-admin-stats.php',
'admin/userfields' => 'qa-page-admin-userfields.php',
'admin/usertitles' => 'qa-page-admin-usertitles.php',
'answers/' => 'qa-page-answers.php',
'ask' => 'qa-page-ask.php',
'categories/' => 'qa-page-categories.php',
'comments/' => 'qa-page-comments.php',
'confirm' => 'qa-page-confirm.php',
'favorites' => 'qa-page-favorites.php',
'favorites/questions' => 'qa-page-favorites-list.php',
'favorites/users' => 'qa-page-favorites-list.php',
'favorites/tags' => 'qa-page-favorites-list.php',
'feedback' => 'qa-page-feedback.php',
'forgot' => 'qa-page-forgot.php',
'hot/' => 'qa-page-hot.php',
'ip/' => 'qa-page-ip.php',
'login' => 'qa-page-login.php',
'logout' => 'qa-page-logout.php',
'messages/' => 'qa-page-messages.php',
'message/' => 'qa-page-message.php',
'questions/' => 'qa-page-questions.php',
'register' => 'qa-page-register.php',
'reset' => 'qa-page-reset.php',
'search' => 'qa-page-search.php',
'tag/' => 'qa-page-tag.php',
'tags' => 'qa-page-tags.php',
'unanswered/' => 'qa-page-unanswered.php',
'unsubscribe' => 'qa-page-unsubscribe.php',
'updates' => 'qa-page-updates.php',
'user/' => 'qa-page-user.php',
'users' => 'qa-page-users.php',
'users/blocked' => 'qa-page-users-blocked.php',
'users/special' => 'qa-page-users-special.php',
'account' => 'pages/account.php',
'activity/' => 'pages/activity.php',
'admin/' => 'pages/admin/admin-default.php',
'admin/approve' => 'pages/admin/admin-approve.php',
'admin/categories' => 'pages/admin/admin-categories.php',
'admin/flagged' => 'pages/admin/admin-flagged.php',
'admin/hidden' => 'pages/admin/admin-hidden.php',
'admin/layoutwidgets' => 'pages/admin/admin-widgets.php',
'admin/moderate' => 'pages/admin/admin-moderate.php',
'admin/pages' => 'pages/admin/admin-pages.php',
'admin/plugins' => 'pages/admin/admin-plugins.php',
'admin/points' => 'pages/admin/admin-points.php',
'admin/recalc' => 'pages/admin/admin-recalc.php',
'admin/stats' => 'pages/admin/admin-stats.php',
'admin/userfields' => 'pages/admin/admin-userfields.php',
'admin/usertitles' => 'pages/admin/admin-usertitles.php',
'answers/' => 'pages/answers.php',
'ask' => 'pages/ask.php',
'categories/' => 'pages/categories.php',
'comments/' => 'pages/comments.php',
'confirm' => 'pages/confirm.php',
'favorites' => 'pages/favorites.php',
'favorites/questions' => 'pages/favorites-list.php',
'favorites/users' => 'pages/favorites-list.php',
'favorites/tags' => 'pages/favorites-list.php',
'feedback' => 'pages/feedback.php',
'forgot' => 'pages/forgot.php',
'hot/' => 'pages/hot.php',
'ip/' => 'pages/ip.php',
'login' => 'pages/login.php',
'logout' => 'pages/logout.php',
'messages/' => 'pages/messages.php',
'message/' => 'pages/message.php',
'questions/' => 'pages/questions.php',
'register' => 'pages/register.php',
'reset' => 'pages/reset.php',
'search' => 'pages/search.php',
'tag/' => 'pages/tag.php',
'tags' => 'pages/tags.php',
'unanswered/' => 'pages/unanswered.php',
'unsubscribe' => 'pages/unsubscribe.php',
'updates' => 'pages/updates.php',
'user/' => 'pages/user.php',
'users' => 'pages/users.php',
'users/blocked' => 'pages/users-blocked.php',
'users/special' => 'pages/users-special.php',
);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment