文章 2019-06-08 来自:开发者社区

Nginx如何处理手机端和PC端跳转不同页面

如果是手机端和pc端需要跳转不同的页面, 则需要在nginx.conf中的location / {}中加入如下代码: if ($http_user_agent ~* '(Android|webOS|iPhone|iPod|BlackBerry)') { rewrite ^.+ http://127.0.0.1:8080/mobile/$uri; } 其中mobile为手机端的路径标识, ...

问答 2019-03-15 来自:开发者社区

nginx安装不能打开页面

http://47.102.213.64:80  安装nginx后,启动: 页面访问不了:显示: 连接超时 47.102.213.64 的服务器响应时间过长。     此站点暂时无法使用或者太过忙碌。请过几分钟后再试。     如果您无法载入任何网页,请检查您计算机的网络连接状态。     如果您的...

问答 2019-01-30 来自:开发者社区

nginx tp框架的 所有访问的都是默认入口的页面

NGINX 配置是用lnmp 的工具  看了没有配置fast_cache 只要修改index.php就会变成正常 之后过一阵子又出现这个问题

问答 2018-10-08 来自:开发者社区

nginx 访问http可以正常访问到页面,https访问就一直是欢迎页

需要怎么改才能正常访问到网站

文章 2018-08-10 来自:开发者社区

nginx让用户通过用户名密码认证访问web页面

在使用nginx转发的时候,要进行一次用户身份的确认。 1)通过htpasswd命令生成用户名及对应密码数据库文件 [root@localhost]# htpasswd -c /usr/local/nginx/passwd.db zutnlp //创建认证信息,zutnlp 为认证用户名 New password: ******* //输入认证密码 Re-type new passwo...

文章 2017-11-29 来自:开发者社区

nginx自定义500、404错误页面

1,首先在http添加以下内容 http{ fastcgi_intercept_errors on; } 2,server中添加以下内容: 注意路径 error_page 500 502 503 504  = /500.html; location /500.html { internal; } error_page 404   /404.html; location...

文章 2017-11-28 来自:开发者社区

powerdns与nginx结合实现以域名和IP方式访问web服务器80端口时分别跳转到不同页面

1.powerdns设置 2.内部网站介绍 web服务器采用nginx,内网dns采用powerdns. 想实现的功能如下 通过ip访问时跳转到A页面,通过域名访问时,让其跳转到B页面。两种方式的端口均为80. 页面A对应的nginx配置 server {         listen   ...

powerdns与nginx结合实现以域名和IP方式访问web服务器80端口时分别跳转到不同页面
文章 2017-11-22 来自:开发者社区

nginx 配置页面压缩

众所周知nginx的请求步骤是:客户端发送请求-->CS建立连接-->服务器响应请求。 在最后一个步骤的过程中 服务器响应客户端的请求会把客户端请求的数据回显到客户端的浏览器中,那么这个过程中我们可以做一下压缩,来提高访问速度 nginx配置如下:     http{     gzip  on;  ...

nginx 配置页面压缩
文章 2017-11-21 来自:开发者社区

nginx_status页面状态详解

开启方法:  server {  ...  location /nginx_status {           stub_status on;           access_log off;           a...

文章 2017-11-15 来自:开发者社区

NGINX下配置404错误页面的方法

,NGINX下配置自定义的404页面是可行的,而且很简单,只需如下几步: 1. 创建自己的404.html页面 2.更改nginx.conf在http定义区域加入: fastcgi_intercept_errors on; 3.更改nginx.conf(或单独网站配置文件,例如在nginx -> sites-enabled下的站点配置文件 ) 中在server 区域加入: error_pa....

本页面内关键词为智能算法引擎基于机器学习所生成,如有任何问题,可在页面下方点击"联系我们"与我们沟通。

产品推荐

{"cardStyle":"productCardStyle","productCode":"aliyun","productCardInfo":{"productTitle":"部署Nginx并通过Ingress暴露和监控服务","productDescription":"在阿里云容器服务(后简称ACK)集群中通过YAML文件快速部署一个Nginx应用并通过Nginx Ingress暴露和监控服务,结合使用ACK、日志服务、专有网络搭建业务部署运维方案。","productContentLink":"https://www.aliyun.com/solution/tech-solution/nginx_ingress","isDisplayProductIcon":true,"productButton1":{"productButtonText":"方案详情","productButtonLink":"https://www.aliyun.com/solution/tech-solution/nginx_ingress"},"productButton2":{"productButtonText":"一键部署","productButtonLink":"https://help.aliyun.com/document_detail/2400022.html"},"productButton3":{"productButtonText":"查看更多技术解决方案","productButtonLink":"https://www.aliyun.com/solution/tech-solution/"},"productPromotionInfoBlock":[{"$id":"0","productPromotionGroupingTitle":"解决方案推荐","productPromotionInfoFirstText":"MSE实现全链路灰度","productPromotionInfoFirstLink":"https://www.aliyun.com/solution/tech-solution/iflgbomse","productPromotionInfoSecondText":"云架构必修课:云上高可用架构","productPromotionInfoSecondLink":"https://www.aliyun.com/solution/tech-solution/hablog"}],"isOfficialLogo":false},"activityCardInfo":{"activityTitle":"","activityDescription":"","cardContentBackgroundMode":"LightMode","activityContentBackgroundImageLink":"","activityCardBottomInfoSelect":"activityPromotionInfoBlock"}}