Tourism product page lightweight operation method, system and equipment and storage medium

By analyzing and converting font information on the OTA platform and generating copywriting node addresses, the problem of slow page loading caused by loading large font files is solved, the mobile web page experience is improved, and the page loading speed is achieved faster.

CN118964762APending Publication Date: 2024-11-15CTRIP TRAVEL NETWORK TECH SHANGHAI0
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202410924839.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-10
Publication Date
2024-11-15

AI Technical Summary

Technical Problem

When loading hotel advertising pictures, the existing online travel agency (OTA) platform uses large copyright font files, which leads to the page loading too slowly, especially on mobile, and the small font package cannot be packaged separately for fixed text, which cannot be effective. Solve the problem of excessive font files.

Method used

By uploading layer file packages to the server, parsing and converting font information, generating copywriting node addresses, establishing mapping relationships, avoiding loading of complete font packages, only loading necessary font information, and optimizing page generation and loading.

Benefits of technology

It reduces the traffic consumption of page loading, improves the fluency of mobile web page experience, avoids the burden on the page by oversized font files, and provides faster page refresh speed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118964762A_ABST
    Figure CN118964762A_ABST
Patent Text Reader

Abstract

The invention provides a tourism product page lightweight operation method, system and device and a storage medium, and the method comprises the steps: uploading a layer file package to a server side, the layer file package comprising a picture layer group and a text layer group; analyzing the layer file package, and converting the first font information of the copywriting layer into corresponding second font information pre-stored in a server side; when the second font information in the at least one copywriting layer does not belong to the preset common font set, taking the copywriting layer which does not belong to the preset common font set as a target copywriting layer, generating a copywriting node address for each target copywriting layer, and storing copywriting information generated based on the second font information and the tourism product name in the copywriting node address; and when the user side refreshes to the tourism product page, generating the tourism product page based on the picture layer group and the text layer group. According to the method and the device, the font file with overlarge volume can be prevented from being loaded, so that the page experience is smoother, and the webpage experience of the mobile terminal is optimized.
Need to check novelty before this filing date? Find Prior Art

Description

Background Art

[0002] OTA stands for Online Travel Agency, which is translated into Chinese as "online travel agency", which is a general term for online hotel, travel ticketing and other reservation system platforms. At present, online hotel industry platforms are mainly divided into three camps. OTA refers to online travel agencies, which are actually a type of B2B2C, that is, online travel agency platforms directly sell resources on behalf of tourism resource providers and collect sales commissions. Tourism platforms are not only online agency resources, but also part of the platform. They are all sold on the platform. The emergence of OTA will replace traditional travel agency sales. The model is placed on the network platform, and the transmission and interaction of route information are more extensive.

[0003] In the sales of tourism products, pictures and text introductions are very important. Take hotels as an example. At present, the hotel background picture and the hotel name logo are usually pre-stored. When the user browses the hotel page, the hotel advertising picture is generated based on the combination of the background picture and the hotel name logo.

[0004] However, for the sake of aesthetics and personalized design, the hotel name logo usually uses some special copyright fonts. Such copyright fonts are relatively large, ranging from a few MB to dozens of MB. Although these special copyright fonts can make the advertisement more eye-catching and attractive in graphics, the advertisement images are generated dynamically through dynamic HTML graphics and FreeMarker. This requires the user's mobile phone to refresh the corresponding fonts, and it needs to download the complete font package, which requires a lot of traffic. If the font package is particularly large, it will have an impact on the web page loading.

[0005] At present, the common solution to solve the problem of TTF fonts being too large is to convert them to woff2. After converting to woff2, the fonts are partially compressed, but the large fonts are still that large. Since the text in the advertising image may not be fixed, it is also impossible to package a few words into a small font package separately.

[0006] Therefore, the present invention provides a lightweight operation method, system, device and storage medium for a tourism product page. Summary of the invention

[0007] In response to the problems in the prior art, the purpose of the present invention is to provide a lightweight operation method, system, device and storage medium for tourism product pages, which overcomes the difficulties of the prior art, can avoid loading font files that are too large, make the page experience smoother, and optimize the web page experience on mobile terminals.

[0008] An embodiment of the present invention provides a lightweight operation method for a tourism product page, comprising the following steps:

[0009] S110, uploading a layer file package for generating a tourism product page to a server, wherein the layer file package includes at least one picture layer group and at least one text layer group, wherein the picture layer group includes at least one tourism product picture layer, and the text layer group includes at least one text layer of a tourism product name having first font information;

