-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
beb4a3c
commit ae0f727
Showing
15 changed files
with
247 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Options -MultiViews | ||
# RewriteEngine on | ||
|
||
# Disable Directory Listings in this Directory and Subdirectories | ||
# This will hide the files from the public unless they know direct URLs | ||
Options -Indexes | ||
|
||
#I think this sets the base url of the site? | ||
# RewriteBase http://localhost/myApps/Tempsens/site/ | ||
|
||
# RewriteCond %{REQUEST_FILENAME} !d | ||
# RewriteCond ^(.+)/$ $1 [NE,R=301,L] | ||
|
||
RewriteCond %{REQUEST_FILENAME} !-d | ||
RewriteCond %{REQUEST_FILENAME} !-f | ||
# Redirecting an old directory to new directory | ||
RewriteRule ^(.+)$ site/ServerRouting.php?url=$1 [QSA,L] | ||
|
||
|
||
|
||
|
||
|
||
# http://localhost/myApps/Tempsens/site/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<?php | ||
|
||
// this kinda works, but messes relative paths up | ||
include_once "site/viewController/index.php"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
|
||
$requestedPage = $_SERVER["REQUEST_URI"]; | ||
$router = str_replace('/myApps/Tempsens/site/', '', $requestedPage); | ||
var_dump($requestedPage); | ||
echo "<br>"; | ||
var_dump($router); | ||
echo "<br>"; | ||
$allowDebug = true; | ||
if ($router == "page1"){ | ||
echo "page1"; | ||
exit(); | ||
} | ||
include_once "viewController/index.php"; | ||
exit(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.