Questions tagged as 'htaccess'

2
answers

block access to a given directory via htacess

Well I have a folder in the root of my site called logs . Inside it I will save the logs which custom errors I mount. Well, I need to block this folder so that it can not be accessed by anyone, just by me via ftp. But php can create...
asked by 19.07.2017 / 18:16
1
answer

Redirect through htaccess

I migrated from one site to another server. On the current server, every site post had an index.php on the link www.meusite.com.br/index.php/teste On the new server I want to either stay www.meusite.com.br/teste Can you do this for .htacc...
asked by 19.07.2017 / 03:31
1
answer

.htacess issues

I made a site in Joomla and we are deploying on the client server (UOL HOST) but I came across a problem. The old site was inside the ftp folder: domain.com.br/web We put the files in another folder and upload the new content to that folde...
asked by 21.07.2017 / 20:22
1
answer

Friendly URL with htaccess pointing

My site is in a subfolder, I want the path to work regardless of what I enter in the subfolder name, for example: www.mydomain.com / any-thing / index.php www.mydomain.com / any-thing1 / index.php www.mydomain.com / any-thing2 / index.p...
asked by 28.06.2017 / 16:27
1
answer

htaccess switch "_" to "-"

I have this code that I'm using in my MVC that I did for studies: class Como_Funciona extends Controller { public function __construct() { parent::__construct(); } public function index() { $data = [...
asked by 20.08.2017 / 17:23
1
answer

www htaccess redirect with segment in url

Where my site is hosted, I'm using .htaccess and it has a condition to remove the www and direct to the main page, without the www. <ifModule mod_rewrite.c> Header set X-Frame-Options DENY RewriteEngine On # Required to allow direct-l...
asked by 19.06.2017 / 22:43
1
answer

Redirect with htaccess

I need to make a target, when the user accesses, link is directed to link Is it possible to do this with .htaccess? Here is the code I have: <ifModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_METHOD} OPTION...
asked by 18.05.2017 / 13:20
1
answer

Getting variable with $ _GET

Hello, in my htaccess it looks like this: RewriteEngine On RewriteCond %{SCRIPT_FILENAME} !-f RewriteCond %{SCRIPT_FILENAME} !-d RewriteRule ^(.*)$ index.php?url=$1 RewriteRule ^download/([A-Za-z0-9]+)$ index.php?a=download&k=$1 [QSA,L]...
asked by 22.03.2017 / 15:31
1
answer

.htaccess returns error 500 instead of 404

My .htaccess file seems to be ok, but if we try to access a page that does not exist, instead of getting the 404 error response, I get the 500 error response. This is the current code: RewriteEngine On # Remove o www e força o https # fun...
asked by 17.03.2017 / 16:01
1
answer

Problems with mod_rewrite

I'm having a problem with mod_rewrite in .htaccess. The problem is this: If I search something like Michael Jackson it looks like this: site.com/search/Michael%20Jackson/82920rdn#ir everything goes normal. But if I search Michael Jackso...
asked by 08.02.2017 / 02:25