[0010] S120, parsing the layer file package, and converting the first font information of the text layer into corresponding second font information pre-stored in the server based on a preset server font mapping table;

[0011] S130, when the second font information in at least one of the text layers does not belong to the preset common font set, the text layer that does not belong to the preset common font set is used as the target text layer, and then step S140 is executed;

[0012] S140, generating a copy node address for each target copy layer, wherein the copy node address stores copy information generated based on at least the second font information of the target copy layer and the name of the tourism product, and establishing a mapping relationship between the target copy layer and the copy node address; and

[0013] S150. When the user terminal refreshes to the travel product page, a travel product page is generated based on the image layer group and the text layer group having the text node address.

[0014] Preferably, in step S110, the tourism product page is a hotel product, the tourism product name is a hotel name, the layer file package is a PSD file, and the text layer includes the tourism product name with first font information, a preset color and a preset rendering effect, and the first font information is an adobe font name.

[0015] Preferably, the step S120 includes:

[0016] S121, parsing the layer file package by using an OpenType tool to obtain the image layer and the text layer;

[0017] S122: Based on a preset server font mapping table, convert the first font information of the text layer of the PSD file into corresponding second font information pre-stored in the server.

[0018] Preferably, the step S130 includes:

[0019] Traverse the text layer to determine whether all the second font information in the text layer belongs to the preset common font set. If so, end; if not, take the text layer that does not belong to the preset common font set as the target text layer, and execute step S140.

[0020] Preferably, the step S140 includes:

[0021] S141, generating a copy node address for each target copy layer, wherein the copy node address stores copy information generated based on at least the second font information and the name of the tourism product;

[0022] S142: Establish a mapping relationship between the target copywriting layer and the copywriting node address, and replace the target copywriting layer with the copywriting node address.

[0023] Preferably, the step S150 includes:

[0024] S151, when the user terminal refreshes to the travel product page, the copywriting node address is called;

[0025] S152: Based on the stacking relationship between the image layer group and the text layer group having the text node address, jointly generate a travel product page and send it to the user end.

[0026] Preferably, the step S152 includes:

[0027] S1521, matching the keywords extracted from the historical travel information of the user terminal with the optional picture layers in the picture layer group, and obtaining the optional picture layer with the highest matching degree as the target layer;

[0028] S1522. Based on the stacking relationship between the target layer and the text layer group having the text node address, a travel product page is jointly generated and sent to the user end.

[0029] The embodiment of the present invention further provides a tourism product page lightweight operation system, which is used to implement the above-mentioned tourism product page lightweight operation method, and the tourism product page lightweight operation system includes:

[0030] A layer file module uploads a layer file package for generating a tourism product page to a server, wherein the layer file package includes at least one picture layer group and at least one text layer group, wherein the picture layer group includes at least one tourism product picture layer, and the text layer group includes at least one text layer of the tourism product name having first font information;

[0031] A layer parsing module parses the layer file package and converts the first font information of the text layer into corresponding second font information pre-stored in the server based on a preset server font mapping table;

[0032] a font conversion module, when the second font information in at least one of the text layers does not belong to the preset common font set, taking the text layer that does not belong to the preset common font set as the target text layer, and executing the mapping establishment module;

[0033] A mapping establishment module generates a copy node address for each target copy layer, wherein the copy node address stores copy information generated based on at least the second font information of the target copy layer and the name of the tourism product, and establishes a mapping relationship between the target copy layer and the copy node address; and

[0034] The page generation module generates a travel product page based on the image layer group and the text layer group having the text node address when the user terminal refreshes to the travel product page.

[0035] The embodiment of the present invention also provides a lightweight operation device for a tourism product page, including:

[0036] processor;

[0037] a memory storing executable instructions of the processor;

[0038] Wherein, the processor is configured to execute the steps of the above-mentioned tourism product page lightweight operation method by executing the executable instructions.

[0039] An embodiment of the present invention further provides a computer-readable storage medium for storing a program, which, when executed, implements the steps of the above-mentioned tourism product page lightweight operation method.

[0040] The purpose of the present invention is to provide a lightweight operation method, system, device and storage medium for a tourism product page, which can avoid loading font files that are too large, make the page experience smoother, and optimize the web page experience on the mobile terminal. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] Other features, objectives and advantages of the present invention will become more apparent from a reading of the detailed description of non-limiting embodiments made with reference to the following accompanying drawings.

[0042] Figure 1 It is a flow chart of the lightweight operation method of the tourism product page of the present invention.

