As an experienced CMS website operation personnel, I am well aware of the importance of setting up and testing websites in a local environment, which not only helps us quickly iterate content and optimize user experience, but also helps us discover and solve potential problems before release.Especially for users who need to manage multiple sites or pursue the ultimate SEO effect, configuring multiple sites and pseudo-static rules is an indispensable part of local testing.Now, I will combine the features of AnQiCMS with my practical experience in the Windows environment, and give you a detailed explanation of how to configure AnQiCMS's multi-site and pseudo-static rules locally.
AnQiCMS Local Basic Overview
Perform local testing of AnQiCMS under Windows environment, we first need to ensure that the AnQiCMS core program can run normally.AnQiCMS is a lightweight system developed based on the Go language.You only need to download the AnQiCMS installation package for Windows from the official channel, unzip it to any directory on your local machine (such asD:\anqicms-test)
Double-click the run directory after extracting.anqicms.exeAn executable file, the AnQiCMS service will start. By default, AnQiCMS will listen8001Port. The first run may require you to perform initial installation, including setting up database information and admin accounts. After installation is complete, you can access it through a web browser.http://127.0.0.1:8001Check out your first AnQiCMS site.
To simulate a real online environment locally and support multi-site management and beautiful pseudo-static URLs, we usually rely on local integrated development environment software, such as the Small Skin panel (phpStudy) or the Windows version of Baota software, which can conveniently provide us with Web server (Nginx or Apache) and hosts file management features.
Configure the local Hosts file to support multiple site domains
When testing multiple sites locally, the web browser needs to know how to access these 'virtual' domain names. Since these domain names do not actually exist on public DNS servers, we need to modify the localhostsFiles, map them to the local loopback address127.0.0.1.
hostsFiles are usually located:C:\Windows\System32\drivers\etc\hosts.
You need to open with administrator privileges