Poslao: 04 Nov 2013 20:49
|
offline
- Pridružio: 13 Jun 2008
- Poruke: 33
|
Pozdrav svima,
imam problem kod izmjene imena htaccess.txt u .htaccess,nikako da mi prihvati.Preko ftp vidim oba faila, kada maknem htaccess.txt neče mi raditi kada uključim rewriting,a cpanelu kada hoću napraviti reneme kaže mi da file postoji i da ne mogu promjeniti ime,naravno pretražim sve i ne vidim nigdje file htaccess da ga obrišem osim toga jednoga.
Da li da ostavim oba sa postavkama koje su potrebne ili da jednoga obrišem ali mi opet neće raditi kada uključim rewriting.
Cijeli dan se vrtim u krug,radim u joomli 2.5,čak sam u jednom trenutku i dobio da mi se otvori stranica ,bez dodatka index.php ali ćim bi krenuo dalje nema ništa..
Pošto to radim prvi put ako mi netko može kao laiku malo pojasniti proceduru bio bi zahvalan.
pozdrav svima
|
|
|
Registruj se da bi učestvovao u diskusiji. Registrovanim korisnicima se NE prikazuju reklame unutar poruka.
|
|
|
Poslao: 04 Nov 2013 23:38
|
|
@klodovik Procitaj njegov post ponovo, napisao je da koristi cPanel, izvini zbog ispravke, ali ne citas dobro koliko vidim postove, cini mi se samo djelimicno.
|
|
|
|
Poslao: 05 Nov 2013 00:36
|
offline
- Sceko
- Građanin
- Pridružio: 08 Dec 2011
- Poruke: 247
- Gde živiš: Bar
|
Jednostavno se loguj na cPanel klikni na File Menager strikiraj Show Hidden Files (dotfiles). izbrisi postojeci .htaccess i taj u .txt promeni u .htaccess
|
|
|
|
Poslao: 05 Nov 2013 00:37
|
offline
- iCho
- Elitni građanin
- Pridružio: 03 Maj 2011
- Poruke: 1808
- Gde živiš: Mos Eisley
|
Alien, imaš li ti šta konstruktivno da kažeš u diskusiji, a ne da ispravljaš druge i spamuješ?
Ludvig, jesi li pokušao rename i upload preko nekog FTP klijenta, tipa FileZilla ili samo preko cPanelovog online FTP-a?
Ako nisi, skini FileZilla, uloguj se i pokušaj da uploaduješ htaccess.txt pa da ga Rename u .htaccess.
|
|
|
|
Poslao: 05 Nov 2013 08:36
|
offline
- Pridružio: 13 Jun 2008
- Poruke: 33
|
iCho,koristim isključivo Total commander,tu se vidi i .htaccess i htaccess.txt,kopirao sam iz tekst fajla na .htaccess,izbrisao ga i u uključio rewrite u joomi,i onda mi se izgubi sve,zato sam kasnije otišao na cpanel jer sam mislio da će on nešto drugačije nači,sada idem isprobavati sa skrivenim folderima ali baš ne vjerujem u to,ipak mislim da nije greška u samom tekstu u datoteci .htaccess
|
|
|
|
Poslao: 05 Nov 2013 09:14
|
offline
- klodovik
- Saradnik foruma Linux
- Pridružio: 02 Sep 2008
- Poruke: 4094
- Gde živiš: Bg
|
2 Alien,
Svakodnevno gledam kako ljudi zovu CPanelom i Plesk, ZPanel, Kloxo, itd, a nije baš isto okruženje...pitao sam da bih pokušao dati precizan odgovor. Izvini što ti je moj post zasmetao, nisam imao nameru!
2 Ludvig,
Pokušaj dakle kroz CPanel (ako njega koristiš) i obavezno uradi bekap u slučaju da nešto krene po zlu:
1 - file manager
2 - web root i čekiraj prikaz skrivenih fajlova
3 - nađi htaccess.txt i selektuj ga
4 - u vrhu CPanela klikni na Rename (Izmeni) i snimi izmene
Takođe pogledaj da već nemaš .htaccess kao text/x-generic, a htaccess.txt je text/plain --> pogledaj pod tipom fajla
|
|
|
|
Poslao: 05 Nov 2013 09:30
|
offline
- Pridružio: 13 Jun 2008
- Poruke: 33
|
Prije nego šta krenem danas ponovo sa time,dosta imam posjetitelja pa mi je bed što se stalno stranica kao ruši ,stavljam kod da možda nije nešto u njemu krivo,ako je neispravan da ga prije stavljanja ispravim,pa ako ima neko vremena da ga pogleda
+ txt.file##
# @package Joomla
# @copyright Copyright (C) 2005 - 2012 Open Source Matters. All rights reserved.
# @license GNU General Public License version 2 or later; see LICENSE.txt
##
##
# READ THIS COMPLETELY IF YOU CHOOSE TO USE THIS FILE!
#
# The line just below this section: 'Options +FollowSymLinks' may cause problems
# with some server configurations. It is required for use of mod_rewrite, but may already
# be set by your server administrator in a way that dissallows changing it in
# your .htaccess file. If using it causes your server to error out, comment it out (add # to
# beginning of line), reload your site in your browser and test your sef url's. If they work,
# it has been set by your server administrator and you do not need it set here.
##
## Can be commented out if causes errors, see notes above.
Options +FollowSymLinks
## Mod_rewrite in use.
RewriteEngine On
## Begin - Rewrite rules to block out some common exploits.
# If you experience problems on your site block out the operations listed below
# This attempts to block the most common type of exploit `attempts` to Joomla!
#
# Block out any script trying to base64_encode data within the URL.
RewriteCond %{QUERY_STRING} base64_encode[^(]*\([^)]*\) [OR]
# Block out any script that includes a <script> tag in URL.
RewriteCond %{QUERY_STRING} (<|%3C)([^s]*s)+cript.*(>|%3E) [NC,OR]
# Block out any script trying to set a PHP GLOBALS variable via URL.
RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]
# Block out any script trying to modify a _REQUEST variable via URL.
RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})
# Return 403 Forbidden header and show the content of the root homepage
RewriteRule .* index.php [F]
#
## End - Rewrite rules to block out some common exploits.
## Begin - Custom redirects
#
# If you need to redirect some pages, or set a canonical non-www to
# www redirect (or vice versa), place that code here. Ensure those
# redirects use the correct RewriteRule syntax and the [R=301,L] flags.
#
## End - Custom redirects
##
# Uncomment following line if your webserver's URL
# is not directly related to physical file paths.
# Update Your Joomla! Directory (just / for root).
##
# RewriteBase /
## Begin - Joomla! core SEF Section.
#
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
#
# If the requested path and file is not /index.php and the request
# has not already been internally rewritten to the index.php script
RewriteCond %{REQUEST_URI} !^/index\.php
# and the request is for something within the component folder,
# or for the site root, or for an extensionless URL, or the
# requested URL ends with one of the listed extensions
RewriteCond %{REQUEST_URI} /component/|(/[^.]*|\.(php|html?|feed|pdf|vcf|raw))$ [NC]
# and the requested path and file doesn't directly match a physical file
RewriteCond %{REQUEST_FILENAME} !-f
# and the requested path and file doesn't directly match a physical folder
RewriteCond %{REQUEST_FILENAME} !-d
# internally rewrite the request to the index.php script
RewriteRule .* index.php [L]
#
## End - Joomla! core SEF Section.
# BEGIN Compress text files
<IfModule mod_deflate.c>
<FilesMatch "\.(css|js|x?html?|php)$">
SetOutputFilter DEFLATE
</FilesMatch>
</IfModule>
# END Compress text files
# BEGIN Expire headers
<IfModule mod_expires.c>
ExpiresActive On
ExpiresDefault "access plus 1 seconds"
ExpiresByType image/x-icon "access plus 2592000 seconds"
ExpiresByType image/jpeg "access plus 2592000 seconds"
ExpiresByType image/png "access plus 2592000 seconds"
ExpiresByType image/gif "access plus 2592000 seconds"
ExpiresByType application/x-shockwave-flash "access plus 2592000 seconds"
ExpiresByType text/css "access plus 604800 seconds"
ExpiresByType text/javascript "access plus 216000 seconds"
ExpiresByType application/x-javascript "access plus 216000 seconds"
ExpiresByType text/html "access plus 600 seconds"
ExpiresByType application/xhtml+xml "access plus 600 seconds"
</IfModule>
# END Expire headers
# BEGIN Cache-Control Headers
<IfModule mod_headers.c>
<FilesMatch "\\.(ico|jpe?g|png|gif|swf)$">
Header set Cache-Control "max-age=2592000, public"
</FilesMatch>
<FilesMatch "\\.(css)$">
Header set Cache-Control "max-age=604800, public"
</FilesMatch>
<FilesMatch "\\.(js)$">
Header set Cache-Control "max-age=216000, private"
</FilesMatch>
<FilesMatch "\\.(x?html?|php)$">
Header set Cache-Control "max-age=600, private, must-revalidate"
</FilesMatch>
</IfModule>
# END Cache-Control Headers
# BEGIN Turn ETags Off
<IfModule mod_headers.c>
Header unset ETag
</IfModule>
FileETag None
# END Turn ETags Off
# BEGIN Remove Last-Modified Header
<IfModule mod_headers.c>
Header unset Last-Modified
</IfModule>
# END Remove Last-Modified Header
|
|
|
|
Poslao: 05 Nov 2013 09:48
|
offline
- klodovik
- Saradnik foruma Linux
- Pridružio: 02 Sep 2008
- Poruke: 4094
- Gde živiš: Bg
|
Deluje ok, sad sam ga upoređivao sa svojim fajlom.
Ovo radiš zbog brzine stranica i Leverage browser caching-a?
Vidim da si dosta koda uneo. Jedan mali savet. Koristi "access plus 1 year" ili još direktniji pristup "access plus 1 month 15 days 2 hour" koji je lakši za čitanje i za održavanje od sekundi.
|
|
|
|
Poslao: 05 Nov 2013 10:01
|
offline
- Pridružio: 13 Jun 2008
- Poruke: 33
|
Interesantno,ne mogu naći u cpanelu opciju za skrivene fajlove,napravit ću sve ponovo opet preko Total commandera čim mi se maknu sa stranice,gledam preko GA na intervale ih dođe dosta pa ih neću smetati.
Inač u txt fajlu piše da nešto može stvarati probleme i da to treba zakomentirati...ili da se javim svom hostingu da mi riješi problem
|
|
|
|