[0043] Figure 2 It is a structural schematic diagram of the lightweight operation system of the tourism product page of the present invention.

[0044] Figure 3 It is a structural schematic diagram of the lightweight operation device of the tourism product page of the present invention.

[0045] Figure 4 It is a schematic diagram of the structure of a computer-readable storage medium according to an embodiment of the present invention. DETAILED DESCRIPTION

[0046] The following describes the implementation of the present application through specific examples, and those skilled in the art can easily understand other advantages and effects of the present application from the content disclosed in the present application. The present application can also be implemented or applied through other different specific implementations, and the details in the present application can also be modified or changed in various ways according to different viewpoints and application systems without departing from the spirit of the present application. It should be noted that the embodiments in the present application and the features in the embodiments can be combined with each other without conflict.

[0047] The following is a detailed description of the embodiments of the present application with reference to the accompanying drawings so that those skilled in the art can easily implement the present application. The present application can be embodied in a variety of different forms and is not limited to the embodiments described herein.

[0048] In the representations of the present application, the representations with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" etc. mean that the specific features, structures, materials or characteristics represented in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. Moreover, the represented specific features, structures, materials or characteristics may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples represented in the present application and the features of the different embodiments or examples, unless they contradict each other.

[0049] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the representation of this application, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.

[0050] In order to clearly describe the present application, components irrelevant to the description are omitted, and the same reference symbols are given to the same or similar components throughout the specification.

[0051] Throughout the specification, when a device is said to be "connected" to another device, this includes not only the case of "direct connection" but also the case of "indirect connection" by placing other elements therebetween. In addition, when a device is said to "include" a certain component, unless otherwise stated, it does not exclude other components, but means that other components may be included.

[0052] When a device is said to be "on" another device, it may be directly on the other device, but there may also be other devices between it. In contrast, when a device is said to be "directly" on another device, there are no other devices between it.

[0053] Although the terms first, second, etc. are used to represent various elements in some examples, these elements should not be limited by these terms. These terms are only used to distinguish one element from another element. For example, the first interface and the second interface, etc. are represented. Moreover, as used in this article, the singular forms "one", "one" and "the" are intended to also include plural forms, unless there is an opposite indication in the context. It should be further understood that the terms "comprising" and "including" indicate the existence of features, steps, operations, elements, components, projects, kinds, and / or groups, but do not exclude the existence, occurrence or addition of one or more other features, steps, operations, elements, components, projects, kinds, and / or groups. The terms "or" and "and / or" used herein are interpreted as inclusive, or mean any one or any combination. Therefore, "A, B or C" or "A, B and / or C" means "any of the following: A; B; C; A and B; A and C; B and C; A, B and C". Only when the combination of elements, functions, steps or operations is inherently mutually exclusive in some way, will there be an exception to this definition.

[0054] The technical terms used herein are only used to refer to specific embodiments and are not intended to limit the present application. The singular form used herein also includes the plural form unless the sentence clearly indicates the contrary meaning. The meaning of "including" used in the specification is to specify specific characteristics, regions, integers, steps, operations, elements and / or components, and does not exclude the existence or addition of other characteristics, regions, integers, steps, operations, elements and / or components.

[0055] Although not defined differently, all terms, including technical and scientific terms used herein, have the same meaning as those generally understood by those skilled in the art to which this application belongs. Terms defined in commonly used dictionaries are additionally interpreted as having meanings consistent with the relevant technical literature and the contents of the current disclosure, and unless defined, shall not be overly interpreted as ideal or very formal meanings.

[0056] Figure 1Flowchart of the lightweight operation method of the tourism product page of the present invention. Figure 1 As shown, the lightweight operation method of the tourism product page of the present invention includes:

[0057] S110, uploading a layer file package for generating a tourism product page to a server, wherein the layer file package includes at least one image layer group and at least one text layer group, wherein the image layer group includes at least one tourism product image layer, and the text layer group includes at least one text layer of a tourism product name having first font information.

[0058] S120: Parse the layer file package, and convert the first font information of the text layer into corresponding second font information pre-stored in the server based on a preset server font mapping table.

[0059] S130. When the second font information in at least one text layer does not belong to the preset common font set, the text layer that does not belong to the preset common font set is taken as the target text layer, and step S140 is executed.

