Display home page, inside a folder on my site

-1

I have a website, where I created some pages in html inside a folder, how can I specify the home page , once user accesses the folder and the chosen page open automatically? I tried by nomenclature index.html inside the folder, it did not work ...

(Remember that it is a folder dendro, in the root of the server when I put index.html it works normally!)

    
asked by anonymous 23.07.2015 / 14:29

2 answers

0

Redirect in PHP PHP Redirect To make the user access a particular address of your site redirect to another address, inside or outside your site, you must use the location: parameter of the header () function. Here is an example of the basic use of this function:

As above, whenever the user accesses the page that contains the above code, it will be redirected automatically to link

a>. Redirection is not restricted to absolute site addresses, and you can also redirect to folders within your FTP, or even files that are in the same folder using a path relative to it. To better illustrate this, let's create a script that will capture the address it is accessed to, and redirect the user to another one according to this access address.

Remembering that for the above script to work, all the entries used in the script should be created in DNS.

    
08.06.2017 / 19:51
0

Ideally, you should rename it to index, however will only work if your site is on an apache server , otherwise not.

    
17.08.2017 / 11:39