gi8ri7
#141
Hullas .htaccess ga http pratakoldan https pratakolga yo’lash uchun kod yozilgan i other/page.php ni page.php ga alishtirish kodi yozilgan shu htaccess orqali urli taxrirlangan sahifaga http pratakol bilan kirilganda sahifani asl urlni sotib qo’yayabdi
Masalan http://uzfor.uz/chat.php ga kirsez httрs://uzfor.uz/pages/chat.php ga tushas, men buni o’zimda sinab ko’rmadim i uzforda bu qanaqa yozilgan bilmayman sizlar bu nimadan deb o’ylaysizlar?
Akbarali
#142
kHakimzhon, # kHakimzhon (21.04.2020 / 19:53)
Hullas .htaccess ga http pratakoldan https pratakolga yo’lash uchun kod yozilgan i other/page.php ni page.php ga alishtirish kodi yozilgan shu htaccess orqali urli taxrirlangan sahifaga http pratakol
Siz xato qilgansiz

https://uzhackersw.uz/contact.php
https://uzhackersw.uz/pages/contact.php


http://uzhackersw.uz/contact.php
http://uzhackersw.uz/pages/contact.php


Menimcha https redriketni other/page.php ni page.php ga alishtirish kodidan keyn yozgansiz shuning uchun xato
sirli
#143
ErrorDocument 402 /error/402.html

ishlamayapti
yordam bervorila
shahzodbekpro
#144
sirli, # sirli (30.05.2020 / 19:51)
ErrorDocument 402 /error/402.html

ishlamayapti
yordam bervorila
Options -Indexes
ErrorDocument 402 http://yoqubov.uz/index.php
ErrorDocument 403 http://yoqubov.uz/index.php
ErrorDocument 404 http://yoqubov.uz/index.php
ErrorDocument 500 http://yoqubov.uz/index.php
DirectoryIndex index.php
TimX
#145
www.site.uz ni http://site.uz ga redirect qilish kodi shunday yoziladimi?
  1. RewriteEngine On
  2. RewriteCond %{HTTP_HOST} ^(.www)\.sayt\.uz$ [NC]
  3. RewriteRule ^ http://sayt.uz [L,R]
sirli
#146
shahzodbekpro, Bolmadida aka
TimX
#147
sirli, # sirli (30.05.2020 / 22:10)
shahzodbekpro, Bolmadida aka
Options -Indexes
ErrorDocument 402 /?err
ErrorDocument 403 /?err
ErrorDocument 404 /?err
ErrorDocument 500 /?err
Akbarali
#148
TimX, # TimX (30.05.2020 / 21:53)
www.site.uz ni http://site.uz ga redirect qilish kodi shunday yoziladimi?

RewriteEngine On
RewriteCond %{HTTP_HOST} ^(.www)\.sayt\.uz$ [NC]
RewriteRule ^ http://sayt.uz [L,R]
Мен ишлатаётганим
  1. HTTPS
  2. RewriteEngine On
  3. RewriteCond %{HTTPS} off
  4. RewriteCond %{HTTP:X-Forwarded-Proto} !https
  5. RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
TimX
#149
Akbarali, # Akbarali (01.06.2020 / 12:19)
TimX, Мен ишлатаётганим


HTTPS
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteCond %{HTTP:X-Forwarded-Proto} !https
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQ
Men so'ragan narsa bunaqa yozilmasligini judayam yaxshi bilib turibsizku
Akbarali
#150
TimX, # TimX (01.06.2020 / 14:27)
Akbarali, Men so'ragan narsa bunaqa yozilmasligini judayam yaxshi bilib turibsizku
нимани сураган эдингиз ?
TimX
#151
Akbarali, # Akbarali (01.06.2020 / 18:42)
TimX, нимани сураган эдингиз ?
SEO uchun 301 redirect. www ni http:// qilib o'zgartiradigan. Masalan: www.site.uz emas http://site.uz bo'lishi kerak. Agar ushbu redirect sozlanmasa, qidiruv tizimlari bu ikkisini ikki xil sayt sifatida qabul qiladi. Bu esa SEO uchun minus
code_one
#152
kHakimzhon, # kHakimzhon (21.04.2020 / 19:53)
Hullas .htaccess ga http pratakoldan https pratakolga yo’lash uchun kod yozilgan i other/page.php ni page.php ga alishtirish kodi yozilgan shu htaccess orqali urli taxrirlangan sahifaga http pratakol
.htaccess orqali URL nomini o'zgartirish:
  1. RewriteRule ^muqova.php$ /jild/muqova.php [L]

