Static publishing method without limiting column document publishing quantity based on CMS (content management system)
By generating and updating a limited set of HTML files within the CMS system, the problem of the number of documents that can be published in a category is solved, enabling rich document display and fast page response, thus improving user experience and system performance.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- TRS INFORMATION TECH CO LTD
- Filing Date
- 2026-01-07
- Publication Date
- 2026-04-17
AI Technical Summary
The current CMS system's limitation on the number of documents that can be published in a category results in insufficient data in the website's categories, poor user experience, and serious user churn, which is detrimental to the long-term operation of the website.
A static publishing method based on a CMS system is adopted, which does not limit the number of document publications for each category. Multiple overview pages under the target category are represented by generating a set of HTML files for the homepage, fragmented list, and fragmented entries. Only some HTML files are updated when the content changes, reducing storage resources and publishing congestion risks.
It increased the number of documents in the section, improved the user experience, prevented user churn, saved storage resources, and improved publishing speed.
Smart Images

Figure CN121879890A_ABST
Abstract
Description
Technical Field
[0001] This manual relates to the field of computer software technology, and in particular to a static publishing method based on a CMS system that does not limit the number of documents published in a single column. Background Technology
[0002] CMS, or Content Management System, is a system used to create, edit, and manage website content. It simplifies website development and maintenance, allowing even non-technical personnel to easily manage website content. CMS static file generation refers to preprocessing website content into static HTML files. These generated HTML files are then deployed to the website's server (i.e., static publishing). This prevents the website content from being dynamically retrieved from the database when users access it, thus speeding up page loading, reducing server load, and improving search engine optimization.
[0003] Websites generated using a CMS primarily consist of pages such as the homepage, category overview pages (also called channel pages), and document detail pages, all of which are static HTML files. In traditional static file generation methods, taking the generation of a single document as an example, in addition to generating the HTML file for the document's detail page, the overview page of the category to which that document belongs also needs to be updated. For instance, if a category has 10,000 documents, and each page displays 20 documents, then there are 500 overview pages. In this scenario, whenever a new document is published, all overview pages under that category are republished; that is, the first document is added to the first page, then the last document from the original first page is added to the second page, and so on, updating all overview pages. Of course, if the document is forwarded or referenced from other categories, generating that document will also trigger updates to the overview pages of those other categories. Similarly, deleting a document may also trigger the regeneration of a large number of overview pages, causing publishing congestion. Therefore, CMS typically limits the number of documents published in each category, which in turn limits the number of overview pages under each category. However, this can lead website visitors or administrators to believe that the document data under each category is insufficient, and it can also create a poor experience for content creators, resulting in a significant loss of website users and hindering the long-term operation of the website.
[0004] Based on this, this specification provides a static publishing method for a CMS system that does not limit the number of documents published in a given section. Summary of the Invention
[0005] To address the problems caused by existing static publishing methods that limit the number of category documents published, such as insufficient website category document data, poor user experience, high user churn, and negative impacts on long-term website operation, this specification provides a static publishing method based on a CMS system that does not limit the number of category documents published. This method uses a set of HTML files—a homepage HTML file, fragmented list HTML files, and fragmented item HTML files—to represent multiple overview pages under a target category. This saves storage resources, and when the content of the overview pages in the target category changes, only a portion of the three types of HTML files need to be updated, without needing to update all the HTML files corresponding to the overview pages under the target category. This reduces the number of HTML files that need to be modified and eliminates the need to limit the number of category documents published to reduce the risk of publishing congestion.
[0006] The following technical solution is adopted in this specification:
[0007] This specification provides a static publishing method based on a CMS system that does not limit the number of documents published in each category. The method includes:
[0008] S1: Web server configuration: Upload the configuration script to the web server and run it to configure the web server;
[0009] S2: Preset target column file storage structure: Generate a static HTML file collection for all overview interfaces in the target column and store it. The static HTML file collection includes: home page HTML file, fragmented list HTML file, and fragmented item HTML file collection. The home page HTML file is nested in the fragmented list HTML file, and the fragmented list HTML file is nested in the files in the fragmented item HTML file collection.
[0010] S3: Generate and publish the initial static HTML file set corresponding to the target column: Based on the publishing template and overview interface content corresponding to the target column, generate the initial static HTML file set corresponding to the target column through the preset target column file storage structure in the publishing engine of the CMS system and store it in the output directory; publish the output directory to the WEB server;
[0011] S4: HTML file update and republishing: When the content of the overview interface in the target column changes, the publishing engine determines whether the initial homepage HTML file, fragmented list HTML file, and initial fragmented entry HTML file set in the output directory have changed. If the HTML files have changed, they are updated and republished to the WEB server.
[0012] Optionally, the structure type of the output directory is one of the first type, the second type, and the third type;
[0013] When the structure type of the output directory is the first type, the output directory includes the initial homepage HTML file, the fragmented list HTML file, and each initial fragmented entry HTML file included in the initial fragmented entry HTML file set;
[0014] When the structure type of the output directory is the second type, the output directory includes the initial homepage HTML file, the fragmented list HTML file, and each first-level entry subdirectory. The number of the first-level entry subdirectories is preset, and each first-level entry subdirectory is used to store each initial fragmented entry HTML file included in the initial fragmented entry HTML file set.
[0015] When the structure type of the output directory is the third type, the output directory includes the initial homepage HTML file, the fragmented list HTML file, and a first-level entry subdirectory. The first-level entry subdirectory includes various second-level subdirectories. The number of second-level subdirectories is preset. Each second-level subdirectory is used to store the initial fragmented entry HTML files included in the initial fragmented entry HTML file set.
[0016] Optionally, the method for storing each initial fragmented entry HTML file in the initial fragmented entry HTML file set in step S3 is as follows:
[0017] When the structure type of the output directory is the second type or the third type, determine the number of initial fragmented entry HTML files generated and use them as the number of entries;
[0018] According to the generation order of each initial fragmented entry HTML file, each initial fragmented entry HTML file is divided into a file group, and the number of initial fragmented entry HTML files included in each file group is no greater than the preset threshold number of overview page entries.
[0019] Based on the structure type of the output directory, the directory to be stored is determined; wherein, when the structure type of the output directory is the second type, the directory to be stored is each of the first-level entry subdirectories; when the structure type of the output directory is the third type, the directory to be stored is each of the second-level subdirectories;
[0020] Set a group identifier for each file group, and determine the target storage directory corresponding to each initial fragmented entry HTML file from the storage directory based on the number of entries, the threshold number of entries on the overview page, and the group identifier for each file group.
[0021] Each initial fragmented entry HTML file is stored in the target storage directory corresponding to each initial fragmented entry HTML file.
[0022] Optionally, the method further includes:
[0023] Upon receiving a user access instruction, determine the page the user accesses based on the user access instruction;
[0024] When the page is an overview page of the target category, the entry lookup module in the WEB server searches for the initial fragmented entry HTML file included in the overview page in the output directory based on the page information in the access instruction and the preset threshold number of overview page entries.
[0025] The SSI module in the web server assembles the initial homepage HTML file, the fragmented list HTML file, and the found initial fragmented entry HTML file to obtain the overview page, which is then returned.
[0026] Optionally, the method for locating the initial fragmented entry HTML files included in the overview page is as follows:
[0027] When the structure type of the output directory is the second type or the third type, the page number of the page accessed by the user is determined according to the page information in the access instruction;
[0028] Based on the structure type of the output directory, the directory to be queried is determined; wherein, when the structure type of the output directory is the second type, the directory to be queried is each of the first-level entry subdirectories; when the structure type of the output directory is the third type, the directory to be queried is each of the second-level subdirectories;
[0029] Based on the total number of documents included in the target column, the page number, and the preset threshold number of overview page entries, the target query directory corresponding to the initial fragmented entry HTML file included in the overview page is determined in the query directory;
[0030] In the target query directory, locate the initial fragmented entry HTML file included in the overview page.
[0031] Optionally, in step S4, determining whether the initial homepage HTML file, fragmented list HTML file, and initial fragmented entry HTML file set in the output directory have changed through the publishing engine specifically includes:
[0032] When the content of the overview interface in the target section changes to the addition of a new document to the target section, the initial homepage HTML file in the output directory is determined to be the HTML file that has changed.
[0033] When the content of the overview interface in the target section changes to the deletion of documents in the target section, the initial homepage HTML file in the output directory is determined to be the HTML file that has changed.
[0034] When the content of the overview interface in the target section changes to modify the document in the target section, the initial fragmented entry HTML file corresponding to the modified document in the output directory is determined to be the changed HTML file.
[0035] Optionally, the modified HTML file is the initial homepage HTML file in the output directory;
[0036] The process of updating and republishing the changed HTML file to the web server in step S4 specifically includes:
[0037] When the content of the overview interface in the target section changes to adding a new document to the target section, the document data corresponding to the newly added document is obtained, and the number of newly added documents is determined based on the document data.
[0038] The publishing engine updates the total number of documents in the initial homepage HTML file based on the document count.
[0039] Based on the document title and publication time in the document data, generate a fragmented entry HTML file corresponding to the document data;
[0040] The updated homepage HTML file and the fragmented entry HTML files corresponding to the document data are republished to the web server.
[0041] Optionally, the modified HTML file is the initial homepage HTML file in the output directory;
[0042] The process of updating and republishing the changed HTML file to the web server in step S3 specifically includes:
[0043] When the content of the overview interface in the target column changes to deleting a document in the target column, the document data corresponding to the deleted document is obtained, and the number of deleted documents is determined based on the document data.
[0044] The publishing engine updates the total number of documents in the initial homepage HTML file based on the document count.
[0045] Generate a deletion instruction corresponding to the deleted document, the deletion instruction being used to instruct the web server to delete the fragmented entry HTML file corresponding to the deleted document;
[0046] The updated homepage HTML file is republished to the web server, and the deletion command is sent to the web server.
[0047] Optionally, the changed HTML file is the initial fragmented entry HTML file corresponding to the modified document in the output directory;
[0048] The process of updating and republishing the changed HTML file to the web server in step S3 specifically includes:
[0049] When the content of the overview interface in the target section changes to modify a document in the target section, the modification information corresponding to the modified document is determined; the modification information includes at least one of the document title and publication time;
[0050] The publishing engine updates the document information in the initial fragmented entry HTML file corresponding to the modified document based on the modification information;
[0051] The updated fragmented entry HTML file corresponding to the modified document is republished to the web server.
[0052] Optionally, S1 specifically includes:
[0053] Obtain the configuration script of the web server, wherein the configuration script includes at least SSI configuration instructions, overview page rewrite configuration instructions, and item lookup configuration instructions;
[0054] The configuration script is uploaded to the web server and run on the web server to configure the web server; the web server is configured with at least an SSI module, an overview page rewrite module, and an item search module.
[0055] Optionally, determining the page accessed by the user based on the user access instruction specifically includes:
[0056] Based on the page information in the access instruction, determine the access path corresponding to the page accessed by the user;
[0057] The overview page rewriting module in the web server determines whether the access path includes a specified identifier.
[0058] If so, determine that the page accessed by the user is an overview page;
[0059] If not, it is determined that the page accessed by the user is not an overview page.
[0060] The above-mentioned technical solutions adopted in this specification can achieve the following beneficial effects:
[0061] This manual provides a static publishing method for a CMS system that does not limit the number of documents published in a category. This method first involves uploading and running a configuration script to a web server to configure the server to support the deployment of static HTML files. A static HTML file collection is generated and stored for all overview interfaces in the target category. This collection includes a homepage HTML file, fragmented list HTML files, and a collection of fragmented item HTML files. The homepage HTML file nests fragmented list HTML files, and the fragmented list HTML files nest files from the fragmented item HTML file collection. Then, based on the publishing template and overview interface content of the target category, and using the pre-defined target category file storage structure in the CMS system's publishing engine, an initial static HTML file collection for the target category is generated and stored in the output directory. The output directory is then published to the web server. The initial homepage HTML file, fragmented list HTML file, and initial fragmented item HTML file set in the initial static HTML file set represent all overview pages under the target category, instead of using separate HTML files for each overview page under the target category. This reduces the amount of data required to represent the overview pages under the target category, saves storage resources, and improves publishing speed.
[0062] Furthermore, when the content of the overview interface in the target category changes, the publishing engine can determine whether the initial homepage HTML file, fragmented list HTML file, and initial fragmented item HTML file set in the output directory have changed. The changed HTML files are updated and republished to the web server. Only the changed HTML files need to be updated, without updating all HTML files under the target category that are affected by the content changes (such as the HTML files corresponding to all overview pages under the target category). This reduces the number of HTML files that need to be modified and eliminates the need to limit the number of category documents published to reduce the risk of publishing congestion. This improves the publishing performance of the CMS system, enriches the number of documents under the category, provides a better user experience, and prevents website user churn.
[0063] In this invention, the output directory can have multiple structural types, namely, type one, type two, and type three. The storage methods for each initial fragmented entry HTML file differ depending on the output directory's structural type. Specifically, when storing each initial fragmented entry HTML file in the initial fragmented entry HTML file set, the number of generated initial fragmented entry HTML files can be determined when the output directory's structural type is type two or three, and this number is used as the entry count. The initial fragmented entry HTML files are divided into file groups according to their generation order. The storage directory is determined based on the output directory's structural type; the storage directory differs for different structural types. For example, the storage directory for type two output directories is the subdirectories for each first-level entry, while the storage directory for type three output directories is the subdirectories for each second-level entry. A group identifier is set for each file group, and the target storage directory for each initial fragmented entry HTML file is determined from the storage directory based on the entry count, the overview page entry threshold, and the group identifier for each file group. Each initial fragmented entry HTML file is then stored in its corresponding target storage directory. By storing multiple initial fragmented entry HTML files hierarchically according to the number of generated initial fragmented entry HTML files, the threshold number of overview page entries, and group identifiers, the web server can easily find the required fragmented entry HTML files in the output directory, improving search speed and thus speeding up the return of the page to the user.
[0064] Upon receiving a user access command, this invention can determine the page the user wants to access based on the command. If the page is an overview page for the target category, the item lookup module in the web server searches the output directory for the initial fragmented item HTML files included in the overview page, based on the page information in the access command and a preset threshold number of overview page items. The SSI module in the web server then assembles the initial homepage HTML file, the fragmented list HTML file, and the found initial fragmented item HTML files to obtain the overview page, which is then returned. Since the overview page for the target category can be represented by all three types of files—the initial homepage HTML file, the fragmented list HTML file, and the initial fragmented item HTML file—upon receiving a user access command, the system can first search for the initial fragmented item HTML files included in the page the user wants to access, then assemble the found initial fragmented item HTML files with the other two files (i.e., the initial homepage HTML file and the fragmented list HTML file) to generate the page the user wants to access, and return it to the user, thus achieving a rapid response to the user's access request.
[0065] Furthermore, the query directories differ depending on the output directory structure. Specifically, the query directory for the first type of output directory is the output directory itself; for the second type, it's the subdirectories of each first-level entry; and for the third type, it's the subdirectories of each second-level entry. Multiple initial fragmented entry HTML files are stored in the output directory, the subdirectories of each first-level entry, or the subdirectories of each second-level entry. Therefore, when searching for the initial fragmented entry HTML files included in the overview page, if the output directory structure is of type two or three, the page number of the page accessed by the user can be determined based on the page information in the access instruction. The query directory is determined based on the output directory structure. Based on the total number of documents included in the target section, the page number, and the preset threshold number of overview page entries, the target query directory corresponding to the initial fragmented entry HTML files included in the overview page is determined within the query directory. The initial fragmented entry HTML files included in the overview page are searched in the target query directory, without needing to search through all initial fragmented entry HTML files, thus improving file search speed and consequently, the assembly and return speed of the overview page.
[0066] In this invention, the overview interface of the target section undergoes various content changes, and these changes correspond to different HTML files. Specifically, when the content change involves adding a new document to the target section, the initial homepage HTML file is used as the changed HTML file. When the content change involves deleting a document from the target section, the initial homepage HTML file is used as the changed HTML file. When the content change involves modifying a document in the target section, the initial fragmented entry HTML file corresponding to the modified document is identified and used as the changed HTML file. Although the changed HTML files differ for different content changes, the identified changed HTML files fall between the initial homepage HTML file and the initial fragmented entry HTML file. Furthermore, only a portion of the content in either the initial homepage HTML file or the initial fragmented entry HTML file is updated. The number of changed HTML files is significantly less than the number of HTML files required to be updated in existing solutions, thus accelerating the update speed and saving resources. Attached Figure Description
[0067] The accompanying drawings, which are included to provide a further understanding of this specification and form part of this specification, illustrate exemplary embodiments and are used to explain this specification, but do not constitute an undue limitation thereof. In the drawings:
[0068] Figure 1 This is a flowchart illustrating a static publishing method based on a CMS system that does not limit the number of documents published in a given section, as provided in this specification.
[0069] Figure 2 This is a schematic diagram of the structure of a first type of output directory provided in this specification;
[0070] Figure 3 This is a schematic diagram of the structure of a second type of output directory provided in this specification;
[0071] Figure 4 This is a schematic diagram of the structure of a third type of output directory provided in this specification. Detailed Implementation
[0072] To make the objectives, technical solutions, and advantages of this specification clearer, the technical solutions of this specification will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this specification, and not all of them. Based on the embodiments in this specification, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this specification.
[0073] This specification provides a static publishing method based on a CMS system that does not limit the number of documents published in each category. The technical solutions provided by the various embodiments of this specification are described in detail below with reference to the accompanying drawings.
[0074] Figure 1 This document presents a flowchart illustrating a static publishing method based on a CMS system that allows for unlimited publication of documents across all sections. The method includes the following steps:
[0075] S1: Web server configuration: Upload the configuration script to the web server and run it to configure the web server.
[0076] In this manual, the device used for static publishing can first be configured with a web server, that is, the configuration script is uploaded to the web server and run to configure the web server. The device used for static publishing can be a server, a system or program, or an electronic device such as a desktop computer or laptop. For ease of description, the following description focuses on the server as the execution entity, illustrating a static publishing method based on a CMS system that does not limit the number of documents published in a given category.
[0077] The aforementioned web server can be any type of server, including Nginx and Apache servers; this specification does not impose specific limitations. The web server is used to host the website; that is, the website's files are stored on the web server. When a user accesses the website through a browser, they send an access command to the web server, allowing the web server to locate the corresponding website file based on the access command and generate a page to return to the user. The aforementioned configuration script includes at least SSI configuration directives, overview page rewrite configuration directives, and entry lookup configuration directives. The aforementioned SSI configuration directives are used to configure the SSI module on the web server. This SSI module is actually SSI (Server Side Includes). The aforementioned SSI configuration directives essentially configure and enable SSI on the web server. Specifically, the aforementioned SSI configuration directives may include the directive to enable SSI, i.e., "ssi on;", and may also include directives to configure the file types that SSI can handle. These file types can be files with the extension ".shtml" or ".html". The overview page rewrite configuration directives described above configure an overview page rewrite module on the web server. This module determines whether a page accessed by a user is an overview page. The item lookup configuration directives described above configure an item lookup module on the web server. This module searches for fragmented item HTML files in the output directory. Of course, the configuration script may also include other preset directives, such as fault tolerance directives. These directives configure a fault tolerance module on the web server, which determines whether the page accessed by the user is legitimate, i.e., whether the page exists on the web server.
[0078] Specifically, the server can obtain the configuration script of the web server, upload the configuration script to the web server, and run the configuration script on the web server to configure the web server. The web server can be configured with at least an SSI module, an overview page rewrite module, and an item search module. Of course, the aforementioned web server can also be configured with a fault tolerance module.
[0079] S2: Preset target category file storage structure: Generate a static HTML file collection for all overview interfaces in the target category and store it. The static HTML file collection includes: home page HTML file, fragmented list HTML file, and fragmented item HTML file collection. The home page HTML file is nested within the fragmented list HTML file, and the fragmented list HTML file is nested within the files in the fragmented item HTML file collection.
[0080] In this specification, the server can preset the target category file storage structure, that is, generate and store a static HTML file collection of all overview interfaces in the target category. This static HTML file collection includes a homepage HTML file, fragmented list HTML files, and a fragmented item HTML file collection. The fragmented item HTML file collection includes multiple fragmented item HTML files. The homepage HTML file nests the fragmented list HTML files, and the fragmented list HTML files nest the files from the fragmented item HTML file collection. In other words, the homepage HTML file is a complete HTML document, while the fragmented list HTML files and fragmented item HTML files are fragmented HTML fragments, i.e., incomplete HTML documents. The homepage HTML file imports the fragmented list HTML files through the SSI mechanism; that is, the homepage HTML file contains code that imports the fragmented list HTML files. This code can be "<!--# include virtual="home_vchips.htm?total=15082&pagesize=20&currpage=$arg_currpage" --> In this code, "home_vchips.htm" is the name of the fragmented list HTML file, "15082" is the total number of documents under the target category (i.e., the number of fragmented HTML files in the aforementioned collection), and "20" represents the threshold number of items for the overview page (the maximum number of items (documents) that the overview page can display; this number can be set according to requirements). "currpage" represents the page number. It should be noted that the file names, total numbers, and threshold numbers included in the above code are just examples.
[0081] The aforementioned fragmented list HTML file imports fragmented item HTML files via the SSI mechanism; that is, the fragmented list HTML file contains code that imports the fragmented item HTML file. This code can be "<!--# include virtual="home / $arg_item3.htm" --> The `home / $arg_item3.htm` directive indicates the storage path of the fragmented item HTML file corresponding to the third item (the third row) in the overview page's list. The import code for the files corresponding to other items in the overview page's list is similar and will not be repeated here. It should be noted that the storage paths mentioned above are just examples. Furthermore, the number of fragmented item HTML files in the fragmented list corresponds to the preset threshold number of overview page items.
[0082] S3: Generate and publish the initial static HTML file set corresponding to the target column: Based on the publishing template and overview interface content corresponding to the target column, generate the initial static HTML file set corresponding to the target column through the preset target column file storage structure in the publishing engine of the CMS system and store it in the output directory; publish the output directory to the WEB server.
[0083] In this specification, the server can generate and publish an initial set of static HTML files corresponding to the target section. Specifically, based on the publishing template and overview interface content corresponding to the target section, the server generates the initial set of static HTML files corresponding to the target section using the preset target section file storage structure in the publishing engine of the CMS system and stores it in the output directory. The output directory is then published to the web server. The target section can be any section of any type of website; that is, the static HTML files corresponding to any section of any type of website can be generated and published using the method described in S3. Furthermore, the website is hosted by the web server configured in S1. The publishing engine in the CMS system is actually a static site generator, used to generate static HTML files for the website or section. The content data may include the section content corresponding to the target section and the document information of the documents included in the target section. The section content may include the section title, section summary, pagination indicators (i.e., "previous page," "next page," and "total," etc.), and the document information may include the document title, publication time, document author, and document content of each document under the target section. The aforementioned CMS system pre-stores publishing templates for each section of the website. These templates conform to CMS syntax and include the styles (i.e., page layouts) and placeholder areas for all overview pages under the target section. These placeholder areas need to be automatically populated based on the content data. It should be noted that the publishing templates are HTML files.
[0084] The aforementioned initial static HTML file set consists of the initial homepage HTML file, fragmented list HTML file, and initial fragmented item HTML file set for all overview interfaces in the target category, and is used to represent all overview pages under the target category. The aforementioned initial fragmented item HTML file set consists of each initial fragmented item HTML file. Furthermore, the content of each overview page is provided by the initial static HTML file, the fragmented list HTML file, and the corresponding initial fragmented item HTML file for each overview page. Each overview page (i.e., the homepage) consists of category content and a fragmented list. The fragmented list consists of fragmented items, and each fragmented item corresponds to a document under the target category; that is, each fragmented item corresponds one-to-one with each document under the target category. The number of fragmented items included in the aforementioned fragmented list is preset, i.e., the threshold number of overview page items. This threshold number can be 20, or other values, which are not specifically limited in this specification. In addition, the aforementioned initial static HTML file set may also include a document details HTML file corresponding to each document in the target category. This document details HTML file is used to provide document information, such as document title, publication time, document author, and document content.
[0085] When generating the initial static HTML file set corresponding to the target column based on the publishing template and overview interface content of the target column, and through the preset target column file storage structure in the publishing engine of the CMS system, the publishing engine of the CMS system can determine the overview interface content of the target column and use it as content data. Then, based on the content data, the content value corresponding to the placeholder area included in the publishing template is determined, and the determined content value is filled into the corresponding placeholder area in the publishing template. Based on the published template after filling and the preset target column file storage structure, the initial homepage HTML file, fragmented list HTML file, and each initial fragmented item HTML file are generated. The initial fragmented item HTML file set composed of each initial fragmented item HTML file is determined, and then the initial static HTML file set composed of the initial homepage HTML file, fragmented list HTML file, and initial fragmented item HTML file set is determined. The aforementioned content data may include the category content and document information corresponding to the target category. Each placeholder area in the publishing template has corresponding input instructions, which describe what data should be entered into the placeholder area. These instructions include a description of the data required for the placeholder area, such as document title, publication time, category content, and document author. When the publishing engine in the CMS system determines the content value corresponding to the placeholder areas in the publishing template based on the content data, it can extract data that satisfies the input instructions for each placeholder area from the content data and use this data as the content value for each placeholder area. Specifically, taking the document title as an example, the publishing engine in the CMS can extract the specific data corresponding to the document title from the content data corresponding to the target category and use this specific data as the content value for the placeholder area of the "document title" input instruction.
[0086] The aforementioned publishing template includes publishing layout parameters, which indicate that the publishing template can be divided into various regions. That is, the publishing template comprises regions, each including styles and placeholder areas. Each region corresponds to content on the homepage or overview page. In other words, regions in the publishing template correspond to category content, fragmented lists, and fragmented items. Therefore, regions in the filled-in publishing template correspond to the homepage HTML file, fragmented list HTML file, and fragmented item HTML file. When generating the initial homepage HTML file, fragmented list HTML file, and initial fragmented item HTML file based on the filled-in publishing template, the region corresponding to the fragmented list in the filled-in publishing template is used as the fragmented list HTML file, the region corresponding to the fragmented items in the filled-in publishing template is used as the initial fragmented item HTML file, and all other regions in the filled-in publishing template except for those corresponding to the fragmented list and fragmented items are used as the initial homepage HTML file.
[0087] In addition, to generate HTML files more efficiently and quickly, the aforementioned publishing templates can include a homepage template, a list template, and an item template. The homepage template includes publishing target parameters. When generating the initial static HTML file set corresponding to the target category based on the publishing template and overview interface content of the target category, using the pre-defined target category file storage structure in the CMS system's publishing engine, the CMS system's publishing engine can determine the overview interface content of the target category and use it as content data. Then, from the category content and document information in the content data, the content values corresponding to the placeholder areas included in the homepage template are determined, and the determined content values are filled into the corresponding placeholder areas in the homepage template to obtain the initial homepage HTML file. Similarly, the CMS system's publishing engine can use the document information corresponding to each document included in the target category to determine the content values corresponding to the placeholder areas included in the item template, and fill the determined content values into the corresponding placeholder areas in the item template to obtain the initial fragmented item HTML file for each document. Finally, the CMS system's publishing engine generates fragmented list HTML files based on the list template. Next, determine the initial set of fragmented entry HTML files, which consists of the initial fragmented entry HTML files corresponding to each document, and then determine the initial set of static HTML files, which consists of the initial homepage HTML file, the fragmented list HTML files, and the initial set of fragmented entry HTML files.
[0088] When storing the initial static HTML file set to the output directory, the server can directly store each HTML file in the initial static HTML file set, namely the initial homepage HTML file, the fragmented list HTML file, and each initial fragmented item HTML file in the initial fragmented item HTML file set, to the output directory.
[0089] After publishing the output directory to the web server, the web server can store the output directory in the corresponding directory of the website. Upon receiving a user access command, the web server can determine the page the user wants to access based on the command. If the page is an overview page for the target category, the web server's entry lookup module searches the output directory for the initial fragmented entry HTML files included in the overview page, based on the page information in the access command and a preset threshold number of overview page entries. The web server's SSI module then assembles the initial homepage HTML file, the fragmented list HTML file, and the found initial fragmented entry HTML files to obtain the overview page, which is then returned. The user access command is sent by the browser used to display the overview page of the website or target category. This command carries page information, which may include the page number corresponding to the page the user accessed, i.e., which page of the overview page.
[0090] When the web server entry lookup module searches for the initial fragmented entry HTML files included in the overview page in the output directory based on the page information in the access command and the preset threshold number of overview page entries, the page number of the page accessed by the user can be determined according to the page information in the access command. Based on the page number and the preset threshold number of overview page entries, the initial fragmented entry HTML files included in the overview page are then searched for in the output directory. Specifically, when searching for the initial fragmented entry HTML file corresponding to the file identifier in the output directory based on the page number and the preset threshold number of overview page entries, the initial fragmented entry HTML files in the output directory can be divided into data groups according to their generation order. The number of initial fragmented entry HTML files in each data group should not exceed the preset threshold number of overview page entries. That is, the initial fragmented entry HTML files of the preset threshold number of overview page entries are first divided into data groups according to their generation order, until all initial fragmented entry HTML files have been divided, resulting in data groups. Alternatively, the remaining initial fragmented entry HTML files can be divided into data groups until their number is less than the preset threshold number of overview page entries. The group identifier for each data group is set according to the division order, and each group identifier actually has a one-to-one correspondence with the page number corresponding to each overview page. Next, identify the group identifier in the data group that is the same as the page number, and use the initial fragmented entry HTML file included in the data group corresponding to the identified group identifier as the initial fragmented entry HTML file included in the overview page, that is, the found initial fragmented entry HTML file.
[0091] Since documents with later publication times are displayed on the overview page with smaller page numbers, the generation order of the initial fragmented entry HTML files is based on the publication time of the documents corresponding to each initial fragmented entry HTML file, from largest to smallest (i.e., from latest to earliest). For example, if file 1 was published at 11:30 AM on December 1, 2025, file 2 at 12:30 PM on December 1, 2025, file 3 at 11:30 AM on December 3, 2025, and file 4 at 1:10 AM on November 20, 2025, then the order from largest to smallest, or from latest to earliest, would be: file 3, file 2, file 1, file 4. The order of partitioning each data group represents the sequential relationship between the partitions, and the publication time of each initial fragmented entry HTML file in the earlier partitioned data group is greater than the publication time of each initial fragmented entry HTML file in the later partitioned data group. The group identifier for each data group can be set to a natural number starting from 1, and the page number can also be a natural number starting from 1. There is a one-to-one correspondence between the two, that is, the page number is the corresponding group identifier. For example, if the page number is 1, then the corresponding group identifier is 1.
[0092] In addition, when searching for the initial fragmented entry HTML files included in the overview page in the output directory based on the page number and the preset threshold number of overview page entries, the product of the page number and the preset threshold number of overview page entries is determined, and the difference between the total number of documents included in the target column and the product is determined. This difference is used as the start identifier, and the sum of the start identifier and the preset threshold number of overview page entries is determined as the end identifier. From each initial fragmented entry HTML file in the output target, the initial fragmented entry HTML file whose file identifier is greater than the start identifier and not greater than the end identifier is determined and used as the initial fragmented entry HTML file included in the overview page, i.e., the found initial fragmented entry HTML file. Each of the aforementioned initial fragmented entry HTML files has a corresponding file identifier, which can be the file name of the initial fragmented entry HTML file. The file identifier for each initial fragmented entry HTML file is a natural number set according to the publication time of each initial fragmented entry HTML file. The difference between the file identifiers of any two initial fragmented entry HTML files with adjacent publication times is 1. The larger the publication time, the larger the file identifier of the initial fragmented entry HTML file, and vice versa.
[0093] S4: HTML file update and republishing: When the content of the overview interface in the target column changes, the publishing engine determines whether the initial homepage HTML file, fragmented list HTML file, and initial fragmented entry HTML file set in the output directory have changed. If the HTML files have changed, they are updated and republished to the WEB server.
[0094] In this specification, the server can update and redistribute HTML files. Specifically, when the content of the overview interface in the target category changes, the publishing engine determines whether the initial homepage HTML file, fragmented list HTML file, and initial fragmented item HTML file set in the output directory have changed. The server then updates and redistributes the changed HTML files to the web server. Different content changes in the overview interface of the target category will result in different HTML file changes. Specifically, when the content change in the overview interface of the target category involves adding a new document to the target category, the initial homepage HTML file in the output directory is determined to be the changed HTML file. When the content change in the overview interface of the target category involves deleting a document from the target category, the initial homepage HTML file in the output directory is determined to be the changed HTML file. When the content change in the overview interface of the target category involves modifying a document in the target category, the initial fragmented item HTML file corresponding to the modified document in the output directory is determined to be the changed HTML file.
[0095] Different update methods are used for different modified HTML files. Specifically, the modified HTML file can be the initial homepage HTML file in the output directory. When the modified HTML file is updated and republished to the web server in step S4, if the content of the overview interface in the target section changes to adding a new document to the target section, the document data corresponding to the newly added document is obtained, and the number of newly added documents is determined based on the document data. The total number of documents in the initial homepage HTML file is updated using the publishing engine based on the document number. Fragmented entry HTML files corresponding to the document data are generated based on the document title and publication time in the document data. The updated homepage HTML file and the fragmented entry HTML files corresponding to the document data are republished to the web server. The document data includes the number of newly added documents, the document title, publication time, document author, and document content of each newly added document (i.e., document information). When updating the total number of documents in the initial homepage HTML file based on the document count using the publishing engine, the total number of documents in the initial homepage HTML file before the update can be obtained. This initial total number of documents is then determined, and the sum of the initial total number of documents and the document count is calculated. The total number of documents in the initial homepage HTML file before the update is then updated to the calculated sum, resulting in the updated homepage HTML file. The process of generating fragmented entry HTML files corresponding to the document data based on the document title and publication time is similar to the process of generating the initial fragmented entry HTML file, and will not be repeated here. After republishing, the initial homepage HTML file stored on the web server can be replaced with the updated homepage HTML file, and the fragmented entry HTML files can be stored in the output directory. The specific storage process is similar to the process of storing the initial fragmented entry HTML files, and will not be repeated here.
[0096] In addition, the aforementioned modified HTML file is also the initial homepage HTML file in the output directory. In step S3, when the modified HTML file is updated and republished to the web server, if the content of the overview interface in the target category changes to deleting documents from the target category, the document data corresponding to the deleted document is obtained, and the number of deleted documents is determined based on the document data. The total number of documents in the initial homepage HTML file is updated by the publishing engine based on the document count. A deletion instruction corresponding to the deleted document is generated, which instructs the web server to delete the fragmented entry HTML file corresponding to the deleted document. The updated homepage HTML file is republished to the web server, and the deletion instruction is sent to the web server. The aforementioned document data includes the number of deleted documents, the document title, publication time, document author, and document content of each deleted document (i.e., document information). When updating the total number of documents in the initial homepage HTML file based on the document count using the publishing engine, the total number of documents in the initial homepage HTML file before the update can be obtained. This initial total number of documents is then determined, and the sum of the initial total number of documents and the document count is calculated. The total number of documents in the initial homepage HTML file before the update is then updated to the calculated sum, resulting in the updated homepage HTML file. The deletion command can include the file identifier corresponding to the fragmented entry HTML file of the document to be deleted. After republishing, the initial homepage HTML file stored on the web server can be replaced with the updated homepage HTML file, and the fragmented entry HTML files corresponding to the file identifiers in the deletion command can be deleted in the output directory. The process of finding the fragmented entry HTML files to be deleted is similar to the process of finding the initial fragmented entry HTML files, and will not be repeated here.
[0097] Additionally, the aforementioned changed HTML file can also be the initial fragmented entry HTML file corresponding to the modified document in the output directory. In step S3, when the changed HTML file is updated and republished to the web server, if the content of the overview interface in the target section changes to modifying a document in the target section, the modification information corresponding to the modified document is determined. The modification information includes at least one of the document title and publication time. The publishing engine updates the document information in the initial fragmented entry HTML file corresponding to the modified document based on the modification information. The updated fragmented entry HTML file corresponding to the modified document is then republished to the web server. Specifically, when updating the document information in the initial fragmented entry HTML file corresponding to the modified document through the publishing engine based on the modification information, the unupdated initial fragmented entry HTML file corresponding to the modified document can be obtained. Based on the modification information, the document information in the obtained unupdated initial fragmented entry HTML file is modified to obtain the updated fragmented entry HTML file corresponding to the modified document. For example, taking the document title as the modification information, the document title in the obtained unupdated initial fragmented entry HTML file can be modified to match the document title in the modification information. After republishing, the initially fragmented entry HTML file corresponding to the modified document stored on the web server can be replaced with the updated fragmented entry HTML file. Specifically, this can be done by searching for the file identifier of the initially fragmented entry HTML file corresponding to the modified document in the output directory and replacing it.
[0098] In some embodiments of this specification, the aforementioned static HTML file set or initial static HTML file set can be stored in the output directory according to a hierarchical directory format. That is, the structure type of the output directory can be one of the first, second, and third types. When the structure type of the output directory is the first type, the output directory includes the initial homepage HTML file (or the homepage HTML file), the fragmented list HTML file, and each initial fragmented entry HTML file (or fragmented entry HTML file) included in the initial fragmented entry HTML file set (or fragmented entry HTML file set). Specifically, as follows... Figure 2 As shown, Figure 2 This is a schematic diagram of the structure of a first type of output directory provided in this specification. Figure 2 The output directory shown includes the homepage HTML file, the fragmented list HTML file, and the collection of fragmented entry HTML files, each containing an HTML file for a fragmented entry (i.e., ...). Figure 2 Fragmented entries in HTML files (1-M). Figure 2Files within the dashed box belong to the same level, meaning they are stored in the same directory (or subdirectory).
[0099] When the output directory structure type is Type II, the output directory includes an initial homepage HTML file, fragmented list HTML files, and various first-level entry subdirectories. The number of first-level entry subdirectories is preset, and each first-level entry subdirectory stores the initial fragmented entry HTML files included in the initial fragmented entry HTML file set. Specifically, as follows... Figure 3 As shown, Figure 3 This is a schematic diagram of the structure of a second type of output directory provided in this specification. Figure 3 The output directory shown includes first-level entry subdirectories 1~N, a homepage HTML file, and fragmented list HTML files. Each first-level entry subdirectory 1~N contains multiple fragmented entry HTML files. Figure 3 The fragmented entries in the HTML file are 1~M. It should be noted that... Figure 3 For example, a subdirectory 1 containing fragmented HTML files (1-M) is a first-level entry. Figure 3 Files within the dashed box belong to the same level, meaning they are stored in the same directory (or subdirectory).
[0100] When the output directory structure is of type three, the output directory includes an initial homepage HTML file, fragmented list HTML files, and first-level entry subdirectories. Each first-level entry subdirectory contains several second-level subdirectories, the number of which is preset. Each second-level subdirectory stores the initial fragmented entry HTML files included in the initial fragmented entry HTML file set. Specifically... Figure 4 As shown, Figure 4 This is a schematic diagram of the structure of a third type of output directory provided in this specification. Figure 4 The output directory shown includes first-level item subdirectories, a homepage HTML file, and fragmented list HTML files. The first-level item subdirectories contain multiple second-level subdirectories, namely... Figure 4 The second-level subdirectories 1~S contain multiple fragmented HTML files, i.e. Figure 4 The fragmented entries in the HTML file are 1~M. It should be noted that... Figure 4 For example, the second-level subdirectory 1 contains fragmented HTML files ranging from 1 to 1M. Figure 4 Files within the dashed box belong to the same level, meaning they are stored in the same directory (or subdirectory).
[0101] The number of first-level subdirectories in the second type of output directory is the same as the number of second-level subdirectories in the third type of output directory. This number can be 100, or other values; this specification does not specify a particular value. It should be noted that the above... Figures 2-4 This example only considers the output directory as including the homepage HTML file, the fragmented list HTML file, and each fragmented entry HTML file in the set of fragmented entry HTML files. Of course, the HTML files included in the above output directory can also be the initial homepage HTML file, the fragmented list HTML file, and each initial fragmented entry HTML file in the set of initial fragmented entry HTML files. This specification does not make any specific limitations.
[0102] In addition, by storing each fragmented entry HTML file (or the initial fragmented entry HTML file) in different first-level entry subdirectories, the web server can first determine the directory to which the required fragmented entry HTML file (or the initial fragmented entry HTML file) belongs, i.e., the first-level entry subdirectory or the second-level subdirectory, and then search in the determined directory, thereby improving the search speed.
[0103] Based on this, taking the initial static HTML file set (i.e., the initial homepage HTML file, the fragmented list HTML file, and the initial fragmented entry HTML file set including each initial fragmented entry HTML file) as an example, when storing each initial fragmented entry HTML file in the initial fragmented entry HTML file set in S3 above, the number of generated initial fragmented entry HTML files can be determined when the structure type of the output directory is type two or type three, and this number is used as the entry count. According to the generation order of each initial fragmented entry HTML file, each initial fragmented entry HTML file is divided into file groups, and the number of initial fragmented entry HTML files included in each file group does not exceed the preset threshold number of overview page entries. Based on the structure type of the output directory, the storage directory is determined, a group identifier corresponding to each file group is set, and based on the entry count, the threshold number of overview page entries, and the group identifier corresponding to each file group, the target storage directory corresponding to each initial fragmented entry HTML file is determined from the storage directory, and each initial fragmented entry HTML file is stored in its corresponding target storage directory.
[0104] The process of dividing the initial fragmented HTML files into file groups according to their generation order is actually achieved by first dividing the initial fragmented HTML files (within a preset threshold number of overview page entries) into a data group according to their generation order, and continuing this process until all initial fragmented HTML files have been divided, resulting in file groups. Alternatively, it can be done until the number of remaining initial fragmented HTML files is less than the preset threshold number of overview page entries, at which point the remaining initial fragmented HTML files are also divided into file groups. The group identifier for each file group is set according to the order in which the file groups are divided. This order indicates the sequence in which the file groups are divided, with the publication time of each initial fragmented HTML file in an earlier divided file group being greater than the publication time of each initial fragmented HTML file in a later divided file group. The group identifier for each file group can be set to a natural number starting from 1; the earlier the file group is divided, the smaller the corresponding group identifier, and vice versa. When the output directory structure type is type two, the directory to be stored is each first-level entry subdirectory. When the output directory structure type is type three, the directory to be stored is each second-level subdirectory.
[0105] When determining the target storage directory for each initial fragmented entry HTML file from the directory to be stored, based on the number of entries, the threshold number of overview page entries, and the group identifier corresponding to each file group, the product of the group identifier corresponding to that file group and the threshold number of overview page entries can be determined first for each file group, and this product is used as the first result. The difference between the number of entries and the first result is then determined and used as the second result. Specifically, this can be achieved using the following formula:
[0106]
[0107] in, The group identifier is indicated by 'b', which represents the threshold number of items on the overview page. Indicates the number of entries. Indicates the first result. This indicates the second result.
[0108] Next, the second result is modulo the number of directories to be stored included in the output directory. The remainder obtained by dividing the second result by the number of directories to be stored in the output directory is used as the first target identifier. Each directory to be stored in the output directory has a corresponding directory identifier. Therefore, the directory with the first target identifier among all the directories to be stored in the output directory can be used as the target storage directory corresponding to the initial fragmented entry HTML file with the largest publication time in the file group. The remaining initial fragmented entry HTML files in the file group are sorted in descending order of publication time to obtain the remaining file sequence. For each initial fragmented entry HTML file in the remaining file sequence, its position identifier is determined. The difference between the second result and the position identifier is used as the third result, which can be implemented using the following formula:
[0109]
[0110]
[0111] in, The group identifier is indicated by 'b', which represents the threshold number of items on the overview page. Indicates the number of entries. Indicates the first result. This indicates the second result. Indicates location identifier, This indicates the third result.
[0112] Next, the third result is moduloed by the number of directories to be stored included in the output directory. The modulo result is used as the second target identifier. Among all the directories to be stored included in the output directory, the directory with the second target identifier is used as the target storage directory corresponding to the initial fragmented entry HTML file. The above position identifier is used to characterize the position of the initial fragmented entry HTML file in the remaining file sequence. That is, when it is the first position in the remaining file sequence, the position identifier is 1; when it is the second position in the remaining file sequence, the position identifier is 2; the determination method for the position identifier corresponding to other positions in the remaining file sequence is the same as the above determination method, and will not be repeated here.
[0113] In addition, when the structure type of the output directory is the first type, each initial fragmented entry HTML file in the initial fragmented entry HTML file set can be directly stored in the output directory.
[0114] Based on this, when searching for the initial fragmented entry HTML files included in the overview page, if the output directory structure type is the second type or the third type, the page number of the page accessed by the user can be determined according to the page information in the access instruction. The query directory is determined based on the output directory structure type. Based on the total number of documents included in the target category, the page number, and the preset threshold number of overview page entries, the target query directory corresponding to the initial fragmented entry HTML files included in the overview page is determined within the query directory. The initial fragmented entry HTML files included in the overview page are then searched within the target query directory.
[0115] Specifically, when the output directory structure type is Type II, the query directory consists of each first-level entry subdirectory. When the output directory structure type is Type III, the query directory consists of each second-level subdirectory. When determining the target query directory corresponding to the initial fragmented entry HTML file included in the overview page within the query directory based on the total number of documents included in the target category, page numbers, and the preset threshold number of overview page entries, the product of the page number and the threshold number of overview page entries can be used as the first product. The difference between the total number of documents included in the target category and the product result can be used as the first difference. The first difference is modulo the number of query directories included in the output directory; that is, the remainder obtained by dividing the first difference by the number of query directories included in the output directory is used as the first identifier. Each query directory included in the output directory has a corresponding directory identifier. Therefore, the query directory with the first identifier among all query directories included in the output directory can be used as the target query directory corresponding to the initial fragmented entry HTML file included in the overview page.
[0116] However, the aforementioned overview page may include multiple entries. The number of entries included in the overview page shall not exceed the threshold number of overview page entries. The specific number of entries can be determined based on the page number. If the page number corresponding to the overview page is not the maximum page number, then the number of entries included in the overview page is the threshold number of overview page entries. If the page number corresponding to the overview page is the maximum page number, it is necessary to determine whether the total number of documents included in the target category is divisible by the threshold number of overview page entries. If it is divisible, then the maximum page number is the result of dividing the total number of documents included in the target category by the result of dividing the threshold number of overview page entries, and the number of entries included in the overview page is the threshold number of overview page entries. If it is not divisible, then the maximum page number is the integer part of the result of dividing the total number of documents included in the target category by the result of dividing the threshold number of overview page entries plus one, and the number of entries included in the overview page is the remainder obtained by dividing the total number of documents included in the target category by the result of dividing the threshold number of overview page entries.
[0117] Therefore, the directory identified by the first identifier is actually the target query directory corresponding to the initial fragmented entry HTML file of the first entry included in the overview page. The first entry is the entry corresponding to the document with the highest publication time among the entries included in the overview page. Since the overview page may include other entries besides the first entry, it is necessary to further determine the target query directories for the initial fragmented entry HTML files corresponding to these other entries. Therefore, the difference between the first difference and a specified value can be determined and used as the second difference. The second difference is then moduloed by the number of directories to be queried included in the output directory (i.e., the remainder obtained by dividing the second difference by the number of directories to be queried included in the output directory). The modulo result is used as the second identifier. Among all the directories to be queried included in the output directory, the directory identified by the second identifier is used as the target query directory corresponding to the initial fragmented entry HTML file of the other entries. It is then determined whether the number of target query directories for the currently determined initial fragmented entry HTML files reaches the number of entries included in the overview page. If it does, then all the determined target query directories for the initial fragmented entry HTML files are used as the target query directories corresponding to the initial fragmented entry HTML files included in the overview page. If the target value is not reached, the specified value is incremented by one and used as the new specified value. The difference between the first difference and the specified value (i.e., the result of incrementing the previously used specified value) is used as the second difference. The second difference is moduloed by the number of directories to be queried included in the output directory. The remainder obtained by dividing the second difference by the number of directories to be queried included in the output directory is used as the second identifier. The directories identified by the second identifier among all directories to be queried included in the output directory are used as the target query directories for the initial fragmented entry HTML files corresponding to other entries. This process continues until the number of target query directories for the currently determined initial fragmented entry HTML files reaches the number of entries included in the overview page. The specified value used each time the target query directory for the initial fragmented entry HTML files corresponding to other entries is determined is the previously used specified value plus one.
[0118] When searching for the initial fragmented entry HTML files included in the overview page in the target query directory, the product of the page number and the preset threshold number of overview page entries can be determined. The difference between the total number of documents included in the target column and the product can be determined. This difference is used as the start identifier. The sum of the start identifier and the preset threshold number of overview page entries is determined as the end identifier. From each initial fragmented entry HTML file in the target query directory, the initial fragmented entry HTML file whose file identifier is greater than the start identifier and not greater than the end identifier is determined and used as the initial fragmented entry HTML file included in the overview page, i.e., the found initial fragmented entry HTML file.
[0119] If the overview page includes multiple entries, then there are multiple target query directories. That is, each entry's corresponding initial fragmented entry HTML file has a corresponding target query directory. Therefore, it is necessary to search for the initial fragmented entry HTML file included in the overview page in each target query directory. The specific process is similar to the search process described above, so it will not be repeated here.
[0120] Additionally, when the output directory structure type is Type 1, the page number of the page accessed by the user can be determined based on the page information in the access instruction. The directory to be queried is determined according to the output directory structure type. Specifically, when the output directory structure type is Type 1, the directory to be queried is the output directory. Therefore, the initial fragmented entry HTML files included in the overview page can be directly searched in the output directory based on the total number of documents included in the target category, the page number, and the preset threshold number of overview page entries. The specific implementation process of searching for the initial fragmented entry HTML files included in the overview page in the output directory is similar to the specific implementation process of searching for the initial fragmented entry HTML files included in the overview page in the target query directory, and will not be repeated here.
[0121] In some embodiments of this specification, when the fragmented entry HTML file or the initial fragmented entry HTML file is stored hierarchically in different first-level entry subdirectories or second-level subdirectories in the output directory, and the content of the overview interface in the target column changes to adding a new document or deleting an existing document, in addition to modifying the home page HTML file (or the initial home page HTML file), adding the fragmented entry HTML file (or the initial fragmented entry HTML file) corresponding to the new document, or deleting the fragmented entry HTML file (or the initial fragmented entry HTML file) corresponding to the document to be deleted, it is also necessary to adjust the storage location of the fragmented entry HTML file or the initial fragmented entry HTML file corresponding to other documents.
[0122] Specifically, taking the example of storing the initial fragmented entry HTML files hierarchically in different second-level subdirectories of the output directory, when the content of the overview interface in the target column changes to adding a new document to the target column and having obtained the updated homepage HTML file and the corresponding fragmented entry HTML files for the document data, the publishing engine or web server can be used. Taking the publishing engine as an example, the publishing engine can determine all the current initial fragmented entry HTML files, redetermine the initial fragmented entry HTML file set composed of all the current initial fragmented entry HTML files, and restore the new initial fragmented entry HTML file set to each second-level subdirectory in the output directory, and then republish it to the web server. The specific implementation process of re-storing the new initial fragmented entry HTML file set to each second-level subdirectory in the output directory is similar to the process in S3 of storing each initial fragmented entry HTML file in the initial fragmented entry HTML file set when the first-level entry subdirectory in the output directory includes each second-level subdirectory, and will not be elaborated further here.
[0123] Similarly, when the content of the overview interface in the target section changes to the deletion of a document in the target section and an updated homepage HTML file has been obtained, the publishing engine or web server mentioned above can be used. Taking the publishing engine as an example, the file identifier corresponding to the initial fragmented entry HTML file of the deleted document can be determined by the publishing engine and used as a partition identifier. Initial fragmented entry HTML files with file identifiers smaller than the partition identifier can be identified and used as the initial fragmented entry HTML files to be adjusted. The positions of the initial fragmented entry HTML files to be adjusted in the various second-level subdirectories of the output directory can be adjusted, and then the file can be republished to the web server. Specifically, when adjusting the positions of the initial fragmented entry HTML files to be adjusted in the various second-level subdirectories of the output directory, the storage subdirectories of the initial fragmented entry HTML files to be adjusted in the various second-level subdirectories of the output directory can be determined, and the positions of the initial fragmented entry HTML files to be adjusted in the various second-level subdirectories of the output directory can be adjusted based on the determined storage subdirectories. The specific implementation process of determining the storage subdirectories of the initial fragmented entry HTML files to be adjusted in each second-level subdirectory of the output directory is similar to the process of storing each initial fragmented entry HTML file in the set of initial fragmented entry HTML files in S3 when the first-level entry subdirectory of the output directory includes each second-level subdirectory, and will not be repeated here.
[0124] In some embodiments of this specification, when determining the page accessed by a user based on a user access instruction, the access path corresponding to the page accessed by the user can be determined based on the page information in the access instruction. The overview page rewriting module in the web server determines whether the access path includes a specified identifier. If yes, the page accessed by the user is determined to be an overview page. If not, the page accessed by the user is determined not to be an overview page. The page information mentioned above may include the access path in addition to the page number, and the specified identifier is preset.
[0125] The above description is merely an embodiment of this specification and is not intended to limit this specification. Various modifications and variations can be made to this specification by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this specification should be included within the scope of the claims of this specification.
Claims
1. A static publishing method based on a CMS system that does not limit the number of documents published in a category, characterized in that, The method includes: S1: Web server configuration: Upload the configuration script to the web server and run it to configure the web server; S2: Preset target column file storage structure: Generate a static HTML file collection for all overview interfaces in the target column and store it. The static HTML file collection includes: home page HTML file, fragmented list HTML file, and fragmented item HTML file collection. The home page HTML file is nested in the fragmented list HTML file, and the fragmented list HTML file is nested in the files in the fragmented item HTML file collection. S3: Generate and publish the initial static HTML file set corresponding to the target column: Based on the publishing template and overview interface content corresponding to the target column, generate the initial static HTML file set corresponding to the target column through the preset target column file storage structure in the publishing engine of the CMS system and store it in the output directory; publish the output directory to the WEB server; S4: HTML file update and republishing: When the content of the overview interface in the target column changes, the publishing engine determines whether the initial homepage HTML file, fragmented list HTML file, and initial fragmented entry HTML file set in the output directory have changed. If the HTML files have changed, they are updated and republished to the WEB server.
2. The static publishing method based on a CMS system that does not limit the number of documents published in a column, as described in claim 1, is characterized in that... The structure type of the output directory is one of the first type, the second type, and the third type; When the structure type of the output directory is the first type, the output directory includes the initial homepage HTML file, the fragmented list HTML file, and each initial fragmented entry HTML file included in the initial fragmented entry HTML file set; When the structure type of the output directory is the second type, the output directory includes the initial homepage HTML file, the fragmented list HTML file, and each first-level entry subdirectory. The number of the first-level entry subdirectories is preset, and each first-level entry subdirectory is used to store each initial fragmented entry HTML file included in the initial fragmented entry HTML file set. When the structure type of the output directory is the third type, the output directory includes the initial homepage HTML file, the fragmented list HTML file, and a first-level entry subdirectory. The first-level entry subdirectory includes various second-level subdirectories. The number of second-level subdirectories is preset. Each second-level subdirectory is used to store the initial fragmented entry HTML files included in the initial fragmented entry HTML file set.
3. The static publishing method based on a CMS system that does not limit the number of documents published in a column, as described in claim 2, is characterized in that... The method for storing each initial fragmented entry HTML file in the initial fragmented entry HTML file set in S3 is as follows: When the structure type of the output directory is the second type or the third type, determine the number of initial fragmented entry HTML files generated and use them as the number of entries; According to the generation order of each initial fragmented entry HTML file, each initial fragmented entry HTML file is divided into a file group, and the number of initial fragmented entry HTML files included in each file group is no greater than the preset threshold number of overview page entries. Based on the structure type of the output directory, the directory to be stored is determined; wherein, when the structure type of the output directory is the second type, the directory to be stored is each of the first-level entry subdirectories; when the structure type of the output directory is the third type, the directory to be stored is each of the second-level subdirectories; Set a group identifier for each file group, and determine the target storage directory corresponding to each initial fragmented entry HTML file from the storage directory based on the number of entries, the threshold number of entries on the overview page, and the group identifier for each file group. Each initial fragmented entry HTML file is stored in the target storage directory corresponding to each initial fragmented entry HTML file.
4. The static publishing method based on a CMS system that does not limit the number of documents published in a column, as described in claim 2, is characterized in that... The method further includes: Upon receiving a user access instruction, determine the page the user accesses based on the user access instruction; When the page is an overview page of the target category, the entry lookup module in the WEB server searches for the initial fragmented entry HTML file included in the overview page in the output directory based on the page information in the access instruction and the preset threshold number of overview page entries. The SSI module in the web server assembles the initial homepage HTML file, the fragmented list HTML file, and the found initial fragmented entry HTML file to obtain the overview page, which is then returned.
5. The static publishing method based on a CMS system that does not limit the number of documents published in a column, as described in claim 4, is characterized in that... The method for locating the initial fragmented entry HTML files included in the overview page is as follows: When the structure type of the output directory is the second type or the third type, the page number of the page accessed by the user is determined according to the page information in the access instruction; Based on the structure type of the output directory, the directory to be queried is determined; wherein, when the structure type of the output directory is the second type, the directory to be queried is each of the first-level entry subdirectories; when the structure type of the output directory is the third type, the directory to be queried is each of the second-level subdirectories; Based on the total number of documents included in the target column, the page number, and the preset threshold number of overview page entries, the target query directory corresponding to the initial fragmented entry HTML file included in the overview page is determined in the query directory; In the target query directory, locate the initial fragmented entry HTML file included in the overview page.
6. The static publishing method based on a CMS system that does not limit the number of documents published in a column, as described in claim 1, is characterized in that... In step S4, determining whether the initial homepage HTML file, fragmented list HTML file, and initial fragmented item HTML file set in the output directory have changed through the publishing engine specifically includes: When the content of the overview interface in the target section changes to the addition of a new document to the target section, the initial homepage HTML file in the output directory is determined to be the HTML file that has changed. When the content of the overview interface in the target section changes to the deletion of documents in the target section, the initial homepage HTML file in the output directory is determined to be the HTML file that has changed. When the content of the overview interface in the target section changes to modify the document in the target section, the initial fragmented entry HTML file corresponding to the modified document in the output directory is determined to be the changed HTML file.
7. A static publishing method based on a CMS system that does not limit the number of documents published in a column, as described in claim 1, characterized in that... The modified HTML file is the initial homepage HTML file in the output directory; The process of updating and republishing the changed HTML file to the web server in step S4 specifically includes: When the content of the overview interface in the target section changes to adding a new document to the target section, the document data corresponding to the newly added document is obtained, and the number of newly added documents is determined based on the document data. The publishing engine updates the total number of documents in the initial homepage HTML file based on the document count. Based on the document title and publication time in the document data, generate a fragmented entry HTML file corresponding to the document data; The updated homepage HTML file and the fragmented entry HTML files corresponding to the document data are republished to the web server.
8. A static publishing method based on a CMS system that does not limit the number of documents published in a column, as described in claim 1, characterized in that... The modified HTML file is the initial homepage HTML file in the output directory; The process of updating and republishing the changed HTML file to the web server in step S3 specifically includes: When the content of the overview interface in the target column changes to deleting a document in the target column, the document data corresponding to the deleted document is obtained, and the number of deleted documents is determined based on the document data. The publishing engine updates the total number of documents in the initial homepage HTML file based on the document count. Generate a deletion instruction corresponding to the deleted document, the deletion instruction being used to instruct the web server to delete the fragmented entry HTML file corresponding to the deleted document; The updated homepage HTML file is republished to the web server, and the deletion command is sent to the web server.
9. A static publishing method based on a CMS system that does not limit the number of documents published in a column, as described in claim 1, characterized in that... The changed HTML file is the initial fragmented entry HTML file corresponding to the modified document in the output directory; The process of updating and republishing the changed HTML file to the web server in step S3 specifically includes: When the content of the overview interface in the target section changes to modify a document in the target section, the modification information corresponding to the modified document is determined; the modification information includes at least one of the document title and publication time; The publishing engine updates the document information in the initial fragmented entry HTML file corresponding to the modified document based on the modification information; The updated fragmented entry HTML file corresponding to the modified document is republished to the web server.
10. A static publishing method based on a CMS system that does not limit the number of documents published in a column, as described in claim 1, characterized in that... S1 specifically includes: Obtain the configuration script of the web server, wherein the configuration script includes at least SSI configuration instructions, overview page rewrite configuration instructions, and item lookup configuration instructions; The configuration script is uploaded to the web server and run on the web server to configure the web server; the web server is configured with at least an SSI module, an overview page rewrite module, and an item search module.
11. A static publishing method based on a CMS system that does not limit the number of documents published in a column, as described in claim 4, characterized in that... Based on the user access instruction, the page accessed by the user is determined, specifically including: Based on the page information in the access instruction, determine the access path corresponding to the page accessed by the user; The overview page rewriting module in the web server determines whether the access path includes a specified identifier. If so, determine that the page accessed by the user is an overview page; If not, it is determined that the page accessed by the user is not an overview page.