Remove index.php from URL in Codeigniter


codetyrant

Open applications/config/config.php and make the following changes :

Replace

With

And add the following code to a new file and save it as .htaccess inside the root folder :

View original post

Advertisements

Remove index.php from URL in Codeigniter


codetyrant

Open applications/config/config.php and make the following changes :

Replace

With

And add the following code to a new file and save it as .htaccess inside the root folder :

View original post

Redirecting client to single domain name.


TechEarth

Here is a problem where a site is hosted under different virtual hosts with different domain names.

Example:
VirtualHost1 is setup for http://www.example.net
VirtualHost2 is setup for http://www.example.com

And, we want to redirect to or show only http://www.example.com domain to our clients.

Then, make some changes as below in main apache config file that is httpd.conf:

 <VirtualHost *:80>
  ServerName www.example.net
  ServerAlias example.com
  Redirect permanent / http://www.example.com/
 </VirtualHost>
<VirtualHost *:80>
 ServerName www.example.com
 DocumentRoot /usr/local/apache/htdocs
</VirtualHost>

View original post