aboutsummaryrefslogtreecommitdiffstats
path: root/index.php
diff options
context:
space:
mode:
authorMike Macgirvin <mike@macgirvin.com>2010-09-08 20:14:17 -0700
committerMike Macgirvin <mike@macgirvin.com>2010-09-08 20:14:17 -0700
commitffb1997902facb36b78a7cfa522f41f2b3d71cda (patch)
treee9fe47acf26c5fd2c742677f2610b60d3008eb26 /index.php
parentb49858b038a0a05bbe7685929e88071d0e125538 (diff)
downloadvolse-hubzilla-ffb1997902facb36b78a7cfa522f41f2b3d71cda.tar.gz
volse-hubzilla-ffb1997902facb36b78a7cfa522f41f2b3d71cda.tar.bz2
volse-hubzilla-ffb1997902facb36b78a7cfa522f41f2b3d71cda.zip
mistpark 2.0 infrasturcture lands
Diffstat (limited to 'index.php')
-rw-r--r--index.php24
1 files changed, 5 insertions, 19 deletions
diff --git a/index.php b/index.php
index c3933dc8b..8002f57fd 100644
--- a/index.php
+++ b/index.php
@@ -42,23 +42,10 @@ if(strlen($a->module)) {
}
else {
header($_SERVER["SERVER_PROTOCOL"] . ' 404 ' . t('Not Found'));
- notice( t('Page not found' ) . EOL);
+ notice( t('Page not found.' ) . EOL);
}
}
-// invoke module functions
-// Important: Modules normally do not emit content, unless you need it for debugging.
-// The module_init, module_post, and module_afterpost functions process URL parameters and POST processing.
-// The module_content function returns content text to this file where it is included on the page.
-// Modules emitting XML/Atom, etc. should do so idirectly and promptly exit before the HTML page can be rendered.
-// "Most" HTML resides in the view directory as text templates with macro substitution.
-// They look like HTML with PHP variables but only a couple pass through the PHP processor - those with .php extensions.
-// The macro substitution is defined per page for the .tpl files.
-// Information transfer between functions can be accomplished via the App session '$a' and its related variables.
-// x() queries both a variable's existence and that it is "non-zero" or "non-empty" depending on how it is called.
-// q() is the SQL query form. All string (%s) variables MUST be passed through dbesc().
-// All int values MUST be cast to integer using intval();
-
if($a->module_loaded) {
$a->page['page_title'] = $a->module;
if(function_exists($a->module . '_init')) {
@@ -85,6 +72,10 @@ if($a->module_loaded) {
}
+if(stristr($_SESSION['sysmsg'], t('Permission denied'))) {
+ header($_SERVER["SERVER_PROTOCOL"] . ' 403 ' . t('Permission denied.'));
+}
+
// report anything important happening
if(x($_SESSION,'sysmsg')) {
@@ -93,11 +84,6 @@ if(x($_SESSION,'sysmsg')) {
unset($_SESSION['sysmsg']);
}
-if(stristr($_SESSION['sysmsg'], t('Permission denied'))) {
- header($_SERVER["SERVER_PROTOCOL"] . ' 403 ' . t('Permission denied.'));
-}
-
-
// Feel free to comment out this line on production sites.
$a->page['content'] .= $debug_text;