search
HomeBackend DevelopmentPHP Tutorial wampserver写的网站,怎么让外网访问

wampserver写的网站,如何让外网访问?
我在wampserver的wwww目录下面写了一个网站。现在在本公司的局域网内,别人的电脑通过我的IP地址可以访问得到我的网站。请问如何能让外网也可访问得到呢?急!

------解决方案--------------------
花生壳
------解决方案--------------------
局域网内的人通过IP可以访问你的网站吧.而不是互联网上的人能访问你的网站

1.在局域网的路由设置端口映射到你这个ip 和 端口上 80
2.注册一个国际域名指到公司的公网ip上(固定IP地址)
3.设置apache 绑定域名
------解决方案--------------------

探讨

引用:
局域网内的人通过IP可以访问你的网站吧.而不是互联网上的人能访问你的网站

1.在局域网的路由设置端口映射到你这个ip 和 端口上 80
2.注册一个国际域名指到公司的公网ip上(固定IP地址)
3.设置apache 绑定域名


谢谢!注册一个国际域名的花费大概是多少呢?如果有能零花费的方案更好了,比如说网上说的什么花生壳。因为我们只需要让省公司能访问……

------解决方案--------------------
免费注册的域名,要设置为花生壳DNS解析服务

然后安装客户端登陆帐户就激活解析了吧,一会就能访问到了。很早玩过,详细过程记不住了
------解决方案--------------------
需要改路由器把80端口的包NAT到你的内网服务器,还要在路由器上配置自动登录花生壳做DDNS,这样你买个域名就可以始终域名访问了。
------解决方案--------------------
其实你还不如花个100块钱买个虚拟主机,啥事都省了,放代码就行了。
------解决方案--------------------
很简单啊,点击右下角的wamp图标,勾选 在线,等重启好了,局域网其它的机子就可以用IP访问了,如果是外网要访问,就要在路由上设置端口影射了,假如你的apache用的是80端口你就要影射80端口到你的机子IP,如果你的电脑有防火墙,你又要得在防火墙设置下规则了。如果以上做到了,应该就能正常访问了
------解决方案--------------------
然后在外网访问就要用到外网的IP,你可以在本地打开 www.ip.cn看下你的外网IP,得到IP后,外网用户就可以通过 http://外网IP/ 这样就可以访问了(如果你的apache是80端口),如果不是80端口,就要这样访问 http://外网IP:端口号/ 这样访问
如 http://13.29.23.11:8080/
------解决方案--------------------
花生壳 外网不能用
------解决方案--------------------
下载花生壳咯~~~
------解决方案--------------------
探讨
引用:

很简单啊,点击右下角的wamp图标,勾选 在线,等重启好了,局域网其它的机子就可以用IP访问了,如果是外网要访问,就要在路由上设置端口影射了,假如你的apache用的是80端口你就要影射80端口到你的机子IP,如果你的电脑有防火墙,你又要得在防火墙设置下规则了。如果以上做到了,应该就能正常访问了


请问哪里的右下角有wamp图标?
Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
How to make PHP applications fasterHow to make PHP applications fasterMay 12, 2025 am 12:12 AM

TomakePHPapplicationsfaster,followthesesteps:1)UseOpcodeCachinglikeOPcachetostoreprecompiledscriptbytecode.2)MinimizeDatabaseQueriesbyusingquerycachingandefficientindexing.3)LeveragePHP7 Featuresforbettercodeefficiency.4)ImplementCachingStrategiessuc

PHP Performance Optimization Checklist: Improve Speed NowPHP Performance Optimization Checklist: Improve Speed NowMay 12, 2025 am 12:07 AM

ToimprovePHPapplicationspeed,followthesesteps:1)EnableopcodecachingwithAPCutoreducescriptexecutiontime.2)ImplementdatabasequerycachingusingPDOtominimizedatabasehits.3)UseHTTP/2tomultiplexrequestsandreduceconnectionoverhead.4)Limitsessionusagebyclosin

PHP Dependency Injection: Improve Code TestabilityPHP Dependency Injection: Improve Code TestabilityMay 12, 2025 am 12:03 AM

Dependency injection (DI) significantly improves the testability of PHP code by explicitly transitive dependencies. 1) DI decoupling classes and specific implementations make testing and maintenance more flexible. 2) Among the three types, the constructor injects explicit expression dependencies to keep the state consistent. 3) Use DI containers to manage complex dependencies to improve code quality and development efficiency.

PHP Performance Optimization: Database Query OptimizationPHP Performance Optimization: Database Query OptimizationMay 12, 2025 am 12:02 AM

DatabasequeryoptimizationinPHPinvolvesseveralstrategiestoenhanceperformance.1)Selectonlynecessarycolumnstoreducedatatransfer.2)Useindexingtospeedupdataretrieval.3)Implementquerycachingtostoreresultsoffrequentqueries.4)Utilizepreparedstatementsforeffi

Simple Guide: Sending Email with PHP ScriptSimple Guide: Sending Email with PHP ScriptMay 12, 2025 am 12:02 AM

PHPisusedforsendingemailsduetoitsbuilt-inmail()functionandsupportivelibrarieslikePHPMailerandSwiftMailer.1)Usethemail()functionforbasicemails,butithaslimitations.2)EmployPHPMailerforadvancedfeatureslikeHTMLemailsandattachments.3)Improvedeliverability

PHP Performance: Identifying and Fixing BottlenecksPHP Performance: Identifying and Fixing BottlenecksMay 11, 2025 am 12:13 AM

PHP performance bottlenecks can be solved through the following steps: 1) Use Xdebug or Blackfire for performance analysis to find out the problem; 2) Optimize database queries and use caches, such as APCu; 3) Use efficient functions such as array_filter to optimize array operations; 4) Configure OPcache for bytecode cache; 5) Optimize the front-end, such as reducing HTTP requests and optimizing pictures; 6) Continuously monitor and optimize performance. Through these methods, the performance of PHP applications can be significantly improved.

Dependency Injection for PHP: a quick summaryDependency Injection for PHP: a quick summaryMay 11, 2025 am 12:09 AM

DependencyInjection(DI)inPHPisadesignpatternthatmanagesandreducesclassdependencies,enhancingcodemodularity,testability,andmaintainability.Itallowspassingdependencieslikedatabaseconnectionstoclassesasparameters,facilitatingeasiertestingandscalability.

Increase PHP Performance: Caching Strategies & TechniquesIncrease PHP Performance: Caching Strategies & TechniquesMay 11, 2025 am 12:08 AM

CachingimprovesPHPperformancebystoringresultsofcomputationsorqueriesforquickretrieval,reducingserverloadandenhancingresponsetimes.Effectivestrategiesinclude:1)Opcodecaching,whichstorescompiledPHPscriptsinmemorytoskipcompilation;2)DatacachingusingMemc

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

MantisBT

MantisBT

Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

SublimeText3 English version

SublimeText3 English version

Recommended: Win version, supports code prompts!

MinGW - Minimalist GNU for Windows

MinGW - Minimalist GNU for Windows

This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

DVWA

DVWA

Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function