a1drich Posted September 22, 2006 Share Posted September 22, 2006 hello to all.may anybody teach me how to redirect. For example, everytime i go to http://localhost/ , instead of it showing apache "It Works!" it redirects to/or displays http://localhost/index.php. and on http://localhost/administrator, it redirects automatically or displays http://localhost/administrator/index.php Quote Link to comment Share on other sites More sharing options...
wildteen88 Posted September 23, 2006 Share Posted September 23, 2006 For removing the 'It Works' page when you goto http://localhost/ remove all the Apache html files from the htdocs folder that start with [b]index.html.[i]x[/i][/b] - x being the abbriviated language, eg index.html.en and any files prefixed with apache_ eg: apache_pb2.gifFor your secound question you'll need to edit the httpd.conf file and find the following:[code]DirectoryIndex index.html index.html.var[/code]Change the above line to this:[code]DirectoryIndex index.html index.html.var index.php[/code]Save the httpd.conf file and restart the Apache server. Now when you go to http://localhost/administrator/ it should automatically loadup the index.php page. This affects any other folder to. So fi you goto http://locahost/somefolde/ Apache will automatically look for a index file listed in the DirectoryIndex directive. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.