0

I want my wamp64 server webpages to can be access globally and not only from my local network.

<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>

Now, if i try to access it from my mobile, there showing an empty (white) page. Same if i put at the url /folder_name

Apache file code here: http://pastebin.com/A7xxiQ6B

ulb
  • 28
  • 1
  • 13

2 Answers2

0

This section must never be changed Specially if you are allowing the universe into your site, as this protects the root and all sub folders on the drive that Apache is installed on. Standard process is to block access to EVERYTHING which this does, and then only allow access to those folders APache actually needs access to.

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

Change it back to

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

And in this part you are using Apache 2.2 AND Apache 2.4 syntax which normally gets Apache confused. So remove the Apache 2.2 syntax so it should look like this

#   onlineoffline tag - don't remove
   Require all granted

Of course you will also need to Port Forward post 80 on your router.

And the PC running WAMPServer will need to be on a static IP address so that that port forwarding always works.

RiggsFolly
  • 93,638
  • 21
  • 103
  • 149
  • Same, nothing changed at all. For IP, i am using ddns. – ulb Jun 04 '16 at 20:34
  • Did you port forward your router – RiggsFolly Jun 05 '16 at 00:52
  • Yep, i did. Also closed firewall on PC and on low filtering on the router. – ulb Jun 05 '16 at 09:51
  • Then you may need to create a Virtual Host with the name you used for the ddns i.e. `something.ddns.org` See http://stackoverflow.com/questions/23665064/project-links-do-not-work-on-wamp-server/23990618#23990618 for help with that – RiggsFolly Jun 05 '16 at 12:42
  • Already did that. Vhosts are ok. When i am trying to access it from my mobile from example (not local network), the bar load almost half and then a white blank page is showing. – ulb Jun 05 '16 at 13:13
0

Well, the followings working for me. Figure it out :)

Just add to C:\Windows\System32\drivers\etc\hosts

# 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

If you have your httpd.conf as the following

#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>

and C:\wamp64\alias\phpmyadmin.conf

<Directory "C:/wamp64/apps/phpmyadmin4.5.2/">
    Options Indexes FollowSymLinks MultiViews
    AllowOverride all
    Require all granted
      ..............
</Directory>

You will be able (probably) too see your wamp online.

Please note you have to configure your vhosts from localhost\add_vhost.php for your every project (www/folder_name) and change the C:\wamp64\index.php from

$suppress_localhost = true;

to

$suppress_localhost = false;
ulb
  • 28
  • 1
  • 13