[0060] S140, generating a copy node address (CND node address) for each target copy layer, storing the copy node address at least based on the second font information of the target copy layer and the copy information generated by the name of the tourism product, and establishing a mapping relationship between the target copy layer and the copy node address. And S150, when the user terminal refreshes to the tourism product page, the tourism product page is jointly generated based on the image layer group and the text layer group with the copy node address.

[0061] In a preferred embodiment, in step S110, the tourism product page is a hotel product, the tourism product name is the hotel name, the layer file package is a PSD file, the copy layer includes the tourism product name with first font information, a preset color and a preset rendering effect, and the first font information is an adobe font name. Among them, the PSD file can be stored in RGB or CMYK mode, and the number of colors can be customized and stored. It can also save Photoshop's layer, channel, path and other information. It is the only format that can support all image color modes, but is not limited to this.

[0062] In a preferred embodiment, step S120 includes:

[0063] S121. Use the OpenType tool to parse the layer file package to obtain the image layer and the text layer. OpenType, also known as Type 2 font, is another font format developed by Microsoft and Adobe. It is also an outline font, more powerful than TrueType. The most obvious advantage is that PostScript fonts can be embedded in TrueType software. It also supports multiple platforms, a large character set, and copyright protection.

[0064] S122. Based on a preset server font mapping table, convert the first font information of the text layer of the PSD file into corresponding second font information pre-stored on the server side, thereby unifying the differences in naming various fonts in different systems, but not limited to this.

[0065] In a preferred embodiment, step S130 includes:

[0066] Traverse the text layer to determine whether all the second font information in the text layer belongs to the preset common font set, if yes, then end. If not, take the text layer that does not belong to the preset common font set as the target text layer, and execute step S140, but not limited thereto.

[0067] In a preferred embodiment, step S140 includes:

[0068] S141. Generate a copy node address for each target copy layer, in which copy node address is stored copy information (eg, a field composed of several tiff fonts) generated at least based on the second font information and the name of the tourism product.

[0069] S142. Establish a mapping relationship between the target text layer and the text node address, replace the target text layer with the text node address (a font CDN address), and keep the layer stacking order (with the stacking order of other layers) of the layer where the replaced text node address is located in the PSD file unchanged, but not limited to this.

[0070] In a preferred embodiment, step S150 includes:

[0071] S151. When the user terminal refreshes to the travel product page, the copywriting node address is called.

[0072] S152. Based on the stacking relationship between the image layer group and the text layer group with the text node address, a travel product page is jointly generated and sent to the user end, but not limited to this.

[0073] In a preferred embodiment, step S152 includes:

[0074] S1521. Matching the keywords extracted from the historical travel information of the user terminal with the optional picture layers in the picture layer group, obtaining the optional picture layer with the highest matching degree as the target layer.

[0075] S1522. Based on the stacking relationship between the target layer and the text layer group with the copy node address, a travel product page is jointly generated and sent to the user end, but not limited to this.

[0076] Specific embodiments of the present invention include:

[0077] First, upload a layer file package for generating a tourism product page to the server side, the layer file package includes at least one picture layer group and at least one text layer group, the picture layer group includes at least one tourism product picture layer, the text layer group includes at least one text layer of the tourism product name with first font information, the tourism product page is a hotel product, the tourism product name is the hotel name, the layer file package is a PSD file, the text layer includes the tourism product name with first font information, preset color and preset rendering effect, and the first font information is the adobe font name. The layer file package is parsed by the OpenType tool to obtain the picture layer and the text layer. Based on the preset server font mapping table, the first font information of the text layer of the PSD file is converted into the corresponding second font information pre-stored in the server side. Traverse the text layer to determine whether the second font information in the text layer all belongs to the preset common font set, and if so, end. If not, the text layer that does not belong to the preset common font set is used as the target text layer, and a text node address is generated for each target text layer, and the text node address stores the text information generated based on at least the second font information and the tourism product name. Establish the mapping relationship between the target copywriting layer and the copywriting node address, and replace the target copywriting layer with the copywriting node address, but not limited thereto. Finally, when the user terminal refreshes to the tourist product page, the copywriting node address is called. Based on the keywords extracted according to the historical tourist information of the user terminal and the optional picture layer in the picture layer group, the optional picture layer with the highest matching degree is obtained as the target layer. Based on the stacking relationship of the target layer and the text layer group with the copywriting node address, the tourist product page is generated together and sent to the user terminal. After using the present invention, even if a variety of special fonts are included in the PSD file, due to having processed these copies into the copywriting node address respectively, the copywriting node address corresponds to the copywriting information generated based on the second font information and the tourist product name, then when the user refreshes the page, the user terminal (mobile phone or computer, etc.) no longer needs to install various font packages containing these special fonts, but only needs to receive the copywriting information corresponding to the copywriting node address from the server, which greatly reduces the flow and improves the refresh speed of the page.

