Questions tagged as 'htaccess'

2
answers

Redirect with htaccess by holding the URL

I need to redirect a registered domain (domain.com.br) to a folder of the domain of my hosting (domain.com/exclusive), but I want to maintain the domain.com in the address bar, without losing the integrity of the URL, that is, all pages also sta...
asked by 16.09.2015 / 18:09
1
answer

What is the difference between SCRIPT_FILENAME and REQUEST_FILENAME?

I'm studying friendly URLs, and in many instances I came across these two forms of writing: RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d and RewriteCond %{SCRIPT_FILENAME} !-f RewriteCond %{SCRIPT_FILENAME} !-d...
asked by 23.11.2016 / 22:39
2
answers

Interpret and direct with URL that after domain contains a hash

I am creating a rule to interpret addresses that after domain begin with # followed by numbers or followed by letters whose rule should only be read if there is no file or directory that matches the path indicated: # Rewrite the url <...
asked by 13.03.2014 / 12:37
1
answer

How to do a redirect via .htaccess?

I'd like to redirect 15 to 20% static% from one site to another url, type: urls to http://meusite.com.br/home1.html http://novosite.com.br to http://meusite.com.br/home2.html http://novosite.com.br to h...
asked by 06.08.2015 / 02:00
2
answers

Block access to javascript files

I have a javascript file that does ajax requests for my API, but I do not want anyone to find out the link to it, is there any way to block access to this file? If you do not have some way to release so only the site can access?     
asked by 08.06.2015 / 03:21
1
answer

Force URLs with www. for without the www. with htaccess

I would like that when typing in the URL link .htaccess would always redirect to link , I need this extra 4 characters for the ad campaigns. The opposite of .htaccess is this way: RewriteEngine on RewriteBase / Options +FollowSymLinks Re...
asked by 21.09.2015 / 15:49
2
answers

How to prevent POST from outside the server?

I'm creating an application and I did not want some smart guy to think about changing the path of a POST html to send the values he wants, so I used a method in PHP: $referral=$_SERVER['HTTP_REFERER']; $origin="https://...
asked by 12.04.2015 / 10:12
1
answer

How to send a file larger than 10MB without having access to php.ini?

It is as follows: My free file hosting gives me access to see php.ini file information, but I can not modify it, I already tried to create a php.ini in the htdocs folder but it did not work, I tried to add it to the .htaccess and d...
asked by 22.02.2017 / 20:42
1
answer

HTTP and HTTPS redirection

I have a site in link and I've added an SSL certificate. I need a script via htaccess to redirect the whole site to link (301 redirect), however a single site specific page will need to be accessed via link Example: link All s...
asked by 13.06.2016 / 17:01
1
answer

Htaccess - redirecting the subdomain

I had the subdomain "b2b" .domain.com and now I have changed the files to the "catalog" .domain.com I want an htaccess rule When you enter the link No matter what level it is Be redirected to link I think that if I create seve...
asked by 27.04.2016 / 02:47