Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- RewriteEngine ON
- ErrorDocument 404 /404.php
- RewriteRule ^users$ /?users [L]
- RewriteRule ^user/(.*)$ /?user=$1 [L]
- //php
- define('SERVER_DIR', $_SERVER['DOCUMENT_ROOT']);
- define('PAGE', str_replace('/?','', $_SERVER['REQUEST_URI']));
- if (file_exists(SERVER_DIR . '/scripts/' . PAGE . '.php')) {
- include 'scripts/' . PAGE. '.php';
- echo SERVER_DIR . '/scripts/' . PAGE . '.php';
- } elseif (empty(PAGE) || PAGE == '/') {
- echo 'galvena';
- } elseif (isset($_GET['user'])) {
- include 'scripts/user.php';
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement