In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
What I want to share with you in this article is about whether Mini Program can be placed on a virtual host. The editor thinks it is very practical, so I share it with you for study. I hope you can get something after reading this article. Let's take a look at it with the editor.
Yes, but because WeChat Mini Programs's official requirements document requires that the backend use HTTPS requests for network communication, and to achieve HTTPS, you must bind an SSL certificate, so when you use virtual hosts to build Mini Program, remember to install SSL certificates.
In addition, if you want to develop WeChat Mini Programs users, the domain name must be put on record. And the SSL certificate that needs to enable HTTPS encrypted access must also be a licensed domain name before it can be bound.
Domain name application and virtual host purchase, including the required SSL certificate, are best carried out on the same service provider platform, which is not only convenient to manage, but also easy to operate. For example, a website can do this work in one stop.
Virtual hosts are rich in products, ranging from shared to exclusive virtual hosts. HTTPS deployment functions have been integrated in the virtual host management panel, which can be completed in a few simple steps.
1. Log in to the website account, find it in the member center: security and monitoring management section, find the SSL certificate service, and upload the certificate to the hosting certificate.
Pay attention to the certificate of nginx, the certificate file can be opened directly with notepad, copy and paste the correct content. In some places, the certificate applied for is in .pem format. Use notepad to open the copied content directly to the certificate bar.
2. In the virtual space management panel, locate the HTTPS deployment, and click deploy. For example, if the domain name is abc.com, after deploying the SSL certificate, in order to unify the access of the HTTP page to the HTTPS page, add the following pseudo-static rule to the .htaccess file under the root directory of the virtual host:
RewriteEngine OnRewriteCond% {HTTP:From-Https}! ^ on$ [NC] RewriteCond% {HTTP_HOST} ^ (www.)? abc.com$ [NC] RewriteRule ^ (. *) $https://www.abc.com/$1 [Rene301 Magi L]
# Jump abc.com and www.abc.com to https://www.abc.com to prevent apache substations from inheriting the parent directory .htaccess
Can the above Mini Program be placed on the virtual host? the editor believes that there are some knowledge points that we may see or use in our daily work. I hope you can learn more from this article. For more details, please follow the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.