Ask a Question related to PHP Development, Design and Development.
-
Lab309 #1
Newb query: index.htm & index.php & the server default
The problem I'm trying to solve is as follows:
The website has two subdirectories: /ordinary and /phpstuff. Users
typing hostname/ordinary get the file index.htm by default, and this
works fine. Users typing hostname/phpstuff don't get anything because
there is no index.htm there, only index.php.
What can I put in an index.htm file that'll invoke the index.php file?
Or is there a setting in the Apache 2.0 server I've overlooked?
Win2000; Apache 2.0.43; php 4.3.3; MySQL 4.0.15
--jim
Lab309 Guest
-
Setting index.cfm as the default document??? Yes, it hasbeen added as a default document in IIS.
I am having trouble getting IIS to recognize the default index.cfm document, and I was wondering if anyone could give me some guidance. I created a... -
default index for primary key of a table
Vinita.Bansal@trilogy.com writes: Postgres does not support UNIQUE constraints (and PRIMARY KEY implies a UNIQUE constraint) without an index.... -
default index created for primary key
Hi, I want to turn off the default setting in postgres for index creation on primary key of a table. Is it possible and how? Regards Vinita ... -
Index was out of range. Must be non-negative and less than the size of the collection. Parameter name: index
Hey Folks,(New to .NET) This is driving me NUTZ... If anyone out there can resolve this from me I would greatly appreciate it... Line 238: Line... -
Query in Index Server: @filename search problem
I try to do some search in ASP using the filename on an Index server Catalog. The filename begin with date (2001_06_13.html). I do some search with... -
Geoff Berrow #2
Re: Newb query: index.htm & index.php & the server default
I noticed that Message-ID:
<f24abf2c.0309201748.1c896624@posting.google.com > from Lab309 contained the
following:
index.php works just like index.htm>Users typing hostname/phpstuff don't get anything because
>there is no index.htm there, only index.php.
--
Geoff Berrow
It's only Usenet, no one dies.
My opinions, not the committee's, mine.
Simple RFDs [url]http://www.ckdog.co.uk/rfdmaker/[/url]
Geoff Berrow Guest
-
Arnoud Galactus Engelfriet #3
Re: Newb query: index.htm & index.php & the server default
In article <eumqmv4at7dfkfteiq107ojv91p52jd2vq@4ax.com>,
Geoff Berrow <bl@ckdog.co.uk.the.cat> wrote:Only if the server is configured that way. Sometimes you have>I noticed that Message-ID:
><f24abf2c.0309201748.1c896624@posting.google.co m> from Lab309 contained the
>following:
>>>>Users typing hostname/phpstuff don't get anything because
>>there is no index.htm there, only index.php.
>index.php works just like index.htm
to manually add index.php to the list of default filenames.
Arnoud
--
Arnoud Engelfriet, Dutch patent attorney - Speaking only for myself
Patents, copyright and IPR explained for techies: [url]http://www.iusmentis.com/[/url]
Arnoud Galactus Engelfriet Guest
-
Martin Lucas-Smith #4
Re: Newb query: index.htm & index.php & the server default
This is an Apache problem, not a PHP issue. You need to tell Apache to set> The problem I'm trying to solve is as follows: The website has two
> subdirectories: /ordinary and /phpstuff. Users typing hostname/ordinary
> get the file index.htm by default, and this works fine. Users typing
> hostname/phpstuff don't get anything because there is no index.htm
> there, only index.php. What can I put in an index.htm file that'll
> invoke the index.php file? Or is there a setting in the Apache 2.0
> server I've overlooked?
index.php as the default for that directory. The best thing to do would be
to put in your main .htaccess file:
DirectoryIndex index.html
Alternatively, you could consider parsing all .html files for PHP, so that
you don't constantly have to switch between the two, and change filenames
[thereby breaking links] every time you decide to add PHP instructions to
an .html file:
AddType application/x-httpd-php .html
Martin Lucas-Smith [url]www.geog.cam.ac.uk/~mvl22[/url]
[url]www.lucas-smith.co.uk[/url]
Martin Lucas-Smith Guest
-
John Dunlop #5
Re: Newb query: index.htm & index.php & the server default
Martin Lucas-Smith wrote:
Apache would only search for index.html then -- as it presumably does> This is an Apache problem, not a PHP issue. You need to tell Apache to set
> index.php as the default for that directory. The best thing to do would be
> to put in your main .htaccess file:
>
> DirectoryIndex index.html
in every stock installation -- and not index.php. DirectoryIndex
accepts a (space separated) list of resources, thus you can make
Apache look for index.php by appending it to that list. The first
resource found is returned.
[url]http://httpd.apache.org/docs-2.0/mod/mod_dir.html#directoryindex[/url]
--
Jock
John Dunlop Guest
-
Martin Lucas-Smith #6
Re: Newb query: index.htm & index.php & the server default
Sorry, that was a typo - I did mean>> > This is an Apache problem, not a PHP issue. You need to tell Apache to
> > set index.php as the default for that directory. The best thing to do
> > would be to put in your main .htaccess file:
> >
> > DirectoryIndex index.html
> Apache would only search for index.html then -- as it presumably does in
> every stock installation -- and not index.php. DirectoryIndex accepts a
> (space separated) list of resources, thus you can make Apache look for
> index.php by appending it to that list. The first resource found is
> returned.
DirectoryIndex index.html index.php
(This will use index.html if it finds that, if not, index.php, etc.)
Martin Lucas-Smith [url]www.geog.cam.ac.uk/~mvl22[/url]
[url]www.lucas-smith.co.uk[/url]
Martin Lucas-Smith Guest
-
Avdija A. Ahmedhodzic #7
Re: Newb query: index.htm & index.php & the server default
Lab309 wrote:
you can create .htaccess file with: "DirectoryIndex index.php"> The problem I'm trying to solve is as follows:
> The website has two subdirectories: /ordinary and /phpstuff. Users
> typing hostname/ordinary get the file index.htm by default, and this
> works fine. Users typing hostname/phpstuff don't get anything because
> there is no index.htm there, only index.php.
> What can I put in an index.htm file that'll invoke the index.php file?
> Or is there a setting in the Apache 2.0 server I've overlooked?
--
Avdija A. Ahmedhodzic
avdija @ epn ba
Prevencija putem edukacije
[url]http://www.narkomanija.ba/[/url]
Avdija A. Ahmedhodzic Guest
-
Lab309 #8
Re: Newb query: index.htm & index.php & the server default
[email]terphenyl@hotmail.com[/email] (Lab309) wrote in message news:<f24abf2c.0309201748.1c896624@posting.google. com>...
Thank you all. I'll modify the Apache file later today.> The problem I'm trying to solve is as follows:
> The website has two subdirectories: /ordinary and /phpstuff. Users
> typing hostname/ordinary get the file index.htm by default, and this
> works fine. Users typing hostname/phpstuff don't get anything because
> there is no index.htm there, only index.php.
> What can I put in an index.htm file that'll invoke the index.php file?
> Or is there a setting in the Apache 2.0 server I've overlooked?
>
> Win2000; Apache 2.0.43; php 4.3.3; MySQL 4.0.15
> --jim
--jim
Lab309 Guest



Reply With Quote