[0078] The purpose of the present invention is to solve the problem of performance consumption caused by excessively large drawing fonts, solve the one-to-one mapping relationship between the font names of uploaded PSD files and the font names in the copyright font library, and solve the problem of updating the server drawing font library and the name mapping relationship.

[0079] In order to solve the problem that the font ttf font (TTF, TrueTypeFont is a font file format jointly launched by Apple and Microsoft. With the popularity of Windows, it has become the most commonly used font file representation method) is too large, the usual solution is to convert it to woff2. After converting to woff2, the font is partially compressed, but the large font is still that large. Since the text in the advertising picture may not be fixed, it is also impossible to package a few words into a small font package separately. The solution of the present invention is as follows:

[0080] Deploy a cloud function (nodejs service), the role of the service is to convert the incoming text and fonts into a woff2 file loaded on demand in real time. And upload this font file to the company's CDN server. Because real-time conversion will consume some time, the original mapping time will increase, and a job is also written to convert the dynamic data of advertising mapping in advance (macros, which can be understood as dynamic databases, such as hotel name macros, which will generate different names according to different hotels, and hotel picture macros, which will generate different hotel pictures according to different hotels). Each generated different copy corresponds to a font CDN address. (This font size may be only a few KB, and there is no problem with remote loading).

[0081] Among them, WOFF2 is a compressed font format designed for web pages, aiming to reduce the size of font files to increase the loading speed of web pages. WOFF2 is the second version of Web Open Font Format (WOFF). It inherits the compression and font source information characteristics of WOFF, but further optimizes the compression ratio to make the font file smaller. Due to its efficient compression technology, WOFF2 can help reduce web page loading time, thereby improving the response speed and user experience of web pages. At present, some mainstream browsers such as Chrome and Firefox support the WOFF2 format, which allows it to be correctly displayed and used in modern web browsers. The full name of CDN is Content Delivery Network. Its basic idea is to avoid bottlenecks and links on the Internet that may affect the speed and stability of data transmission as much as possible, so that content transmission is faster and more stable. By placing node servers everywhere in the network to form a layer of intelligent virtual network on the basis of the existing Internet, the CDN system can redirect user requests to the service node closest to the user in real time based on comprehensive information such as network traffic and the connection and load status of each node, as well as the distance to the user and the response time. Its purpose is to enable users to obtain the required content nearby, solve the problem of Internet congestion, and improve the response speed of users visiting the website.

[0082] In order to solve the problem of inconsistency between the font name of the advertising template file and the font name in the copyright font library (the reason for the inconsistency is that the font ttf name and the font name in adobe are resolved differently, and adobe uses OpenType), the advertising graphics are made by the operator uploading the psd template file, and the background parses the psd template file into an html file, and then replaces the text in the template file with different dynamic data (macros). In addition, a font file library is created, and the operator uploads the purchased fonts through the background. For the uploaded fonts, openType will be called to parse the corresponding font name in adobe PhotoShop corresponding to the current font, and the font file name and the parsed name in ps will be stored in the data, so that the font name in psd will have a mapping relationship with the font name on the server.

[0083] The original plan was to put the fonts on the server, and the server read the local originals, but with the new font server, a new server needs to be added, and the server needs to solve similar problems as above, the correspondence between the server font name and the font name in the psd. At present, the server directly loads the cdn file remotely. The fonts in the cdn file are all fonts generated by the service. The fonts are very small and do not affect the service mapping. Previously, mapping needed to rely on the service (mapping service, the front end sends the html file to the mapping service, the service parses the html and macros, and generates the corresponding pictures) for font installation. The page has problems with fonts being too large and loading too slowly. At present, the program operators only need to upload the fonts in the psd that are within the copyright fonts, without relying on the service font installation, and there will be no inconsistency between the service and the preview. The page experience is also smoother and will not load fonts that are too large.

