Войти

Показать полную графическую версию : apache поддомены


Clarc
27-06-2011, 18:20
Всем привет!

Как зделать чтобы при вводе softrooom.no-ip.org открывался index.html, а при about.no-ip.org открывался about.html

И ещё как установить php? Что гд нужно прописать? Подскажите плиз:)

Sham
29-06-2011, 18:23
где хосты apache прописаны добавьте индексный файл DirectoryIndex файл.пхп

Clarc
05-07-2011, 13:08
где хосты apache прописаны добавьте индексный файл DirectoryIndex файл.пхп »
Дак я не знаю вообще не чего

Habetdin
06-07-2011, 15:09
Clarc, Установка PHP (http://www.php5.ru/study/install#php)
при about.no-ip.org открывался about.html »
В .htaccess папки сайта about.no-ip.org добавьте DirectoryIndex about.html и не забудьте сам about.html рядом разместить :)

Clarc
14-07-2011, 05:36
Clarc, Установка PHP »
Спасибо!
В .htaccess папки сайта about.no-ip.org добавьте DirectoryIndex about.html и не забудьте сам about.html рядом разместить »
Я в Apache ничего не понимаю. У меня нету никаких папок, у меня всё по умолчанию index.html и about.html находятся в папке htdocs!

Clarc
14-07-2011, 07:55
Вот что здесь не правильно?
NameVirtualHost 95.82.216.153:80
<VirtualHost 95.82.216.153:80>
ServerAdmin webmaster@may_domain.ru
DocumentRoot D:\Program Files\Apache Software Foundation\Apache2.2\htdocs\about
ServerName about.no-ip.org
ServerAlias about.no-ip.org
ErrorLog logs/mysite-error.log
CustomLog logs/mysite-access.log common
</VirtualHost>
<VirtualHost 95.82.216.153:80>
ServerAdmin webmaster@may_domain.ru
DocumentRoot D:\Program Files\Apache Software Foundation\Apache2.2\htdocs
ServerName 95.82.216.153
ServerAlias softrooom.no-ip.org
ErrorLog logs/mysite-error.log
CustomLog logs/mysite-access.log common
</VirtualHost>

Всё делал как указано здесь http://www.softtime.ru/info/articlephp.php?id_article=24

Sham
14-07-2011, 09:06
http://httpd.apache.org/docs/2.2/mod/mod_dir.html#directoryindex

добавьте в каждый VirtualHost свой DirectoryIndex

Clarc
14-07-2011, 09:29
добавьте в каждый VirtualHost свой DirectoryIndex »
Неа не хочет

я добавил DirectoryIndex index.html index.html.var index.php

Правильно?:)

<VirtualHost 95.82.216.153>
ServerAdmin webmaster@may_domain.ru
DocumentRoot D:\Program Files\Apache Software Foundation\Apache2.2\htdocs\about
DirectoryIndex about.html about.html.var about.php
ServerName about.no-ip.org
ServerAlias about.no-ip.org
ErrorLog logs/mysite-error.log
CustomLog logs/mysite-access.log common
</VirtualHost>
<VirtualHost 95.82.216.153/about>
ServerAdmin webmaster@may_domain.ru
DocumentRoot D:\Program Files\Apache Software Foundation\Apache2.2\htdocs
DirectoryIndex index.html index.html.var index.php
ServerName 95.82.216.153
ServerAlias softrooom.no-ip.org 95.82.216.153
ErrorLog logs/mysite-error.log
CustomLog logs/mysite-access.log common
</VirtualHost>

Clarc
14-07-2011, 12:28
Я чё то намутил теперь сервер запускается но выдаёт ошибку Forbidden

Habetdin
14-07-2011, 23:14
DocumentRoot D:\Program Files\Apache Software Foundation\Apache2.2\htdocs\about
DirectoryIndex about.html about.html.var about.php »
В папке D:\Program Files\Apache Software Foundation\Apache2.2\htdocs\about есть один из файлов about.html, about.html.var или about.php? И незачем указывать столько файлов, можно только один :)

Sham
15-07-2011, 03:29
<VirtualHost 95.82.216.153/about> »
что за ересь, см. http://httpd.apache.org/docs/2.2/mod/core.html#virtualhost
NameVirtualHost нужен до версии апача 2.3.11 http://httpd.apache.org/docs/2.3/mod/core.html#namevirtualhost

Clarc
15-07-2011, 12:33
В папке D:\Program Files\Apache Software Foundation\Apache2.2\htdocs\about есть один из файлов about.html, about.html.var или about.php?И незачем указывать столько файлов, можно только один »
»
есть!




© OSzone.net 2001-2012