2016-06-04 4 views
0

내 wamp64 서버 웹 페이지가 내 로컬 네트워크뿐만 아니라 전 세계에 액세스 할 수있게하려고합니다.웹 서버로 액세스 // Apache 2.4 // 전 세계적으로

<Directory /> 
    AllowOverride none 
    Require all granted 
</Directory> 

<Directory "C:/wamp64/www/"> 
    # 
    # Possible values for the Options directive are "None", "All", 
    # or any combination of: 
    # Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews 
    # 
    # Note that "MultiViews" must be named *explicitly* --- "Options All" 
    # doesn't give it to you. 
    # 
    # The Options directive is both complicated and important. Please see 
    # http://httpd.apache.org/docs/2.4/mod/core.html#options 
    # for more information. 
    # 
    Options Indexes FollowSymLinks 

    # 
    # AllowOverride controls what directives may be placed in .htaccess files. 
    # It can be "All", "None", or any combination of the keywords: 
    # AllowOverride FileInfo AuthConfig Limit 
    # 
    AllowOverride all 

    # 
    # Controls who can get stuff from this server. 
    # 

# onlineoffline tag - don't remove 
    Order allow,deny 
    Allow from all 
    Require all granted 
</Directory> 

이제 휴대 전화에서 내 페이지에 빈 페이지 (흰색)가 표시되면 액세스하려고합니다. 내가

아파치 파일 코드 여기에 URL/폴더 _에 넣으면 같은 : http://pastebin.com/A7xxiQ6B 사이트에 우주를 허용하는 경우이 루트와 모든 하위 폴더를 보호하는이 섹션은, 특별히 변경하지 말아야합니다

답변

0

아파치가 설치된 드라이브. 표준 프로세스는이 작업이 수행하는 모든 작업에 대한 액세스를 차단 한 다음 APache가 실제로 액세스해야하는 폴더에 대한 액세스 만 허용하는 것입니다. 다시

<Directory /> 
    AllowOverride none 
    Require all denied 
</Directory> 

에 그리고 당신은 아파치 2.2와 아파치 일반적으로 아파치가 혼동됩니다 2.4 구문을 사용하는이 부분에서

<Directory /> 
    AllowOverride none 
    Require all granted 
</Directory> 

변경을. 따라서 Apache 2.2 구문을 제거하면 다음과 같이 표시됩니다.

# onlineoffline tag - don't remove 
    Require all granted 

물론 포트 포워드 80을 라우터에 추가해야합니다.

WAMPServer를 실행하는 PC는 고정 IP 주소를 사용해야 포트 포워딩이 항상 작동합니다.

+0

동일하지만 아무 것도 변경되지 않았습니다. IP의 경우, 나는 ddns를 사용하고 있습니다. – ulb

+0

라우터를 포워딩 했습니까 – RiggsFolly

+0

그래, 그랬어. 또한 PC에서 방화벽을 닫고 라우터에서 필터링이 낮음. – ulb

0

글쎄, 나를 위해 일하는 다음과 같습니다.

그냥 C에 추가 :) 그것을 밖으로 그림 : 당신이있는 경우 \ WINDOWS \ system32를 \ 드라이버 \ 등 \ 호스트

# localhost name resolution is handled within DNS itself. 
    127.0.0.1  localhost <-- Uncomment this 
# ::1    localhost 
    127.0.0.1 xxxxxx.ddns.net <-- Add here your public IP or your Dynamic DNS name 

당신의 을 httpd.conf 다음

#Listen 12.34.56.78:80 
Listen 0.0.0.0:80 
Listen [::0]:80 

ServerName xxxxx.ddns.net:80 

<Directory "C:/wamp64/www/"> 
    # 
    # Possible values for the Options directive are "None", "All", 
    # or any combination of: 
    # Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews 
    # 
    # Note that "MultiViews" must be named *explicitly* --- "Options All" 
    # doesn't give it to you. 
    # 
    # The Options directive is both complicated and important. Please see 
    # http://httpd.apache.org/docs/2.4/mod/core.html#options 
    # for more information. 
    # 
    Options Indexes FollowSymLinks 

    # 
    # AllowOverride controls what directives may be placed in .htaccess files. 
    # It can be "All", "None", or any combination of the keywords: 
    # AllowOverride FileInfo AuthConfig Limit 
    # 
    AllowOverride all 

    # 
    # Controls who can get stuff from this server. 
    # 

# onlineoffline tag - don't remove 
    Require all granted 
</Directory> 

C : \ wamp64 \ alias \ phpmyadmin.conf

당신은 (아마) 너무 너의 wamp 온라인을 볼 수있을 것입니다.

당신이 에서 가상 호스트를 구성 할 필요가 있습니다 로컬 호스트 \ add_vhost.php 당신의 모든 프로젝트 (WWW/폴더 _)에 대한C 변경 : \ wamp64 \ index.php를

$suppress_localhost = true; 

에서 ~

$suppress_localhost = false; 
관련 문제