当前位置:网站首页>About the difference between root and alias under localization
About the difference between root and alias under localization
2022-07-28 18:11:00 【Ripo_ za】
This article is well written .https://www.cnblogs.com/my_life/articles/7070805.html
The following is the content of this article 
My practical application
I want to visit C:\javaweb\apache-tomcat-8.5.45\apache-tomcat-8.5.45\webapps\ROOT In the catalog index.html file . The following is an introduction to the use of root and alias How to configure localtion.

hypothesis server_name yes www.abc.com
1、 Use root
location /ROOT{
root "C:/javaweb/apache-tomcat-8.5.45/apache-tomcat-8.5.45/webapps";
index index.html;
}
In the above code
1、location Must be followed by root Subdirectory name under path , It can also be /
2、# Double quotation marks of the path can be added or not
3、 The slash of the path can be reversed or , this is it
C:\javaweb\apache-tomcat-8.5.45\apache-tomcat-8.5.45\webapps
During the visit www.abc.com/ROOT visit
2、 Use alias
location /home{
alias C:/javaweb/apache-tomcat-8.5.45/apache-tomcat-8.5.45/webapps/ROOT/;
index index.html;
}
1、 below home Where can I write any value , Acting as an agent “ Virtual path ”.
During the visit www.abc.com/home visit
边栏推荐
- Openmv (VI) -- STM32 realizes object recognition and handwritten digit recognition
- OpenMV(二)--IDE安装与固件下载
- Overflow failure of mobile terminal
- 进程、线程、信号量和互斥锁
- The video number is more like a official account of version 2.0
- com.mysql.jdbc. Configuration files of driver and com.mysql.cj.jdbc.driver
- Nearly 200000 people watched a live calligraphy video
- 中芯国际上半年净利13.86亿元,N+1工艺已进入客户产品验证阶段
- [reading notes] - 2 learn machine learning classification through naive Bayesian model
- Tensorflow2.0 (XII) -- realize simple RNN and LSTM networks
猜你喜欢

2023年网络安全预算规划的五个关键考虑因素

Idea error running 'application' command line is too long solution

OpenMV(三)--实时获取摄像头图片

The growth path of hardware engineers (0) -- Understanding components

Uniapp local packaging permission configuration problem

Digital filter (V) -- design IIR filter

OpenMV(一)--基础介绍与硬件架构

OpenMV(五)--STM32实现人脸识别

Leetcode systematic question brushing (II) -- greed, backtracking, recursion

TensorFlow2.0(十一)--理解LSTM网络
随机推荐
概率函数P(x)、概率分布函数F(x)与概率密度函数f(x)的区别
mysql5.7压缩包安装教程
"Queen's day on March 8" has doubled the sales of on-site viewers and video numbers?
Machine test questions for graduate students of Central South University
SMIC's net profit in the first half of the year was 1.386 billion yuan, and the n+1 process has entered the stage of customer product verification
1.2-hexadecimal conversion
Leetcode systematic question brushing (I) -- linked list, stack, queue, heap
[reading notes] for:object detection with deep learning: the definitive guide
Changjiang storage launched its own storage brand "Zhiti", and the first SSD product was exposed
数字滤波器(三)--模拟滤波器的设计
com.mysql.jdbc.Driver 和 com.mysql.cj.jdbc.Driver的配置文件
视频号小白起号操作指南
TensorFlow2.0(十一)--理解LSTM网络
Openmv (III) -- get camera pictures in real time
通过公众号等私域渠道,为视频号直播引流
centos8按照docker官网创wordpress+mysql报错解决
Functions brought by the binding of official account and video Number
视频号如何将公域流量将用户导入私域
xcode打包ipa配置手动配置证书
Digital filter (I) -- basic structure and matlab implementation of IIR and fir