-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.htaccess
64 lines (53 loc) · 2.78 KB
/
.htaccess
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
php_value session.gc_maxlifetime 86400
php_value session.cookie_lifetime 86400
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !index.php
ErrorDocument 404 /404/
## Футер
RewriteRule ^terms/$ /help/Terms&Conditions.php
RewriteRule ^services/$ /help/Privacy_Policy.php
RewriteRule ^support/$ /help/support.php
## Хедер
RewriteRule ^collections/$ /collections.php
RewriteRule ^help/$ /help.php
## Авторизация
RewriteRule ^login/$ /Validation-form/login-form.php
RewriteRule ^register/$ /Validation-form/register-form.php
RewriteRule ^register/email-exists/$ /Validation-form/register-form.php?error=email-exists
RewriteRule ^profile/$ /Validation-form/profile.php
RewriteRule ^login/forgot-pass/$ /Validation-form/forgot_pass.php
## Профиль
RewriteRule ^history/$ /Validation-form/History.php
RewriteRule ^favorites/$ /Validation-form/favorites.php
RewriteRule ^archives/$ /Validation-form/archives.php
RewriteRule ^rating/$ /Validation-form/rating.php
RewriteRule ^logout/$ /Validation-form/exit.php
RewriteRule ^profile/edit/$ /Validation-form/profile.php?edit
## Редактор заданий
RewriteRule ^my_base/$ /TaskEditor/my_base.php
RewriteRule ^my_base/edit/test/([0-9]+)$ /TaskEditor/edit_test.php?id=$1
RewriteRule ^my_base/edit/cards/([0-9]+)$ /TaskEditor/edit_collection.php?id=$1
RewriteRule ^my_base/delete_card/([0-9]+)/([0-9]+)$ /TaskEditor/delete_card.php?cards_id=$1&id=$2
RewriteRule ^my_base/add_card/([0-9]+)$ /TaskEditor/add_card.php?id=$1
RewriteRule ^my_base/edit_card/([0-9]+)/([0-9]+)$ /TaskEditor/edit_card.php?cards_id=$1&id=$2
RewriteRule ^my_base/delete_task/([0-9]+)/([0-9]+)$ /TaskEditor/delete_card.php?cards_id=$1&id=$2
RewriteRule ^my_base/add_task/([0-9]+)$ /TaskEditor/add_card.php?id=$1
RewriteRule ^my_base/edit_task/([0-9]+)/([0-9]+)$ /TaskEditor/edit_card.php?cards_id=$1&id=$2
## Редактор пользователей
RewriteRule ^users/$ /Validation-form/Users.php
RewriteRule ^users/edit_user/([0-9]+)$ /Validation-form/edit_user.php?id=$1
RewriteRule ^users/delete_user/([0-9]+)$ /Validation-form/delete_user.php?id=$1
RewriteRule ^users/edit_user/([0-9]+)$ /Validation-form/edit_user.php?id=$1
##Тесты и карточки
RewriteRule ^collections/cards/([0-9]+)$ /show_cards.php?id=$1
RewriteRule ^collections/get_cards/([0-9]+)$ /get_cards.php?id=$1
RewriteRule ^collections/keyboard/$ /keyboard.php
RewriteRule ^collections/cards/([0-9]+)/([0-9]+)$ /show_cards.php?id=$1&card=$2
RewriteRule ^collections/test/([0-9]+)$ /show_tasks.php?id=$1
##Тесты и карточки
RewriteRule ^test/([0-9]+)$ /test.php?id=$1
RewriteRule ^404/$ /404.php
</IfModule>