bu koddan keyin www.sayt.com/jild/muqova.php joriy manzilga o'zgaradi: sayt.com/muqova.php

manimcha siz shuni suragansiz bu bumasa uzur
98 kun 23 soat 40 daqiqa 9 soniyadan keyin yozdi:
https ni ololmayapman yordam kerak
  1. Options -Indexes
  2. ErrorDocument 402 /?err
  3. ErrorDocument 403 /?err
  4. ErrorDocument 404 /?err
  5. ErrorDocument 500 /?err
  6. DirectoryIndex index.php
  7.  
  8. RemoveHandler .phtml .php3 .php4 .php5 .php6 .phps .cgi .pl .asp .aspx .shtml .shtm .fcgi .fpl .jsp .py
  9. AddType application/x-httpd-php-source .phtml .php3 .php4 .php5 .php6 .phps .cgi .pl .asp .aspx .shtml .shtm .fcgi .fpl .jsp .py
  10.  
  11. AddDefaultCharset UTF-8
  12.  
  13. <IfModule mod_expires.c>
  14. ExpiresActive on
  15. ExpiresDefault "access plus 1 month"
  16.  
  17. # CSS
  18. ExpiresByType text/css "access plus 1 year"
  19.  
  20. # Data interchange
  21. ExpiresByType application/json "access plus 0 seconds"
  22. ExpiresByType application/ld+json "access plus 0 seconds"
  23. ExpiresByType application/xml "access plus 0 seconds"
  24. ExpiresByType text/xml "access plus 0 seconds"
  25.  
  26. # Favicon (cannot be renamed!) and cursor images
  27. ExpiresByType image/x-icon "access plus 1 week"
  28.  
  29. # HTML components (HTCs)
  30. ExpiresByType text/x-component "access plus 1 month"
  31.  
  32. # HTML
  33. ExpiresByType text/html "access plus 0 seconds"
  34.  
  35. # JavaScript
  36. ExpiresByType application/javascript "access plus 1 year"
  37.  
  38. # Manifest files
  39. ExpiresByType application/x-web-app-manifest+json "access plus 0 seconds"
  40. ExpiresByType text/cache-manifest "access plus 0 seconds"
  41.  
  42. # Media
  43. ExpiresByType audio/ogg "access plus 1 month"
  44. ExpiresByType image/gif "access plus 1 month"
  45. ExpiresByType image/jpeg "access plus 1 month"
  46. ExpiresByType image/png "access plus 1 month"
  47. ExpiresByType video/mp4 "access plus 1 month"
  48. ExpiresByType video/ogg "access plus 1 month"
  49. ExpiresByType video/webm "access plus 1 month"
  50.  
  51. # Web feeds
  52. ExpiresByType application/atom+xml "access plus 1 hour"
  53. ExpiresByType application/rss+xml "access plus 1 hour"
  54. </IfModule>

shundan keyin buni yozsam sayt ishlamay qolyapti
  1. RewriteEngine On
  2. RewriteCond %{HTTPS}!on
  3. RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}

maqsadim https olish ssl sertitikat olingan
gi8ri7
#153
Hullas, RewriteRule orqali "domain.com/info.php" "domain.com/info" ga yo'naltirilgan, agar ohiriga slash qo'yib "domain.com/info/" kirilsa 404 ga jo'natib yuboryabdi bunaqa RewriteRulelar juda ko'p shuni bittada slashsiz ham slash bilan ham kiradigon qilish kerak. Harnarsa qib ko'rdim
Akbarali
#154
Kradoff ⁾, kodni tashlang
Clever
#155
Kradoff ⁾, # Kradoff ⁾ (20.11.2021 / 05:08)
Hullas, RewriteRule orqali "domain.com/info.php" "domain.com/info" ga yo'naltirilgan, agar ohiriga slash qo'yib "domain.com/info/" kirilsa 404 ga jo'natib yuboryabdi bunaqa RewriteRulelar juda ko'p sh
$ belgisi oldidan ? belgisini qo'shib qo'ysangiz, ya'ni bunday holatda ?$ o'sha sahifaga slash qo'ysangiz ham, qo'ymasangiz ham ishlayveradi.

Kodga na'muna:
  1. RewriteRule ^id([0-9]+)?$ /user/anketa.php?id=$1 [L,QSA]