[0084] First, maintain the font library list, and upload the font to the font library. During the upload process, the openType method is used to parse the font name in the picture adboe and store it in the database. The font list has a mapping relationship between the adobe name and the font name, and the adobe name can be used to obtain the font name. Secondly, through the job docking pi library (a macro data source library), a font is generated for each library name. For example: Shanghai Dao Ke Dao Hotel will collect 'Shanghai Dao Ke Hotel', and these words will generate a font as a whole, which will correspond to the macro name this time and be stored as a node address. The operation uploads the psd file, parses the adobe font name during the upload process, and then searches the library for the corresponding font to generate a module. If it is a static template file, the corresponding font file can be generated according to the lens font for mapping. If it is a dynamic template, there are macros in the template, such as title macros, destination macros, etc. Through the job method, the corresponding macro is run to generate a font file with the font name corresponding to the macro, so that the corresponding font file can be accurately found when making advertising maps, and the corresponding advertising maps can be made.

[0085] The above specific implementation methods do not constitute a limitation on the protection scope of the present invention. Any technician familiar with the art can use the above disclosed methods and technical contents to make many possible changes and modifications to the technical solution of the present application without departing from the scope of the technical solution of the present application, or modify it into an equivalent embodiment of equivalent changes. Therefore, any simple modification, equivalent change and modification made to the above embodiments based on the technical essence of the present application without departing from the content of the technical solution of the present application still falls within the scope of protection of the technical solution of the present application.

[0086] Figure 2 Schematic diagram of the structure of the lightweight operation system of the tourism product page of the present invention. Figure 2As shown, the embodiment of the present invention further provides a tourism product page lightweight operation system, which is used to implement the above-mentioned tourism product page lightweight operation method. The tourism product page lightweight operation system 5 includes:

[0087] The layer file module 51 uploads a layer file package for generating a tourism product page to the server, wherein the layer file package includes at least one image layer group and at least one text layer group, wherein the image layer group includes at least one tourism product image layer, and the text layer group includes at least one text layer of the tourism product name having first font information.

[0088] The layer parsing module 52 parses the layer file package and converts the first font information of the text layer into corresponding second font information pre-stored in the server based on a preset server font mapping table.

[0089] The font conversion module 53, when the second font information in at least one text layer does not belong to the preset common font set, takes the text layer that does not belong to the preset common font set as the target text layer, and executes the mapping establishment module.

[0090] The mapping establishment module 54 generates a text node address for each target text layer, the text node address stores the text information generated based on at least the second font information of the target text layer and the name of the tourism product, and establishes a mapping relationship between the target text layer and the text node address.

[0091] The page generation module 55 generates the travel product page based on the picture layer group and the text layer group with the copy node address when the user terminal refreshes to the travel product page.

[0092] In a preferred embodiment, the tourism product page in the layer file module 51 is a hotel product, the tourism product name is the hotel name, the layer file package is a PSD file, and the text layer includes the tourism product name with first font information, preset colors and preset rendering effects, and the first font information is the adobe font name, but is not limited to this.

[0093] In a preferred embodiment, the layer parsing module 52 is configured to parse the layer file package through the OpenType tool to obtain the image layer and the text layer. Based on the preset server font mapping table, the first font information of the text layer of the PSD file is converted into the corresponding second font information pre-stored on the server side, but not limited to this.

[0094] In a preferred embodiment, the font conversion module 53 is configured to traverse the text layer and determine whether all the second font information in the text layer belongs to the preset common font set. If so, the process ends. If not, the text layer that does not belong to the preset common font set is used as the target text layer, and the mapping establishment module 54 is executed, but the present invention is not limited thereto.

[0095] In a preferred embodiment, the mapping establishment module 54 is configured to generate a copy node address for each target copy layer, and the copy node address stores copy information generated based on at least the second font information and the name of the tourism product. A mapping relationship between the target copy layer and the copy node address is established, and the target copy layer is replaced with the copy node address.

[0096] In a preferred embodiment, the page generation module 55 is configured to call the copy node address when the user terminal refreshes to the travel product page, and jointly generate the travel product page based on the stacking relationship between the image layer group and the text layer group with the copy node address, and send it to the user terminal.

[0097] In a preferred embodiment, the page generation module 55 is further configured to match the keywords extracted from the historical travel information of the user terminal with the optional picture layers in the picture layer group, and obtain the optional picture layer with the highest matching degree as the target layer. Based on the stacking relationship between the target layer and the text layer group with the copy node address, a travel product page is jointly generated and sent to the user terminal.

[0098] The lightweight operation system for the tourism product page of the present invention can avoid loading font files that are too large, making the page experience smoother and optimizing the web page experience on the mobile terminal.

[0099] The embodiment of the present invention also provides a lightweight operation device for a tourism product page, comprising a processor and a memory, wherein executable instructions of the processor are stored, wherein the processor is configured to execute the steps of a lightweight operation method for a tourism product page via the executable instructions.

