Closed Thread Icon

Topic awaiting preservation: default index.php document on apache. (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=12262" title="Pages that link to Topic awaiting preservation: default index.php document on apache. (Page 1 of 1)" rel="nofollow" >Topic awaiting preservation: default index.php document on apache. <span class="small">(Page 1 of 1)</span>\

 
jive
Paranoid (IV) Inmate

From: Greenville, SC, USA
Insane since: Jan 2002

posted posted 06-12-2002 17:03

Im trying to call up my index.php file by default on my webserver instead of having to actually type the path. (for example) I want to type :

localhost/website

instead of having to type:

localhost/website/index.php

I think I need to modify it somewhere on my httpd config file on apache webserver but I'm not sure where to do it. Any clues?



[This message has been edited by jive (edited 06-12-2002).]

[This message has been edited by jive (edited 06-12-2002).]

GRUMBLE
Paranoid (IV) Mad Scientist

From: Omicron Persei 8
Insane since: Oct 2000

posted posted 06-12-2002 17:13

<IfModule mod_dir.c>
DirectoryIndex index.html index.php
</IfModule>

jive
Paranoid (IV) Inmate

From: Greenville, SC, USA
Insane since: Jan 2002

posted posted 06-12-2002 17:20

ok thats what I have. It does pull up on the default directory. But I want to be able to do that in a subdirectory within the default directory.

ex:

localhost/defaultdirectory/subdirectory

instead of:
localhost/defaultdirectory/subdirectory/index.php



GRUMBLE
Paranoid (IV) Mad Scientist

From: Omicron Persei 8
Insane since: Oct 2000

posted posted 06-12-2002 17:32

doesnt it work with the lines i posted above for all directories?
after DirectoryIndex can stand any filename you want to be the index.

common are:

index.htm index.html index.php index.php3 default.htm

jive
Paranoid (IV) Inmate

From: Greenville, SC, USA
Insane since: Jan 2002

posted posted 06-12-2002 17:40

it works in my default directory, but its not working in a subdirectory that I put it in. I get a "page cannot be displayed". even index.html files aren't called up in a subdirectory. I have to actually type /index.html.

jive
Paranoid (IV) Inmate

From: Greenville, SC, USA
Insane since: Jan 2002

posted posted 06-12-2002 18:05

you know what, it actually works if I type the / afterwards.

ex:

localhost:/defaultdirectory/subdirectory/

instead of:

localhost/defaultdirectory/subdirectory

I shouldn't have to type the / on the end should I? I noticed on other my hosted website that I don't have to.



[This message has been edited by jive (edited 06-12-2002).]

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 06-12-2002 18:38

Oh shit this came up before and I found the answer. It has to do with your server config.

Basically Apache configured to deal with the trailing slash. It'a actually in the apache FAQ



.:[ The Tao of Steve ]:.
Be Desireless
Be Excellent
Be Gone
...................................

jive
Paranoid (IV) Inmate

From: Greenville, SC, USA
Insane since: Jan 2002

posted posted 06-12-2002 18:55

cool. That helps. I just had to change my server name to the loop back address to enable it. But I think that will eliminate any outside access wouldn't it? Tell me what you see through my ip address. What do you see?

GRUMBLE
Paranoid (IV) Mad Scientist

From: Omicron Persei 8
Insane since: Oct 2000

posted posted 06-12-2002 19:20

ah, i had that problem once too!
http://www.ozoneasylum.com/Forum12/HTML/000836.html

in my case it was a dns misconfiguration in the LAN.

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 06-12-2002 20:03

I can see it via IP.



.:[ The Tao of Steve ]:.
Be Desireless
Be Excellent
Be Gone
...................................

Veneficuz
Paranoid (IV) Inmate

From: A graveyard of dreams
Insane since: Mar 2001

posted posted 06-13-2002 13:32

At the IP I get a page called 'the Book of Lore'...

_________________________
Anyone who has lost track of time when using a computer knows the propensity to dream, the urge to make dreams come true and the tendency to miss lunch.
- copied from the wall of cell 408 -

stinx
Bipolar (III) Inmate

From: London, UK
Insane since: Apr 2002

posted posted 06-13-2002 17:04

I think the best way is to put the (external) IP as your server name.

This has worked fine for me with every server, single or multi host, that I have set up

Also, make sure that your IP is referenced in your hosts file, just to avoid a few more problems

e.g. in /etc/hosts:
24.158.64.58 machinename machinename.my.domain.name

This should sort out the problem.


« BackwardsOnwards »

Show Forum Drop Down Menu