gi8ri7
#156
Clever, Ishlamadi
gi8ri7
#157
  1. AddDefaultCharset UTF-8
  2. RewriteEngine On
  3. DirectoryIndex index.php
  4.  
  5. ## EXPIRES CACHING ##
  6. # Включаем кэш в браузерах посетителей
  7. <ifModule mod_headers.c>
  8. # Все html и htm файлы будут храниться в кэше браузера один день
  9. <FilesMatch "\.(html|htm)$">
  10. Header set Cache-Control "max-age=43200"
  11. </FilesMatch>
  12. # Все css, javascript и текстовые файлы будут храниться в кэше браузера одну неделю
  13. <FilesMatch "\.(js|txt)$">
  14. Header set Cache-Control "max-age=604800"
  15. </FilesMatch>
  16. # Все флэш файлы и изображения будут храниться в кэше браузера один месяц
  17. <FilesMatch "\.(flv|swf|ico|gif|jpg|jpeg|png|svg)$">
  18. Header set Cache-Control "max-age=2592000"
  19. </FilesMatch>
  20. # Отключаем кеширование php и других служебных файлов
  21. <FilesMatch "\.(pl|php|cgi|spl|scgi|fcgi)$">
  22. Header unset Cache-Control
  23. </FilesMatch>
  24. </IfModule>
  25.  
  26. <ifModule mod_expires.c>
  27. ExpiresActive On
  28. #по умолчанию кеш в 5 секунд
  29. ExpiresDefault "access plus 5 seconds"
  30. # Включаем кэширование изображений и флэш на месяц
  31. ExpiresByType image/x-icon "access plus 1 month"
  32. ExpiresByType image/jpeg "access plus 4 weeks"
  33. ExpiresByType image/png "access plus 30 days"
  34. ExpiresByType image/gif "access plus 43829 minutes"
  35. ExpiresByType application/x-shockwave-flash "access plus 2592000 seconds"
  36. # Включаем кэширование css, javascript и текстовых файлов на одну неделю
  37. ExpiresByType text/javascript "access plus 604800 seconds"
  38. ExpiresByType application/javascript "access plus 604800 seconds"
  39. ExpiresByType application/x-javascript "access plus 604800 seconds"
  40. # Включаем кэширование html и htm файлов на один день
  41. ExpiresByType text/html "access plus 43200 seconds"
  42. # Включаем кэширование xml файлов на десять минут
  43. ExpiresByType application/xhtml+xml "access plus 600 seconds"
  44. </ifModule>
  45.  
  46. ## EXPIRES CACHING ##
  47. #Редирект с протокола http на https.#
  48. RewriteCond %{HTTPS} off
  49. RewriteCond %{HTTP:X-Forwarded-Proto} !https
  50. RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
  51. #Редирект с www на без www.#
  52. RewriteCond %{HTTP_HOST} ^www.oscore.ga
  53. RewriteRule (.*) https://oscore.ga/$1 [R=301,L]
  54. #Редирект с index.php#
  55. RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.php\ HTTP/
  56. RewriteRule ^index\.php$ https://oscore.ga/ [R=301,L]
  57.  
  58.  
  59. # Настройка
  60. RewriteRule ^change/password$ modules/settings.php?act=password [L,QSA]
  61. # Сообщения
  62. RewriteRule ^messages$ modules/messages.php [L,QSA]
  63. RewriteRule ^messages/write/([0-9]*)$ modules/messages.php?act=write&id=$1 [L,QSA]
  64. RewriteRule ^messages/view/([0-9]*)$ modules/messages.php?act=view&id=$1 [L,QSA]
  65. # Комментарии
  66. RewriteRule ^comments/delete/([0-9]*)$ modules/comments.php?act=dell&id=$1 [L,QSA]
  67. RewriteRule ^edit/comment/([0-9]*)$ modules/comments.php?act=reads&id=$1 [L,QSA]
  68. RewriteRule ^comments/reply/([0-9]*)$ modules/comments.php?act=otvet&id=$1 [L,QSA]
  69. RewriteRule ^comments/quote/([0-9]*)$ modules/comments.php?act=citat&id=$1 [L,QSA]
  70. # Анкета
  71. RewriteRule ^profile/([0-9]*)$ modules/profile.php?id=$1 [L,QSA]
  72. RewriteRule ^profile/themf/([0-9]*)$ modules/ank.php?act=themf&id=$1 [L,QSA]
  73. RewriteRule ^profile/themk/([0-9]*)$ modules/profile.php?act=themk&id=$1 [L,QSA]
  74. RewriteRule ^profile/simpa/([0-9]*)$ modules/profile.php?act=simpa&id=$1 [L,QSA]
  75. # Авторизация
  76. RewriteRule ^sign-in$ modules/system.php?act=login [L,QSA]
  77. RewriteRule ^sign-up$ modules/system.php?act=registration [L,QSA]
  78. RewriteRule ^sign-out$ modules/system.php?act=exit [L,QSA]
  79. RewriteRule ^sign-up/referral/([0-9]*)$ modules/system.php?act=reg&ref=$1 [L,QSA]
  80. # UPLOAD
  81. RewriteRule ^upload/avatar$ modules/upload.php?act=avatar [L,QSA]
  82. RewriteRule ^upload/file/([0-9]*)$ modules/upload.php?act=file&id=$1 [L,QSA]
  83. # Биллинг
  84. RewriteRule ^billing$ modules/billing.php [L,QSA]
  85. RewriteRule ^billing/services$ modules/billing.php?act=services [L,QSA]
  86. RewriteRule ^billing/services/grad$ modules/billing.php?act=grad [L,QSA]
  87. RewriteRule ^billing/services/podc$ modules/billing.php?act=podc [L,QSA]
  88. RewriteRule ^billing/services/username$ m/billing.php?act=editnick [L,QSA]
  89. RewriteRule ^billing/send$ modules/billing.php?act=perevod [L,QSA]
  90. RewriteRule ^billing/send/([0-9]*)$ m/billing.php?act=perevod&id=$1 [L,QSA]
  91. RewriteRule ^billing/send/([0-9]*)/([0-9.]*)$ modules/billing.php?act=perevod&id=$1&summa=$2 [L,QSA]
  92. # info
  93. RewriteRule ^rules$ modules/faq.php?act=rules [L,QSA]
  94. RewriteRule ^onlines$ modules/users.php?act=online [L,QSA]
  95. RewriteRule ^users$ modules/users.php?act=list [L,QSA]
  96. # Кабинет
  97. RewriteRule ^office?$ modules/office.php [L,QSA]
  98. RewriteRule ^change/avatar$ modules/settings.php?act=avatar [L,QSA]
  99. RewriteRule ^profile/edit$ modules/settings.php?act=profile [L,QSA]
  100. RewriteRule ^profile/edit/contact$ modules/settings.php?act=contact [L,QSA]
  101.  
  102. RewriteRule ^office/referral$ modules/office.php?act=referral [L,QSA]
  103. RewriteRule ^notifications$ modules/office.php?act=lenta [L,QSA]
  104. RewriteRule ^office/settings$ modules/office.php?act=sett [L,QSA]
  105. # Форум
  106. RewriteRule ^forum$ modules/forum.php [L,QSA]
  107. RewriteRule ^forum/add/category$ modules/forum.php?act=add-category [L,QSA]
  108. RewriteRule ^forum/([0-9]*)$ modules/forum.php?act=category&id=$1 [L,QSA]
  109. RewriteRule ^forum/add/subforum/([0-9]*)$ modules/forum.php?act=add-subforum&id=$1 [L,QSA]
  110. RewriteRule ^forum/([A-Za-z0-9-]+)-([0-9]*)$ modules/forum.php?act=subforum&id=$2 [L,QSA]
  111. RewriteRule ^forum/create/([0-9]*)$ modules/forum.php?act=create-topic&id=$1 [L,QSA]
  112. RewriteRule ^topic/([A-Za-z0-9-]+)-([^/]+)-([0-9]*)?$ modules/forum.php?act=topic&id=$3 [L,QSA]
  113. # js
  114. RewriteRule ^to/likes$ system/ajax/like.php [L,QSA]
  115. RewriteRule ^to/delete-file$ system/ajax/delete-file.php [L,QSA]
  116. RewriteRule ^to/podpsus$ system/ajax/podpsus.php [L,QSA]
  117. RewriteRule ^to/add-bookmarks$ system/ajax/add-bookmarks.php [L,QSA]
  118. RewriteRule ^to/sortkomm$ system/ajax/sortkomm.php [L,QSA]
  119. RewriteRule ^to/office/redkont$ system/ajax/office.php?act=redkont [L,QSA]
  120.  
  121. ErrorDocument 400 /modules/error.php?code=400
  122. ErrorDocument 401 /modules/error.php?code=401
  123. ErrorDocument 403 /modules/error.php?code=403
  124. ErrorDocument 404 /modules/error.php?code=404
  125. ErrorDocument 500 /modules/error.php?code=500
Akbarali
#158
Kradoff ⁾, RewriteRule ^office/?$ modules/office.php [L,QSA] ishlatib ko`ringchi

Kunduzi: °C

7 Feb 2026 yil
Joylashuv aniqlanmadi
CORES.UZ
Платформа разработчиков
который можно найти всё
UZFOR.NET - Rasmiy guruh
t.me/@uzfornet_rasmiy