[0100] As shown above, the lightweight operation device of the tourism product page of this embodiment of the present invention can avoid loading font files that are too large, making the page experience smoother and optimizing the web page experience on the mobile terminal.

[0101] It will be appreciated by those skilled in the art that various aspects of the present invention may be implemented as systems, methods or program products. Therefore, various aspects of the present invention may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or a combination of hardware and software implementations, which may be collectively referred to herein as "circuits", "modules" or "platforms".

[0102] Figure 3 This is a schematic diagram of the structure of the lightweight operating device for the tourism product page of the present invention. Figure 3 The electronic device 600 according to this embodiment of the present invention is described. Figure 3The electronic device 600 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.

[0103] like Figure 3 As shown, the electronic device 600 is in the form of a general computing device. The components of the electronic device 600 may include, but are not limited to: at least one processing unit 610, at least one storage unit 620, a bus 630 connecting different platform components (including the storage unit 620 and the processing unit 610), a display unit 640, etc.

[0104] The storage unit stores program codes, which can be executed by the processing unit 610, so that the processing unit 610 performs the steps according to various exemplary embodiments of the present invention described in the above method section of this specification. For example, the processing unit 610 can perform the following steps: Figure 1 Follow the steps shown in .

[0105] The storage unit 620 may include a readable medium in the form of a volatile storage unit, such as a random access memory unit (RAM) 6201 and / or a cache memory unit 6202 , and may further include a read-only memory unit (ROM) 6203 .

[0106] The storage unit 620 may also include a program / utility 6204 having a set (at least one) of program modules 6205, such program modules 6205 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.

[0107] Bus 630 may represent one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.

[0108] The electronic device 600 may also communicate with one or more external devices 700 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), may also communicate with one or more devices that enable a user to interact with the electronic device 600, and / or communicate with any device that enables the electronic device 600 to communicate with one or more other computing devices (e.g., routers, modems, etc.). Such communication may be performed via an input / output (I / O) interface 650. Furthermore, the electronic device 600 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) via a network adapter 660. The network adapter 660 may communicate with other modules of the electronic device 600 via a bus 630. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 600, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage platforms, etc.

[0109] The embodiment of the present invention also provides a computer-readable storage medium for storing a program, and the steps of the lightweight operation method of the tourism product page are implemented when the program is executed. In some possible implementations, various aspects of the present invention can also be implemented in the form of a program product, which includes a program code. When the program product is run on a terminal device, the program code is used to enable the terminal device to execute the steps of various exemplary embodiments of the present invention described in the above method section of this specification.

[0110] As shown above, the tourism product page lightweight operation system of this embodiment of the present invention can avoid loading font files that are too large, making the page experience smoother and optimizing the web page experience on the mobile terminal.

[0111] Figure 4 Schematic diagram of the structure of the computer-readable storage medium of the present invention. Figure 4 As shown, a program product 800 for implementing the above method according to an embodiment of the present invention is described, which can adopt a portable compact disk read-only memory (CD-ROM) and include program code, and can be run on a terminal device, such as a personal computer. However, the program product of the present invention is not limited thereto. In this document, a readable storage medium can be any tangible medium containing or storing a program, which can be used by or in combination with an instruction execution system, an apparatus or a device.

[0112] The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination thereof. More specific examples (a non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof.

[0113] Computer readable storage media may include data signals propagated in baseband or as part of a carrier wave, wherein readable program codes are carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The readable storage medium may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, device, or device. The program code contained on the readable storage medium may be transmitted using any suitable medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the above.

[0114] Program code for performing the operations of the present invention may be written in any combination of one or more programming languages, including object-oriented programming languages ​​such as Java, C++, etc., and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., through the Internet using an Internet service provider).

[0115] In summary, the purpose of the present invention is to provide a lightweight operation method, system, device and storage medium for a tourism product page, which can avoid loading font files that are too large, make the page experience smoother, and optimize the web page experience on the mobile terminal.

[0116] The above contents are further detailed descriptions of the present invention in combination with specific preferred embodiments, and it cannot be determined that the specific implementation of the present invention is limited to these descriptions. For ordinary technicians in the technical field to which the present invention belongs, several simple deductions or substitutions can be made without departing from the concept of the present invention, which should be regarded as falling within the protection scope of the present invention.

Claims

