I was working on a site that have “cache” folder inside DocumentRoot of Apache. Since this is a cache folder used by the PHP application, it need to be writable by apache user. We need to prevent access to this
To verify mod_rewrite is enabled in your Apache server, run On CentOS On Debian/Ubuntu If the command shows “rewrite_module”, you have rewrite module enabled on your Apache server. On CentOS servers, rewrite module is enabled by default. On Ubuntu/Debian, you
When you move your web site form one domain to another, you need to redirect all visitors on your old domain to new one to avoid lose of traffic. Google recommend using 301 redirect when you change URL of a
By default the document root of website on a cPanel server is /home/username/public_html . At the time anyone search a domain from there own end the site displays the index page from default location. That means from public_html folder. Here
301 redirect is a permanent redirect from one URL to the other. This is the cleanest way to redirect a URL. Quick, easy, and search-engine friendly. Remember htaccess stuff is for Apache servers only. You can use following code to
You need to run “a2enmod rewrite” to enable apache mod_rewrite. hon@hon-desktop:~/web$ sudo a2enmod rewrite Module rewrite already enabled hon@hon-desktop:~/web$ In my case it was already enabled, still .htaccess was not working. It was the default site, so i need to