1. A lightweight operation method for a tourism product page, characterized in that: The following steps are involved: S110, uploading a layer file package for generating a tourism product page to a server, wherein the layer file package includes at least one picture layer group and at least one text layer group, wherein the picture layer group includes at least one tourism product picture layer, and the text layer group includes at least one text layer of a tourism product name having first font information; S120, parsing the layer file package, and converting the first font information of the text layer into corresponding second font information pre-stored in the server based on a preset server font mapping table; S130, when the second font information in at least one of the text layers does not belong to the preset common font set, the text layer that does not belong to the preset common font set is used as the target text layer, and then step S140 is executed; S140, generating a copy node address for each target copy layer, wherein the copy node address stores copy information generated based on at least the second font information of the target copy layer and the name of the tourism product, and establishing a mapping relationship between the target copy layer and the copy node address; as well as S150. When the user terminal refreshes to the travel product page, a travel product page is generated based on the image layer group and the text layer group having the text node address.

2. The lightweight operation method of the tourism product page according to claim 1, characterized in that: In step S110, the tourism product page is a hotel product, the tourism product name is a hotel name, the layer file package is a PSD file, and the text layer includes the tourism product name with first font information, a preset color, and a preset rendering effect, and the first font information is an adobe font name.

3. The lightweight operation method of the tourism product page according to claim 2, characterized in that: The step S120 includes: S121, parsing the layer file package by using an OpenType tool to obtain the image layer and the text layer; S122: Based on a preset server font mapping table, convert the first font information of the text layer of the PSD file into corresponding second font information pre-stored in the server.

4. The lightweight operation method of a tourism product page according to claim 2, characterized in that: The step S130 includes: Traverse the text layer to determine whether all the second font information in the text layer belongs to the preset common font set. If so, end; if not, take the text layer that does not belong to the preset common font set as the target text layer, and execute step S140.

5. The lightweight operation method of the tourism product page according to claim 1, characterized in that: The step S140 includes: S141, generating a copy node address for each target copy layer, wherein the copy node address stores copy information generated based on at least the second font information and the name of the tourism product; S142: Establish a mapping relationship between the target copywriting layer and the copywriting node address, and replace the target copywriting layer with the copywriting node address.

6. The lightweight operation method of a tourism product page according to claim 1, characterized in that: The step S150 includes: S151, when the user terminal refreshes to the travel product page, the copywriting node address is called; S152, based on the stacking relationship between the image layer group and the text layer group having the text node address, jointly generate a travel product page and send it to the user end.

7. The lightweight operation method of a tourism product page according to claim 1, characterized in that: The step S152 includes: S1521, matching the keywords extracted from the historical travel information of the user terminal with the optional picture layers in the picture layer group, and obtaining the optional picture layer with the highest matching degree as the target layer; S1522. Based on the stacking relationship between the target layer and the text layer group having the text node address, a travel product page is jointly generated and sent to the user end.

8. A tourism product page lightweight operation system, used to implement the tourism product page lightweight operation method according to claim 1, characterized in that: include: A layer file module uploads a layer file package for generating a tourism product page to a server, wherein the layer file package includes at least one picture layer group and at least one text layer group, wherein the picture layer group includes at least one tourism product picture layer, and the text layer group includes at least one text layer of the tourism product name having first font information; A layer parsing module parses the layer file package and converts the first font information of the text layer into corresponding second font information pre-stored in the server based on a preset server font mapping table; a font conversion module, when the second font information in at least one of the text layers does not belong to the preset common font set, taking the text layer that does not belong to the preset common font set as the target text layer, and executing the mapping establishment module; A mapping establishment module generates a copy node address for each target copy layer, wherein the copy node address stores copy information generated based on at least the second font information of the target copy layer and the name of the tourism product, and establishes a mapping relationship between the target copy layer and the copy node address; as well as The page generation module generates a travel product page based on the image layer group and the text layer group having the text node address when the user terminal refreshes to the travel product page.

9. A lightweight operating device for a tourism product page, characterized in that: include: processor; a memory storing executable instructions of the processor; Wherein, the processor is configured to execute the steps of the lightweight operation method of the tourism product page as described in any one of claims 1 to 7 by executing the executable instructions.

10. A computer-readable storage medium for storing a program, characterized in that: When the program is executed by a processor, the steps of the lightweight operation method of the tourism product page described in any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Method and device for generating static page

    CN104020984A

  • Chinese font subset-based webpage font display method and system

    CN107704615A

  • Chinese font loading method and device

    CN110705210A

  • Image analysis processing method and device

    CN112330532A

  • Web font distribution method and system therefor

    JP2015118619A