WO2022111591A1 - 页面生成方法和装置、存储介质和电子设备 - Google Patents

页面生成方法和装置、存储介质和电子设备 Download PDF

Info

Publication number
WO2022111591A1
WO2022111591A1 PCT/CN2021/133209 CN2021133209W WO2022111591A1 WO 2022111591 A1 WO2022111591 A1 WO 2022111591A1 CN 2021133209 W CN2021133209 W CN 2021133209W WO 2022111591 A1 WO2022111591 A1 WO 2022111591A1
Authority
WO
WIPO (PCT)
Prior art keywords
page
component
file
user
editing
Prior art date
Application number
PCT/CN2021/133209
Other languages
English (en)
French (fr)
Inventor
朱耀华
Original Assignee
北京有竹居网络技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 北京有竹居网络技术有限公司 filed Critical 北京有竹居网络技术有限公司
Publication of WO2022111591A1 publication Critical patent/WO2022111591A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
    • G06F9/44526Plug-ins; Add-ons

Definitions

  • the present disclosure relates to the field of web pages, and in particular, to a method and apparatus for generating pages, a storage medium and an electronic device.
  • the current web page is usually generated by rendering the page file.
  • the name of the component and the content of the item are usually set to be consistent or related, so that the user can quickly find the position of the component to be edited and improve the efficiency of page editing.
  • the present disclosure provides a method for generating a page, the method includes: in response to an editing operation by a user, determining a component name of a page component edited by a user, and component content input by the user for the page component; The corresponding relationship between the component name and the component identifier is to determine the component identifier of the page component in the page file, wherein the component identifier is a character without text semantics; based on the component identifier and the component content, modify the Page file; generate a page based on the page file.
  • the present disclosure provides an apparatus for generating a page, the apparatus comprising: an obtaining module for determining, in response to an editing operation by a user, a component name of a page component edited by the user, and component content input by the user for the page component ; determine the module for determining the component identifier of the page component in the page file according to the corresponding relationship between the preset component name and the component identifier, wherein the component identifier is a character that does not have text semantics; modifying the module, using modifying the page file based on the component identifier and the component content; a generating module, configured to generate a page based on the page file.
  • the present disclosure provides a computer-readable medium on which a computer program is stored, and when the program is executed by a processing apparatus, implements one or more of the page generation methods described in any one of the first aspect of the present disclosure step.
  • the present disclosure provides an electronic device, including a storage device and a processing device, where a computer program is stored on the storage device, and the processing device is configured to execute the computer program in the storage device, so as to realize the first aspect of the present disclosure
  • a computer program is stored on the storage device
  • the processing device is configured to execute the computer program in the storage device, so as to realize the first aspect of the present disclosure
  • the present disclosure provides a computer program comprising: instructions that, when executed by a processor, cause the processor to perform one or more steps of the page generation method of any one of the first aspects.
  • the present disclosure provides a computer program product comprising instructions that, when executed by a processor, cause the processor to perform one or more steps of the page generation method of any one of the first aspects.
  • FIG. 1 is a flowchart of a method for generating a page according to an exemplary disclosed embodiment.
  • Fig. 2 is a schematic diagram of a page editing interface according to an exemplary disclosed embodiment.
  • Fig. 3 is a block diagram of a page generating apparatus according to an exemplary disclosed embodiment.
  • Fig. 4 is a block diagram of an electronic device according to an exemplary disclosed embodiment.
  • the term “including” and variations thereof are open-ended inclusions, ie, "including but not limited to”.
  • the term “based on” is “based at least in part on.”
  • the term “one embodiment” means “at least one embodiment”; the term “another embodiment” means “at least one additional embodiment”; the term “some embodiments” means “at least some embodiments”. Relevant definitions of other terms will be given in the description below.
  • FIG. 1 is a flowchart of a method for generating a page according to an exemplary disclosed embodiment. As shown in FIG. 1 , the method includes:
  • the component name can be described by the project name.
  • the component name of the component describing the user name can be user_name
  • the component name of the component describing the company name can be company_name. Find the component that needs to be edited and prevent editing errors caused by confusing component names.
  • the component is identified as a character without literal semantics.
  • the component identifier can be a random combination of numbers and letters.
  • the component identifier of the page component in the first position of the page can be defined as B39sdhoNJu28
  • the component identifier of the page component in the second position of the page can be defined as OIYH279Whuwi3
  • you need to edit the component content of the page component in the second position of the page When editing, you can modify the fields in the page file that describe the page component whose component ID is OIYH279Whuwi3.
  • the component identifier of the page component in the page file can be determined by the corresponding relationship between the component name and the component identifier. In this way, after the user edits the page component, the component name of the page component corresponding to the page component in the page file can be determined. Modify the field of the component identifier of the page, so that the user's modification of the page component can be mapped to the page file, on the basis of ensuring the editing efficiency of the page, so as not to leave a textual component name or project name in the page file. effect, improve the information security on the page.
  • the preset correspondence between component names and component identifiers may be stored in the form of a JSON file.
  • MapJSON may be used to describe the mapping relationship between component names and component identifiers.
  • the mapping relationship may be "company name company_name ;Component ID: OIYH279Whuwi3".
  • the page component used to describe the company name item is named "company_name”.
  • the crawler obtains the input operation of "company_name”, it can modify the content of the field in the page file to complete the editing of the page components. In this way, after the page is generated, the crawler can easily crawl from the page file.
  • the final page can be obtained by rendering the page file, and the page can be a website page, an application page, a game page, etc.
  • the preview page can be rendered based on the page file in real time. That is to say, a preview page may be generated based on the original page file, and after modification based on the user's editing operation, the preview page may be updated based on the modified page file.
  • the editing operation can be previewed and displayed by rendering the modified page file in real time, which improves the convenience of visual editing.
  • the preview page includes an edit control for receiving user editing operations; in response to a user's click operation on the edit control in the preview page, a component name corresponding to the edit control is determined ; In response to the user's input operation on the editing control, determine the component content input by the user.
  • the editing control is configured in the form of a JSON file
  • the component content in the page can be configured in the form of an input box through the JSON file for editing.
  • the input The box is configured at the position of the page component corresponding to the input box in the preview page, and is used to receive the user's editing operation on the page component.
  • the editing operation in S11 may be performed by entering text, pictures, videos, etc. in the input box of the item name, or by editing the editing controls.
  • Figure 2 a Schematic diagram of the page editing interface, the edit box for the project name is shown on the left, and the preview page equipped with editing controls is shown on the right. You can complete it by entering the content in the input box on the left or right.
  • For editing of the component corresponding to the input box in actual use, only the input box shown on the left, or only the input box shown on the right that is consistent with the position of the component, or a combination of the two can be used.
  • a page file and a page editing file corresponding to the page template are determined, wherein the page editing file includes the editing file for receiving an editing operation by the user controls.
  • the page template may further include a preview image, and the image of the page generated by the page file corresponding to the page template may be used as the preview image, and in response to the user's click operation on the preview image, it may be determined that the user has selected the page template corresponding to the preview image , thereby pulling the page editing file and the page file corresponding to the page template, so that the user can modify the page components in the page through the editing control provided by the page editing file, so as to obtain the modified page file.
  • the modification operation of the page component in the preview page by the user can also be obtained, and the description content of the page component in the page file is modified, so that the page component in the page file is modified.
  • Page components are consistent with the user's modification operations. For example, when the user drags and drops the size of a page component in the preview page to enlarge, the component name of the page component can be determined by the adjustment control, and the component identifier can be determined by the component name, and the page corresponding to the component identifier in the page file can be modified. Components are sized to accommodate this adjustment. It should be noted that the adjustment control can be generated by the page editing file.
  • the modification operation is a move operation, modify the description content of the editing control in the page editing file, so that the position of the editing control is consistent with the position of the page component. That is to say, when the modification operation is a move operation, not only the description content of the page component in the page file is modified, but also the description content of the editing control in the page editing file, so that the position of the editing control is the same as that of the modified page component. The position of the corresponding page component is the same, so as to avoid that the editing control cannot correctly receive the editing operation for the corresponding page component.
  • the current page file and the page editing file can be exported and stored as a corresponding page template, so that the page template can be adjusted visually and the convenience of page design can be improved. degree.
  • the component name corresponding to the newly added editing control and the component identifier of the newly added page component are stored as a preset correspondence relationship.
  • a component identifier can be randomly generated in the page file, and a description of the position and style of the page component can be added, and added in the page editing file.
  • the component name corresponding to the editing control may be defined by the user or randomly generated, and the component name and the component identifier are stored as a preset corresponding relationship.
  • a string can be randomly generated each time a new page template is saved, and the component identifier in the current page file can be updated according to the randomly generated string. , and based on the updated component identifier, update the preset corresponding relationship between the component name and the component identifier, export the updated file page and the current page editing file, and store them as a page template correspondingly.
  • the component identifiers used to describe the page components of the same project can be different, and the corresponding relationship between component names and component identifiers in each page template is different, which can prevent
  • the problem of reduced information security due to the leakage of the file storing the corresponding relationship can also prevent others from manually associating the item name and component identifier in one page and then applying it to other webpage templates.
  • the information security of webpages under other templates is reduced. The problem.
  • Fig. 3 is a block diagram of a page generating apparatus according to an exemplary disclosed embodiment. As shown in Fig. 3, the apparatus 300 includes:
  • the obtaining module 310 is configured to, in response to an editing operation of the user, determine the component name of the page component edited by the user and the component content input by the user for the page component.
  • the determining module 320 is configured to determine the component identifier of the page component in the page file according to the preset correspondence between the component name and the component identifier, wherein the component identifier is a character without textual semantics.
  • a modification module 330 configured to modify the page file based on the component identifier and the component content.
  • the generating module 340 is configured to generate a page based on the page file.
  • the apparatus further includes a preview module, configured to generate a preview page based on the original page file, and update the preview page based on the modified page file.
  • the preview page includes an editing control for receiving an editing operation from a user;
  • the obtaining module 310 is configured to, in response to a user's click operation on the editing control in the preview page, determine The name of the component corresponding to the edit control, and in response to the user's input operation on the edit control, the content of the component input by the user is determined.
  • the apparatus further includes a selection module, configured to determine a page file and a page editing file corresponding to the page template based on a user's selection operation on the page template, wherein the page editing file includes The editing control for receiving user editing operations.
  • a selection module configured to determine a page file and a page editing file corresponding to the page template based on a user's selection operation on the page template, wherein the page editing file includes The editing control for receiving user editing operations.
  • the apparatus further includes an editing module, configured to obtain the modification operation of the page component in the preview page by the user; modify the description content of the page component in the page file, so that all The page component in the page file is consistent with the user's modification operation; modify the description content of the edit control in the page edit file, so that the position of the edit control is consistent with the position of the page component;
  • the current page file and page edit file are exported and stored as page templates.
  • the editing module is further configured to obtain the user's operation of adding or deleting page components in the preview page; adding or deleting page components in the page file, and adding or deleting page components in the page Add or delete edit controls in the edit file; in the case of obtaining the addition operation of the page component, store the component name corresponding to the newly added edit control and the component identifier of the newly added page component as a preset correspondence relationship.
  • the editing module is further configured to generate a character string randomly, and update the component identifier in the current page file according to the randomly generated character string; based on the updated component identifier, update the preset
  • the corresponding relationship between the set component name and the component ID; the updated file page and the current page editing file are exported and stored as a corresponding page template.
  • Terminal devices in the embodiments of the present disclosure may include, but are not limited to, such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablets), PMPs (portable multimedia players), vehicle-mounted terminals (eg, mobile terminals such as in-vehicle navigation terminals), etc., and stationary terminals such as digital TVs, desktop computers, and the like.
  • the electronic device shown in FIG. 4 is only an example, and should not impose any limitation on the function and scope of use of the embodiments of the present disclosure.
  • an electronic device 400 may include a processing device (eg, a central processing unit, a graphics processor, etc.) 401 that may be loaded into random access according to a program stored in a read only memory (ROM) 402 or from a storage device 408 Various appropriate actions and processes are executed by the programs in the memory (RAM) 403 . In the RAM 403, various programs and data required for the operation of the electronic device 400 are also stored.
  • the processing device 401, the ROM 402, and the RAM 403 are connected to each other through a bus 404.
  • An input/output (I/O) interface 405 is also connected to bus 404 .
  • I/O interface 405 the following devices may be connected to the I/O interface 405: input devices 406 including, for example, a touch screen, touchpad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; including, for example, a liquid crystal display (LCD), speakers, vibration An output device 407 of a computer, etc.; a storage device 408 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 409. Communication means 409 may allow electronic device 400 to communicate wirelessly or by wire with other devices to exchange data.
  • FIG. 4 shows electronic device 400 having various means, it should be understood that not all of the illustrated means are required to be implemented or provided. More or fewer devices may alternatively be implemented or provided.
  • embodiments of the present disclosure include a computer program product comprising a computer program carried on a non-transitory computer readable medium, the computer program containing program code for performing the method illustrated in the flowchart.
  • the computer program may be downloaded and installed from the network via the communication device 409, or from the storage device 408, or from the ROM 402.
  • the processing apparatus 401 When the computer program is executed by the processing apparatus 401, the above-mentioned functions defined in the methods of the embodiments of the present disclosure are executed.
  • the computer-readable medium mentioned above in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium, or any combination of the above two.
  • the computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus or device, or a combination of any of the above. More specific examples of computer readable storage media may include, but are not limited to, electrical connections having one or more wires, portable computer disks, hard disks, random access memory (RAM), read only memory (ROM), erasable Programmable read only memory (EPROM or flash memory), fiber optics, portable compact disk read only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
  • a computer-readable storage medium may be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, apparatus, or device.
  • a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave with computer-readable program code embodied thereon. 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 foregoing.
  • a computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device .
  • Program code embodied on a computer readable medium may be transmitted using any suitable medium including, but not limited to, electrical wire, optical fiber cable, RF (radio frequency), etc., or any suitable combination of the foregoing.
  • electronic devices can communicate using any currently known or future developed network protocols such as HTTP (HyperText Transfer Protocol), and can communicate with digital data in any form or medium (
  • network protocols such as HTTP (HyperText Transfer Protocol)
  • communication networks are interconnected.
  • Examples of communication networks include local area networks (“LAN”), wide area networks (“WAN”), the Internet (eg, the Internet), and peer-to-peer networks (eg, ad hoc peer-to-peer networks), as well as any currently known or future development network of.
  • the above-mentioned computer-readable medium may be included in the above-mentioned electronic device; or may exist alone without being assembled into the electronic device.
  • Computer program code for performing operations of the present disclosure may be written in one or more programming languages, including but not limited to object-oriented programming languages—such as Java, Smalltalk, C++, and This includes conventional procedural programming languages - such as the "C" language or similar programming languages.
  • the program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer, or entirely on the remote computer or server.
  • the remote computer may be connected to the user's computer through any kind of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (eg, using an Internet service provider to via Internet connection).
  • LAN local area network
  • WAN wide area network
  • each block in the flowchart or block diagrams may represent a module, segment, or portion of code that contains one or more logical functions for implementing the specified functions executable instructions.
  • the functions noted in the blocks may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved.
  • each block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations can be implemented in dedicated hardware-based systems that perform the specified functions or operations , or can be implemented in a combination of dedicated hardware and computer instructions.
  • the modules involved in the embodiments of the present disclosure may be implemented in software or hardware. Among them, the name of the module does not constitute a limitation of the module itself under certain circumstances.
  • exemplary types of hardware logic components include: Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), Systems on Chips (SOCs), Complex Programmable Logical Devices (CPLDs) and more.
  • FPGAs Field Programmable Gate Arrays
  • ASICs Application Specific Integrated Circuits
  • ASSPs Application Specific Standard Products
  • SOCs Systems on Chips
  • CPLDs Complex Programmable Logical Devices
  • a machine-readable medium may be a tangible medium that may contain or store a program for use by or in connection with the instruction execution system, apparatus or device.
  • the machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium.
  • Machine-readable media may include, but are not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or devices, or any suitable combination of the foregoing.
  • machine-readable storage media would include one or more wire-based electrical connections, portable computer disks, hard disks, random access memory (RAM), read only memory (ROM), erasable programmable read only memory (EPROM or flash memory), fiber optics, compact disk read only memory (CD-ROM), optical storage, magnetic storage, or any suitable combination of the foregoing.
  • RAM random access memory
  • ROM read only memory
  • EPROM or flash memory erasable programmable read only memory
  • CD-ROM compact disk read only memory
  • magnetic storage or any suitable combination of the foregoing.
  • Example 1 provides a method for generating a page, the method comprising: in response to an editing operation by a user, determining a component name of a page component edited by the user, and inputting a user input for the page component Component content; determine the component identifier of the page component in the page file according to the preset correspondence between the component name and the component identifier, wherein the component identifier is a character without textual semantics; based on the component identifier and For the component content, modify the page file; generate a page based on the page file.
  • example 2 provides the method of example 1, the method further includes: generating a preview page based on the original page file; After the page file, the method further includes: updating the preview page based on the modified page file.
  • Example 3 provides the method of Example 2, wherein the preview page includes an edit control for receiving an editing operation by the user; the page component edited by the user is determined in response to the editing operation by the user The component name of the page component, and the component content input by the user for the page component, including: in response to the user's click operation on the editing control in the preview page, determining the component name corresponding to the editing control; The input operation of the control determines the content of the component entered by the user.
  • Example 4 provides the method of Example 3, the method further includes: determining a page file and a page editing file corresponding to the page template based on a user's selection operation on the page template, wherein, The page editing file includes the editing control for receiving user editing operations.
  • Example 5 provides the method of Example 4, the method further comprising: obtaining a modification operation of a page component in a preview page by a user; modifying a modification of the page component in the page file description content, so that the page component in the page file is consistent with the user's modification operation; in the case that the modification operation is a move operation, the method further includes: modifying the page editing file in the page editing file. Editing the description content of the control so that the position of the editing control is consistent with the position of the page component; the method further includes: exporting the current page file and the page editing file, and correspondingly storing them as a page template.
  • Example 6 provides the method of Example 5, wherein the acquiring the user's modification operation on the page component in the preview page further includes: acquiring the user's adding operation on the page component in the preview page or delete operation; the method further includes: adding or deleting page components in the page file, and adding or deleting editing controls in the page editing file; in the case of acquiring the adding operation of the page component, adding or deleting a new page component
  • the component name corresponding to the added edit control and the component identifier of the added page component are stored as a preset corresponding relationship.
  • Example 7 provides the method of Example 5 or Example 6, wherein the current page file and the page edit file are exported and stored as a page template correspondingly, including: randomly generating a string, and Update the component identification in the current page file according to the randomly generated string; update the corresponding relationship between the preset component name and the component identification based on the updated component identification; edit the file with the updated file page and the current page Export and store as a corresponding page template.
  • Example 8 provides an apparatus for generating a page, the apparatus comprising: an obtaining module for determining, in response to an editing operation of a user, a component name of a page component edited by the user, and a user The component content input for the page component; the determining module, configured to determine the component identifier of the page component in the page file according to the preset correspondence between the component name and the component identifier, wherein the component identifier does not have text Semantic characters; a modification module for modifying the page file based on the component identifier and the component content; a generation module for generating a page based on the page file.
  • Example 9 provides the apparatus of Example 8, the apparatus further comprising a preview module for generating a preview page based on the original page file, and updating all the preview pages based on the modified page file the preview page.
  • Example 10 provides the apparatus of Example 9, wherein the preview page includes an editing control for receiving an editing operation by a user; the obtaining module is configured to respond to the user's request for the preview The click operation of the edit control in the page determines the component name corresponding to the edit control, and in response to the user's input operation on the edit control, determines the content of the component input by the user.
  • Example 11 provides the apparatus of Example 10, the apparatus further includes a selection module, configured to determine the page file and page corresponding to the page template based on a user's selection operation on the page template An editing file, wherein the page editing file includes the editing control for receiving user editing operations.
  • a selection module configured to determine the page file and page corresponding to the page template based on a user's selection operation on the page template
  • An editing file wherein the page editing file includes the editing control for receiving user editing operations.
  • Example 12 provides the apparatus of Example 11, the apparatus further includes an editing module, configured to obtain a user's modification operation on page components in the preview page; The description content of the page component, so that the page component in the page file is consistent with the user's modification operation; modify the description content of the editing control in the page editing file, so that the editing control The location is consistent with the location of the page component; the current page file and the page editing file are exported and stored as a page template correspondingly.
  • an editing module configured to obtain a user's modification operation on page components in the preview page; The description content of the page component, so that the page component in the page file is consistent with the user's modification operation; modify the description content of the editing control in the page editing file, so that the editing control The location is consistent with the location of the page component; the current page file and the page editing file are exported and stored as a page template correspondingly.
  • Example 13 provides the apparatus of Example 12, and the editing module is further configured to obtain an operation of adding or deleting a page component in the preview page by the user; in the page file Add or delete page components, and add or delete editing controls in the page editing file; when the operation of adding the page components is obtained, compare the component name corresponding to the newly added editing control with the name of the newly added page component.
  • the component identifier is stored as a preset correspondence.
  • Example 14 provides the apparatus of Example 12 or Example 13, the editing module is further configured to randomly generate a character string, and update the current page file according to the randomly generated character string.
  • Component identification based on the updated component identification, update the preset corresponding relationship between the component name and the component identification; export the updated file page and the current page editing file, and store them as a page template correspondingly.
  • Example 15 provides a computer program comprising: instructions that, when executed by a processor, cause the processor to perform one or more of the page generation methods of any one of Examples 1 to 7 steps.
  • Example 16 provides a computer program product comprising instructions that, when executed by a processor, cause the processor to perform one or more of the page generation methods of any one of Examples 1-7 steps.
  • different page components can be distinguished in the page file by component identifiers that do not have character semantics, and the user's input content to the page components can be modified to the page file through the corresponding relationship between the component names and the component identifiers.
  • the correlation between the component name in the page file used to generate the page and the project content can be reduced, making it difficult for others to extract from the page file. to specific project information, thereby improving the information security of the page.

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

一种页面生成方法和装置、存储介质和电子设备,所述方法包括:响应于用户的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容(S11);根据预设的组件名称与组件标识的对应关系,确定所述页面组件在页面文件中的组件标识(S12),其中,所述组件标识为不具有文字语义的字符;基于所述组件标识和所述组件内容,修改所述页面文件(S13);基于所述页面文件生成页面(S14)。可以提升网页的信息安全性。

Description

页面生成方法和装置、存储介质和电子设备
相关申请的交叉引用
本申请以申请号为202011356170.5,申请日为2020年11月26日的中国申请为基础,并主张其优先权,该中国申请的公开内容在此作为整体引入本申请中。
技术领域
本公开涉及网页领域,具体地,涉及一种页面生成方法和装置、存储介质和电子设备。
背景技术
目前的网络页面通常是通过页面文件渲染生成的,目前的页面文件的编辑方式有两种,一种为直接对页面文件进行编辑,一种为通过编辑器对页面文件进行编辑,在这两种方式中,为了方便用户的编辑,通常将组件名称和项目的内容设置为一致或相关,使得用户可以快速地找到需要编辑的组件的位置,提高页面编辑的效率。
发明内容
提供该发明内容部分以便以简要的形式介绍构思,这些构思将在后面的具体实施方式部分被详细描述。该发明内容部分并不旨在标识要求保护的技术方案的关键特征或必要特征,也不旨在用于限制所要求的保护的技术方案的范围。
第一方面,本公开提供一种页面生成方法,所述方法包括:响应于用户 的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容;根据预设的组件名称与组件标识的对应关系,确定所述页面组件在页面文件中的组件标识,其中,所述组件标识为不具有文字语义的字符;基于所述组件标识和所述组件内容,修改所述页面文件;基于所述页面文件生成页面。
第二方面,本公开提供一种页面生成装置,所述装置包括:获取模块,用于响应于用户的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容;确定模块,用于根据预设的组件名称与组件标识的对应关系,确定所述页面组件在页面文件中的组件标识,其中,所述组件标识为不具有文字语义的字符;修改模块,用于基于所述组件标识和所述组件内容,修改所述页面文件;生成模块,用于基于所述页面文件生成页面。
第三方面,本公开提供一种计算机可读介质,其上存储有计算机程序,该程序被处理装置执行时实现本公开第一方面中任一项所述的页面生成方法中的一个或多个步骤。
第四方面,本公开提供一种电子设备,包括存储装置和处理装置,存储装置上存储有计算机程序,处理装置用于执行所述存储装置中的所述计算机程序,以实现本公开第一方面中任一项所述的页面生成方法中的一个或多个步骤。
第五方面,本公开提供一种计算机程序,包括:指令,该指令当由处理器执行时使处理器执行第一方面中任一项所述的页面生成方法中的一个或多个步骤。
第六方面,本公开提供一种计算机程序产品,包括指令,该指令当由处理器执行时使处理器执行第一方面中任一项所述的页面生成方法中的一个或多个步骤。
本公开的其他特征和优点将在随后的具体实施方式部分予以详细说明。
附图说明
结合附图并参考以下具体实施方式,本公开各实施例的上述和其他特征、优点及方面将变得更加明显。贯穿附图中,相同或相似的附图标记表示相同或相似的元素。应当理解附图是示意性的,原件和元素不一定按照比例绘制。在附图中:
图1是根据一示例性公开实施例示出的一种页面生成方法的流程图。
图2是根据一示例性公开实施例示出的一种页面编辑界面的示意图。
图3是根据一示例性公开实施例示出的一种页面生成装置的框图。
图4是根据一示例性公开实施例示出的一种电子设备的框图。
具体实施方式
下面将参照附图更详细地描述本公开的实施例。虽然附图中显示了本公开的某些实施例,然而应当理解的是,本公开可以通过各种形式来实现,而且不应该被解释为限于这里阐述的实施例,相反提供这些实施例是为了更加透彻和完整地理解本公开。应当理解的是,本公开的附图及实施例仅用于示例性作用,并非用于限制本公开的保护范围。
应当理解,本公开的方法实施方式中记载的各个步骤可以按照不同的顺序执行,和/或并行执行。此外,方法实施方式可以包括附加的步骤和/或省略执行示出的步骤。本公开的范围在此方面不受限制。
本文使用的术语“包括”及其变形是开放性包括,即“包括但不限于”。术语“基于”是“至少部分地基于”。术语“一个实施例”表示“至少一个实施例”;术语“另一实施例”表示“至少一个另外的实施例”;术语“一 些实施例”表示“至少一些实施例”。其他术语的相关定义将在下文描述中给出。
需要注意,本公开中提及的“第一”、“第二”等概念仅用于对不同的装置、模块或单元进行区分,并非用于限定这些装置、模块或单元所执行的功能的顺序或者相互依存关系。
需要注意,本公开中提及的“一个”、“多个”的修饰是示意性而非限制性的,本领域技术人员应当理解,除非在上下文另有明确指出,否则应该理解为“一个或多个”。
本公开实施方式中的多个装置之间所交互的消息或者信息的名称仅用于说明性的目的,而并不是用于对这些消息或信息的范围进行限制。
如上所述,目前的页面文件的编辑方式有两种,一种为直接对页面文件进行编辑,一种为通过编辑器对页面文件进行编辑,在这两种方式中,为了方便用户的编辑,通常将组件名称和项目的内容设置为一致或相关。但是,这两种方式都存在组件的名称和组件的项目内容高度对应的问题,页面在上线后,通过对页面文件的爬取,很容易即可得到各组件对应的项目的信息,导致页面中的信息安全度较低。
图1是根据一示例性公开实施例示出的一种页面生成方法的流程图,如图1所示,所述方法包括:
S11、响应于用户的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容。
其中,该组件名称可以是以项目名称描述的,例如,描述用户名称的组件的组件名称可以为user_name,描述公司名称的组件的组件名称可以为company_name,这样,用户可以通过查找组件名称,快捷地找到需要进行编辑的组件,防止因组件名称混乱而导致的编辑错误。
S12、根据预设的组件名称与组件标识的对应关系,确定所述页面组件 在页面文件中的组件标识。
其中,所述组件标识为不具有文字语义的字符。该组件标识可以是以数字与字母的随机组合而成的字符串,例如,可以定义页面第一位置的页面组件的组件标识为B39sdhoNJu28,并定义页面第二位置的页面组件的组件标识为OIYH279Whuwi3,则在需要对页面第一位置的页面组件的组件内容进行编辑时,可以修改页面文件中用于描述组件标识为B39sdhoNJu28的页面组件的字段,在需要对页面第二位置的页面组件的组件内容进行编辑时,可以修改页面文件中用于描述组件标识为OIYH279Whuwi3的页面组件的字段。这样,页面文件中没有例如user_name或者company_name等具有文字语义的字符构成的项目名称相关的信息,当页面生成后,即使他人对页面文件进行爬取,也无法爬取到具体的项目名称和组件内容的对应关系。
在本公开中,可以通过组件名称和组件标识的对应关系,确定页面组件在页面文件中的组件标识,这样,在用户编辑页面组件之后,可以在页面文件中对该页面组件的组件名称所对应的组件标识的字段进行修改,使得用户对页面组件的修改可以映射到页面文件中,在保证了页面的编辑效率的基础上,达到不在页面文件中留下具有文字意义的组件名称或项目名称的效果,提升页面中的信息安全性。
该预设的组件名称与组件标识的对应关系可以是通过JSON文件的形式存储的,例如,可以使用MapJSON对组件名称和组件标识的映射关系进行描述,例如,该映射关系可以为“公司名称company_name;组件标识:OIYH279Whuwi3”。
举例说明,目前对页面进行编辑时,为了方便用户准确无误地对需要进行编辑的页面组件进行编辑,在页面文件中对于用于描述公司名称这一项目的页面组件以“company_name”进行命名,编辑器获取到对“company_name”的输入操作,即可对页面文件中该字段的内容进行修改,以完成对页面组件 的编辑,这样,当页面生成之后,爬虫程序可以轻松地从页面文件中爬取到“company_name:ABCD”等信息;而在本公开中,当对用于描述公司名称这一项目的页面组件进行编辑时,编辑器可以获取到用户针对“company_name”输入的值,并通过用于查询的JSON文件,查询到“company_name”对应的组件标识为“OIYH279Whuwi3”,并通过对页面文件中“OIYH279Whuwi3”对应的字段进行修改从而完成对页面组件的编辑,这样,页面文件中没有“company_name”相关的描述,即使对该页面文件进行爬取,也只能获得“OIYH279Whuwi3:ABCD”等信息,这样可以使得被爬取到的信息无法直接利用,从而提升了信息安全性。
S13、基于所述组件标识和所述组件内容,修改所述页面文件。
通过组件标识和组件内容,可以将页面文件中用于描述该组件标识对应的页面组件的字段修改为该组件内容,或者在该组件标识对应的页面组件的字段中插入该组件内容对应的引用连接等。
S14、基于所述页面文件生成页面。
通过页面文件渲染可以得到最终的页面,该页面可以为网站页面、应用程序页面、游戏页面等页面。
在一种可能的实施方式中,可以实时的基于页面文件渲染出预览页面。也就是说,可以基于原始的页面文件,生成预览页面,并在基于用户的编辑操作进行了修改后,基于修改后的页面文件,更新所述预览页面。
也就是说,用户一旦进行了编辑操作,该编辑操作都可以实时地通过对修改后的页面文件的渲染进行预览展示,提高了可视化编辑的便捷程度。
在一种可能的实施方式中,所述预览页面中包括用于接收用户编辑操作的编辑控件;响应于用户针对所述预览页面中的编辑控件的点击操作,确定所述编辑控件对应的组件名称;响应于用户针对所述编辑控件的输入操作,确定用户输入的组件内容。
在一种可能的实施方式中,该编辑控件是通过JSON文件的形式配置的,通过用于编辑的JSON文件可以将页面中的组件内容以输入框的形式进行配置,具体地,还可以将输入框配置于预览页面中与输入框对应的页面组件的位置处,用于接收用户对该页面组件的编辑操作。
在S11中的编辑操作可以是通过在项目名称的输入框中输入文本、图片、视频等内容进行的,还可以是通过对编辑控件进行编辑进行的,例如,如图2所示的是一种页面编辑界面的示意图,左侧所示的是针对项目名称的编辑框,右侧所示的是装配有编辑控件的预览页面,通过在左侧或右侧的输入框中输入内容,即可完成对该输入框对应的组件的编辑,在实际使用时,可以仅采用左侧所示的输入框,或者仅采用右侧所示的与组件位置一致的输入框,或者两者结合使用。
在一种可能的实施方式中,基于用户对页面模板的选择操作,确定所述页面模板对应的页面文件和页面编辑文件,其中,所述页面编辑文件包括所述用于接收用户编辑操作的编辑控件。
其中,页面模板还可以包括预览图像,可以将该页面模板对应的页面文件生成的页面的图像作为预览图像,响应于用户对预览图像的点击操作,可以确定用户选择了该预览图像对应的页面模板,从而拉取该页面模板对应的页面编辑文件和页面文件,以供用户通过页面编辑文件提供的编辑控件修改页面中的页面组件,从而得到修改后的页面文件。
在一种可能的实施方式中,还可以获取用户对预览页面中的页面组件的修改操作,并修改所述页面文件中对所述页面组件的描述内容,以使所述页面文件中的所述页面组件与用户的修改操作一致。例如,当用户将预览页面中的某页面组件的尺寸拖拽放大,则可以通过调节控件确定该页面组件的组件名称,并通过组件名称确定组件标识,并修改页面文件中该组件标识对应的页面组件的尺寸以适应该调整。值得说明的是,该调节控件可以是由页面 编辑文件生成的。
在所述修改操作为移动操作的情况下,修改所述页面编辑文件中对所述编辑控件的描述内容,以使所述编辑控件的位置与所述页面组件的位置一致。也就是说,当修改操作为移动操作的情况下,不仅修改页面文件中队页面组件的描述内容,还要修改页面编辑文件中对编辑控件的描述内容,使得编辑控件的位置与修改后的页面组件的位置一致,以免出现编辑控件无法正确接收到针对对应的页面组件的编辑操作。
在一种可能的实施方式中,在完成对页面组件的修改之后,可以将当前的页面文件和页面编辑文件导出,并作为页面模板对应存储,这样可以可视化地调整页面模板,提升页面设计的便利程度。
在一种可能的实施方式中,获取用户对预览页面中的页面组件的添加操作或删除操作;在所述页面文件中添加或删除页面组件,并在所述页面编辑文件中添加或删除编辑控件;在获取到对页面组件的添加操作的情况下,将新增的编辑控件对应的组件名称与新增的页面组件的组件标识作为预设的对应关系存储。
例如,用户在预览页面中的某个位置新增了一个页面组件,则可以在页面文件中随机生成一个组件标识,并增加对该页面组件的位置、样式的描述,并在页面编辑文件中添加针对该页面组件的编辑控件,其中,编辑控件对应的组件名称可以由用户定义或随机生成,并且将该组件名称和组件标识作为预设的对应关系进行存储。
在一种可能的实施方式中,为了进一步提高页面信息的安全性,可以在每次保存新的页面模板时,随机生成字符串,并根据随机生成的字符串更新当前的页面文件中的组件标识,并基于更新后的组件标识,更新所述预设的组件名称与组件标识的对应关系,并将更新后的文件页面和当前的页面编辑文件导出,并作为页面模板对应存储。也就是说,每份新生成的页面文件中, 用于描述同一项目的页面组件的组件标识都可以不同,且每份页面模板中的组件名称和组件标识的对应关系都不相同,这样可以防止由于存储对应关系的文件泄露导致的信息安全度降低的问题,还可以防止他人手动关联了一个页面中的项目名称和组件标识之后套用至其他网页模板导致的其他模板下的网页的信息安全度降低的问题。
通过上述技术方案,通过由不具有文字语义的字符的组件标识在页面文件中区分不同的页面组件,并通过组件名称和组件标识的对应关系,将用户对页面组件的输入内容修改到页面文件中与该页面组件对应的部分,并基于该页面文件生成页面,这样,可以使得用于生成页面的页面文件中的组件名称与项目内容之间的关联性降低,使得他人难以从页面文件中提取到具体的项目信息,从而提高了页面的信息安全性。
图3是根据一示例性公开实施例示出的一种页面生成装置的框图,如图3所示,所述装置300包括:
获取模块310,用于响应于用户的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容。
确定模块320,用于根据预设的组件名称与组件标识的对应关系,确定所述页面组件在页面文件中的组件标识,其中,所述组件标识为不具有文字语义的字符。
修改模块330,用于基于所述组件标识和所述组件内容,修改所述页面文件。
生成模块340,用于基于所述页面文件生成页面。
在一种可能的实施方式中,所述装置还包括预览模块,用于基于原始的页面文件,生成预览页面,并基于修改后的页面文件,更新所述预览页面。
在一种可能的实施方式中,所述预览页面中包括用于接收用户编辑操作 的编辑控件;所述获取模块310,用于响应于用户针对所述预览页面中的编辑控件的点击操作,确定所述编辑控件对应的组件名称,并响应于用户针对所述编辑控件的输入操作,确定用户输入的组件内容。
在一种可能的实施方式中,所述装置还包括选择模块,用于基于用户对页面模板的选择操作,确定所述页面模板对应的页面文件和页面编辑文件,其中,所述页面编辑文件包括所述用于接收用户编辑操作的编辑控件。
在一种可能的实施方式中,所述装置还包括编辑模块,用于获取用户对预览页面中的页面组件的修改操作;修改所述页面文件中对所述页面组件的描述内容,以使所述页面文件中的所述页面组件与用户的修改操作一致;修改所述页面编辑文件中对所述编辑控件的描述内容,以使所述编辑控件的位置与所述页面组件的位置一致;将当前的页面文件和页面编辑文件导出,并作为页面模板对应存储。
在一种可能的实施方式中,所述编辑模块,还用于获取用户对预览页面中的页面组件的添加操作或删除操作;在所述页面文件中添加或删除页面组件,并在所述页面编辑文件中添加或删除编辑控件;在获取到对页面组件的添加操作的情况下,将新增的编辑控件对应的组件名称与新增的页面组件的组件标识作为预设的对应关系存储。
在一种可能的实施方式中,所述编辑模块,还用于随机生成字符串,并根据随机生成的字符串更新当前的页面文件中的组件标识;基于更新后的组件标识,更新所述预设的组件名称与组件标识的对应关系;将更新后的文件页面和当前的页面编辑文件导出,并作为页面模板对应存储。
上述装置中各模块所具体执行的步骤在本公开关于该装置的方法部分的实施例中已经进行详细阐述,在此不做赘述。
通过上述技术方案,通过由不具有文字语义的字符的组件标识在页面文件中区分不同的页面组件,并通过组件名称和组件标识的对应关系,将用户 对页面组件的输入内容修改到页面文件中与该页面组件对应的部分,并基于该页面文件生成页面,这样,可以使得用于生成页面的页面文件中的组件名称与项目内容之间的关联性降低,使得他人难以从页面文件中提取到具体的项目信息,从而提高了页面的信息安全性。
下面参考图4,其示出了适于用来实现本公开实施例的电子设备400的结构示意图。本公开实施例中的终端设备可以包括但不限于诸如移动电话、笔记本电脑、数字广播接收器、PDA(个人数字助理)、PAD(平板电脑)、PMP(便携式多媒体播放器)、车载终端(例如车载导航终端)等等的移动终端以及诸如数字TV、台式计算机等等的固定终端。图4示出的电子设备仅仅是一个示例,不应对本公开实施例的功能和使用范围带来任何限制。
如图4所示,电子设备400可以包括处理装置(例如中央处理器、图形处理器等)401,其可以根据存储在只读存储器(ROM)402中的程序或者从存储装置408加载到随机访问存储器(RAM)403中的程序而执行各种适当的动作和处理。在RAM 403中,还存储有电子设备400操作所需的各种程序和数据。处理装置401、ROM 402以及RAM 403通过总线404彼此相连。输入/输出(I/O)接口405也连接至总线404。
通常,以下装置可以连接至I/O接口405:包括例如触摸屏、触摸板、键盘、鼠标、摄像头、麦克风、加速度计、陀螺仪等的输入装置406;包括例如液晶显示器(LCD)、扬声器、振动器等的输出装置407;包括例如磁带、硬盘等的存储装置408;以及通信装置409。通信装置409可以允许电子设备400与其他设备进行无线或有线通信以交换数据。虽然图4示出了具有各种装置的电子设备400,但是应理解的是,并不要求实施或具备所有示出的装置。可以替代地实施或具备更多或更少的装置。
特别地,根据本公开的实施例,上文参考流程图描述的过程可以被实现 为计算机软件程序。例如,本公开的实施例包括一种计算机程序产品,其包括承载在非暂态计算机可读介质上的计算机程序,该计算机程序包含用于执行流程图所示的方法的程序代码。在这样的实施例中,该计算机程序可以通过通信装置409从网络上被下载和安装,或者从存储装置408被安装,或者从ROM 402被安装。在该计算机程序被处理装置401执行时,执行本公开实施例的方法中限定的上述功能。
需要说明的是,本公开上述的计算机可读介质可以是计算机可读信号介质或者计算机可读存储介质或者是上述两者的任意组合。计算机可读存储介质例如可以是——但不限于——电、磁、光、电磁、红外线、或半导体的系统、装置或器件,或者任意以上的组合。计算机可读存储介质的更具体的例子可以包括但不限于:具有一个或多个导线的电连接、便携式计算机磁盘、硬盘、随机访问存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、光纤、便携式紧凑磁盘只读存储器(CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。在本公开中,计算机可读存储介质可以是任何包含或存储程序的有形介质,该程序可以被指令执行系统、装置或者器件使用或者与其结合使用。而在本公开中,计算机可读信号介质可以包括在基带中或者作为载波一部分传播的数据信号,其中承载了计算机可读的程序代码。这种传播的数据信号可以采用多种形式,包括但不限于电磁信号、光信号或上述的任意合适的组合。计算机可读信号介质还可以是计算机可读存储介质以外的任何计算机可读介质,该计算机可读信号介质可以发送、传播或者传输用于由指令执行系统、装置或者器件使用或者与其结合使用的程序。计算机可读介质上包含的程序代码可以用任何适当的介质传输,包括但不限于:电线、光缆、RF(射频)等等,或者上述的任意合适的组合。
在一些实施方式中,电子设备可以利用诸如HTTP(HyperText Transfer  Protocol,超文本传输协议)之类的任何当前已知或未来研发的网络协议进行通信,并且可以与任意形式或介质的数字数据通信(例如,通信网络)互连。通信网络的示例包括局域网(“LAN”),广域网(“WAN”),网际网(例如,互联网)以及端对端网络(例如,ad hoc端对端网络),以及任何当前已知或未来研发的网络。
上述计算机可读介质可以是上述电子设备中所包含的;也可以是单独存在,而未装配入该电子设备中。
可以以一种或多种程序设计语言或其组合来编写用于执行本公开的操作的计算机程序代码,上述程序设计语言包括但不限于面向对象的程序设计语言—诸如Java、Smalltalk、C++,还包括常规的过程式程序设计语言——诸如“C”语言或类似的程序设计语言。程序代码可以完全地在用户计算机上执行、部分地在用户计算机上执行、作为一个独立的软件包执行、部分在用户计算机上部分在远程计算机上执行、或者完全在远程计算机或服务器上执行。在涉及远程计算机的情形中,远程计算机可以通过任意种类的网络——包括局域网(LAN)或广域网(WAN)——连接到用户计算机,或者,可以连接到外部计算机(例如利用因特网服务提供商来通过因特网连接)。
附图中的流程图和框图,图示了按照本公开各种实施例的系统、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段、或代码的一部分,该模块、程序段、或代码的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。也应当注意,在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个接连地表示的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执行规定的功能或操作的专用的基于硬件的系统 来实现,或者可以用专用硬件与计算机指令的组合来实现。
描述于本公开实施例中所涉及到的模块可以通过软件的方式实现,也可以通过硬件的方式来实现。其中,模块的名称在某种情况下并不构成对该模块本身的限定。
本文中以上描述的功能可以至少部分地由一个或多个硬件逻辑部件来执行。例如,非限制性地,可以使用的示范类型的硬件逻辑部件包括:现场可编程门阵列(FPGA)、专用集成电路(ASIC)、专用标准产品(ASSP)、片上系统(SOC)、复杂可编程逻辑设备(CPLD)等等。
在本公开的上下文中,机器可读介质可以是有形的介质,其可以包含或存储以供指令执行系统、装置或设备使用或与指令执行系统、装置或设备结合地使用的程序。机器可读介质可以是机器可读信号介质或机器可读储存介质。机器可读介质可以包括但不限于电子的、磁性的、光学的、电磁的、红外的、或半导体系统、装置或设备,或者上述内容的任何合适组合。机器可读存储介质的更具体示例会包括基于一个或多个线的电气连接、便携式计算机盘、硬盘、随机存取存储器(RAM)、只读存储器(ROM)、可擦除可编程只读存储器(EPROM或快闪存储器)、光纤、便捷式紧凑盘只读存储器(CD-ROM)、光学储存设备、磁储存设备、或上述内容的任何合适组合。
根据本公开的一个或多个实施例,示例1提供了一种页面生成方法,所述方法包括:响应于用户的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容;根据预设的组件名称与组件标识的对应关系,确定所述页面组件在页面文件中的组件标识,其中,所述组件标识为不具有文字语义的字符;基于所述组件标识和所述组件内容,修改所述页面文件;基于所述页面文件生成页面。
本公开的一个或多个实施例,示例2提供了示例1的方法,所述方法还 包括:基于原始的页面文件,生成预览页面;在基于所述组件标识和所述组件内容,修改所述页面文件之后,所述方法还包括:基于修改后的页面文件,更新所述预览页面。
本公开的一个或多个实施例,示例3提供了示例2的方法,所述预览页面中包括用于接收用户编辑操作的编辑控件;所述响应于用户的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容,包括:响应于用户针对所述预览页面中的编辑控件的点击操作,确定所述编辑控件对应的组件名称;响应于用户针对所述编辑控件的输入操作,确定用户输入的组件内容。
本公开的一个或多个实施例,示例4提供了示例3的方法,所述方法还包括:基于用户对页面模板的选择操作,确定所述页面模板对应的页面文件和页面编辑文件,其中,所述页面编辑文件包括所述用于接收用户编辑操作的编辑控件。
本公开的一个或多个实施例,示例5提供了示例4的方法,所述方法还包括:获取用户对预览页面中的页面组件的修改操作;修改所述页面文件中对所述页面组件的描述内容,以使所述页面文件中的所述页面组件与用户的修改操作一致;在所述修改操作为移动操作的情况下,所述方法还包括:修改所述页面编辑文件中对所述编辑控件的描述内容,以使所述编辑控件的位置与所述页面组件的位置一致;所述方法还包括:将当前的页面文件和页面编辑文件导出,并作为页面模板对应存储。
本公开的一个或多个实施例,示例6提供了示例5的方法,所述获取用户对预览页面中的页面组件的修改操作,还包括:获取用户对预览页面中的页面组件的添加操作或删除操作;所述方法还包括:在所述页面文件中添加或删除页面组件,并在所述页面编辑文件中添加或删除编辑控件;在获取到对页面组件的添加操作的情况下,将新增的编辑控件对应的组件名称与新增 的页面组件的组件标识作为预设的对应关系存储。
本公开的一个或多个实施例,示例7提供了示例5或示例6的方法,所述将当前的页面文件和页面编辑文件导出,并作为页面模板对应存储,包括:随机生成字符串,并根据随机生成的字符串更新当前的页面文件中的组件标识;基于更新后的组件标识,更新所述预设的组件名称与组件标识的对应关系;将更新后的文件页面和当前的页面编辑文件导出,并作为页面模板对应存储。
根据本公开的一个或多个实施例,示例8提供了一种页面生成装置,所述装置包括:获取模块,用于响应于用户的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容;确定模块,用于根据预设的组件名称与组件标识的对应关系,确定所述页面组件在页面文件中的组件标识,其中,所述组件标识为不具有文字语义的字符;修改模块,用于基于所述组件标识和所述组件内容,修改所述页面文件;生成模块,用于基于所述页面文件生成页面。
根据本公开的一个或多个实施例,示例9提供了示例8的装置,所述装置还包括预览模块,用于基于原始的页面文件,生成预览页面,并基于修改后的页面文件,更新所述预览页面。
根据本公开的一个或多个实施例,示例10提供了示例9的装置,所述预览页面中包括用于接收用户编辑操作的编辑控件;所述获取模块,用于响应于用户针对所述预览页面中的编辑控件的点击操作,确定所述编辑控件对应的组件名称,并响应于用户针对所述编辑控件的输入操作,确定用户输入的组件内容。
根据本公开的一个或多个实施例,示例11提供了示例10的装置,所述装置还包括选择模块,用于基于用户对页面模板的选择操作,确定所述页面模板对应的页面文件和页面编辑文件,其中,所述页面编辑文件包括所述用 于接收用户编辑操作的编辑控件。
根据本公开的一个或多个实施例,示例12提供了示例11的装置,所述装置还包括编辑模块,用于获取用户对预览页面中的页面组件的修改操作;修改所述页面文件中对所述页面组件的描述内容,以使所述页面文件中的所述页面组件与用户的修改操作一致;修改所述页面编辑文件中对所述编辑控件的描述内容,以使所述编辑控件的位置与所述页面组件的位置一致;将当前的页面文件和页面编辑文件导出,并作为页面模板对应存储。
根据本公开的一个或多个实施例,示例13提供了示例12的装置,所述编辑模块,还用于获取用户对预览页面中的页面组件的添加操作或删除操作;在所述页面文件中添加或删除页面组件,并在所述页面编辑文件中添加或删除编辑控件;在获取到对页面组件的添加操作的情况下,将新增的编辑控件对应的组件名称与新增的页面组件的组件标识作为预设的对应关系存储。
根据本公开的一个或多个实施例,示例14提供了示例12或示例13的装置,所述编辑模块,还用于随机生成字符串,并根据随机生成的字符串更新当前的页面文件中的组件标识;基于更新后的组件标识,更新所述预设的组件名称与组件标识的对应关系;将更新后的文件页面和当前的页面编辑文件导出,并作为页面模板对应存储。
根据本公开的一个或多个实施例,示例15提供了一种计算机程序,包括:指令,该指令当由处理器执行时使处理器执行示例1至7任一页面生成方法中的一个或多个步骤。
根据本公开的一个或多个实施例,示例16提供了一种计算机程序产品,包括指令,该指令当由处理器执行时使处理器执行示例1至7任一页面生成方法中的一个或多个步骤。
通过上述技术方案,可以通过由不具有文字语义的字符的组件标识在页 面文件中区分不同的页面组件,并通过组件名称和组件标识的对应关系,将用户对页面组件的输入内容修改到页面文件中与该页面组件对应的部分,并基于该页面文件生成页面,这样,可以使得用于生成页面的页面文件中的组件名称与项目内容之间的关联性降低,使得他人难以从页面文件中提取到具体的项目信息,从而提高了页面的信息安全性。
以上描述仅为本公开的较佳实施例以及对所运用技术原理的说明。本领域技术人员应当理解,本公开中所涉及的公开范围,并不限于上述技术特征的特定组合而成的技术方案,同时也应涵盖在不脱离上述公开构思的情况下,由上述技术特征或其等同特征进行任意组合而形成的其它技术方案。例如上述特征与本公开中公开的(但不限于)具有类似功能的技术特征进行互相替换而形成的技术方案。
此外,虽然采用特定次序描绘了各操作,但是这不应当理解为要求这些操作以所示出的特定次序或以顺序次序执行来执行。在一定环境下,多任务和并行处理可能是有利的。同样地,虽然在上面论述中包含了若干具体实现细节,但是这些不应当被解释为对本公开的范围的限制。在单独的实施例的上下文中描述的某些特征还可以组合地实现在单个实施例中。相反地,在单个实施例的上下文中描述的各种特征也可以单独地或以任何合适的子组合的方式实现在多个实施例中。
尽管已经采用特定于结构特征和/或方法逻辑动作的语言描述了本主题,但是应当理解所附权利要求书中所限定的主题未必局限于上面描述的特定特征或动作。相反,上面所描述的特定特征和动作仅仅是实现权利要求书的示例形式。关于上述实施例中的装置,其中各个模块执行操作的具体方式已经在有关该方法的实施例中进行了详细描述,此处将不做详细阐述说明。

Claims (12)

  1. 一种页面生成方法,包括:
    响应于用户的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容;
    根据预设的组件名称与组件标识的对应关系,确定所述页面组件在页面文件中的组件标识,其中,所述组件标识为不具有文字语义的字符;
    基于所述组件标识和所述组件内容,修改所述页面文件;
    基于所述页面文件生成页面。
  2. 根据权利要求1所述的页面生成方法,还包括:
    基于原始的页面文件,生成预览页面;
    在基于所述组件标识和所述组件内容,修改所述页面文件之后,所述页面生成方法还包括:
    基于修改后的页面文件,更新所述预览页面。
  3. 根据权利要求2所述的页面生成方法,其中,所述预览页面中包括用于接收用户编辑操作的编辑控件;
    所述响应于用户的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容,包括:
    响应于用户针对所述预览页面中的编辑控件的点击操作,确定所述编辑控件对应的组件名称;
    响应于用户针对所述编辑控件的输入操作,确定用户输入的组件内容。
  4. 根据权利要求3所述的页面生成方法,还包括:
    基于用户对页面模板的选择操作,确定所述页面模板对应的页面文件和 页面编辑文件,其中,所述页面编辑文件包括所述用于接收用户编辑操作的编辑控件。
  5. 根据权利要求4所述的页面生成方法,还包括:
    获取用户对预览页面中的页面组件的修改操作;
    修改所述页面文件中对所述页面组件的描述内容,以使所述页面文件中的所述页面组件与用户的修改操作一致;
    在所述修改操作为移动操作的情况下,所述页面生成方法还包括:
    修改所述页面编辑文件中对所述编辑控件的描述内容,以使所述编辑控件的位置与所述页面组件的位置一致;
    所述页面生成方法还包括:
    将当前的页面文件和页面编辑文件导出,并作为页面模板对应存储。
  6. 根据权利要求5所述的页面生成方法,其中,所述获取用户对预览页面中的页面组件的修改操作,还包括:
    获取用户对预览页面中的页面组件的添加操作或删除操作;
    所述页面生成方法还包括:
    在所述页面文件中添加或删除页面组件,并在所述页面编辑文件中添加或删除编辑控件;
    在获取到对页面组件的添加操作的情况下,将新增的编辑控件对应的组件名称与新增的页面组件的组件标识作为预设的对应关系存储。
  7. 根据权利要求5或6所述的页面生成方法,其中,所述将当前的页面文件和页面编辑文件导出,并作为页面模板对应存储,包括:
    随机生成字符串,并根据随机生成的字符串更新当前的页面文件中的组 件标识;
    基于更新后的组件标识,更新所述预设的组件名称与组件标识的对应关系;
    将更新后的文件页面和当前的页面编辑文件导出,并作为页面模板对应存储。
  8. 一种页面生成装置,包括:
    获取模块,用于响应于用户的编辑操作,确定用户编辑的页面组件的组件名称,及用户针对该页面组件输入的组件内容;
    确定模块,用于根据预设的组件名称与组件标识的对应关系,确定所述页面组件在页面文件中的组件标识,其中,所述组件标识为不具有文字语义的字符;
    修改模块,用于基于所述组件标识和所述组件内容,修改所述页面文件;
    生成模块,用于基于所述页面文件生成页面。
  9. 一种计算机可读介质,其上存储有计算机程序,该程序被处理装置执行时实现权利要求1-7中任一项所述的页面生成方法中的一个或多个步骤。
  10. 一种电子设备,包括:
    存储装置,其上存储有计算机程序;
    处理装置,用于执行所述存储装置中的所述计算机程序,以实现权利要求1-7中任一项所述的页面生成方法中的一个或多个步骤。
  11. 一种计算机程序,包括:
    指令,所述指令当由处理器执行时使所述处理器执行根据权利要求1-7中任一项所述的页面生成方法中的一个或多个步骤。
  12. 一种计算机程序产品,包括指令,所述指令当由处理器执行时使所述处理器执行根据权利要求1-7中任一项所述的页面生成方法中的一个或多个步骤。
PCT/CN2021/133209 2020-11-26 2021-11-25 页面生成方法和装置、存储介质和电子设备 WO2022111591A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011356170.5 2020-11-26
CN202011356170.5A CN112487331A (zh) 2020-11-26 2020-11-26 页面生成方法和装置、存储介质和电子设备

Publications (1)

Publication Number Publication Date
WO2022111591A1 true WO2022111591A1 (zh) 2022-06-02

Family

ID=74936043

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/133209 WO2022111591A1 (zh) 2020-11-26 2021-11-25 页面生成方法和装置、存储介质和电子设备

Country Status (2)

Country Link
CN (1) CN112487331A (zh)
WO (1) WO2022111591A1 (zh)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115437535A (zh) * 2022-11-08 2022-12-06 北京德风新征程科技有限公司 针对烟草制丝车间的数据处理方法、装置、设备与介质
CN117669529A (zh) * 2024-02-01 2024-03-08 腾讯科技(深圳)有限公司 数据处理方法、装置、设备以及介质

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112487331A (zh) * 2020-11-26 2021-03-12 北京有竹居网络技术有限公司 页面生成方法和装置、存储介质和电子设备
CN113282863B (zh) * 2021-06-11 2023-04-21 上海哔哩哔哩科技有限公司 业务页面生成方法及装置
CN113419992B (zh) * 2021-06-22 2024-02-20 北京金山云网络技术有限公司 文件清除配置页面展示方法、装置、电子设备和介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110289546A1 (en) * 2010-05-19 2011-11-24 International Business Machines Corporation Method and apparatus for protecting markup language document against cross-site scripting attack
CN108132942A (zh) * 2016-11-30 2018-06-08 北京国双科技有限公司 一种页面生成方法及终端
CN111488546A (zh) * 2020-04-13 2020-08-04 北京小米移动软件有限公司 一种页面生成方法、装置及存储介质
CN111783006A (zh) * 2020-07-22 2020-10-16 网易(杭州)网络有限公司 页面的生成方法、装置、电子设备及计算机可读介质
CN112487331A (zh) * 2020-11-26 2021-03-12 北京有竹居网络技术有限公司 页面生成方法和装置、存储介质和电子设备

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7680758B2 (en) * 2004-09-30 2010-03-16 Citrix Systems, Inc. Method and apparatus for isolating execution of software applications
US8875099B2 (en) * 2011-12-22 2014-10-28 International Business Machines Corporation Managing symbolic links in documentation
CN106201489A (zh) * 2016-06-30 2016-12-07 乐视控股(北京)有限公司 一种页面编辑方法和装置
CN108255847B (zh) * 2016-12-28 2021-03-26 腾讯科技(深圳)有限公司 页面生成方法及装置
CN108572821A (zh) * 2018-04-11 2018-09-25 连向辉 用户界面代码的生成方法和插件
CN109582297A (zh) * 2018-11-08 2019-04-05 北京达佳互联信息技术有限公司 一种代码模板的生成方法、装置、电子设备及存储介质
CN109614568B (zh) * 2018-12-07 2023-04-14 微梦创科网络科技(中国)有限公司 一种页面生成方法及装置

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110289546A1 (en) * 2010-05-19 2011-11-24 International Business Machines Corporation Method and apparatus for protecting markup language document against cross-site scripting attack
CN108132942A (zh) * 2016-11-30 2018-06-08 北京国双科技有限公司 一种页面生成方法及终端
CN111488546A (zh) * 2020-04-13 2020-08-04 北京小米移动软件有限公司 一种页面生成方法、装置及存储介质
CN111783006A (zh) * 2020-07-22 2020-10-16 网易(杭州)网络有限公司 页面的生成方法、装置、电子设备及计算机可读介质
CN112487331A (zh) * 2020-11-26 2021-03-12 北京有竹居网络技术有限公司 页面生成方法和装置、存储介质和电子设备

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115437535A (zh) * 2022-11-08 2022-12-06 北京德风新征程科技有限公司 针对烟草制丝车间的数据处理方法、装置、设备与介质
CN115437535B (zh) * 2022-11-08 2023-09-12 北京德风新征程科技股份有限公司 针对烟草制丝车间的数据处理方法、装置、设备与介质
CN117669529A (zh) * 2024-02-01 2024-03-08 腾讯科技(深圳)有限公司 数据处理方法、装置、设备以及介质
CN117669529B (zh) * 2024-02-01 2024-04-30 腾讯科技(深圳)有限公司 数据处理方法、装置、设备以及介质

Also Published As

Publication number Publication date
CN112487331A (zh) 2021-03-12

Similar Documents

Publication Publication Date Title
WO2022111591A1 (zh) 页面生成方法和装置、存储介质和电子设备
WO2020119485A1 (zh) 一种页面显示方法、装置、设备及存储介质
US11418592B2 (en) Uploading user and system data from a source location to a destination location
WO2022218034A1 (zh) 交互方法、装置和电子设备
WO2022127838A1 (zh) 文档处理方法、装置和电子设备
CN110096665B (zh) 图片类评论数据的展示方法、装置、设备及介质
CN111400625B (zh) 页面处理方法、装置、电子设备及计算机可读存储介质
CN110781658B (zh) 简历解析方法、装置、电子设备和存储介质
WO2022233311A1 (zh) 展示方法、装置和电子设备
WO2022184034A1 (zh) 一种文档处理方法、装置、设备和介质
WO2022184077A1 (zh) 文档编辑的方法、装置、终端及非暂时性存储介质
CN114356962A (zh) 一种数据查询方法、装置、电子设备和存储介质
WO2023160578A1 (zh) 信息处理方法、装置、终端和存储介质
CN115344688B (zh) 业务数据展示方法、装置、电子设备和计算机可读介质
CN111124541A (zh) 一种配置文件的生成方法、装置、设备及介质
US9965484B1 (en) Template-driven data extraction and insertion
CN110780898B (zh) 页面数据的升级方法、装置和电子设备
CN111753238A (zh) 数据映射方法、装置和电子设备
CN115422131B (zh) 业务审核知识库检索方法、装置、设备和计算机可读介质
CN111399902B (zh) 客户端源文件处理方法、装置、可读介质与电子设备
WO2022184037A1 (zh) 文档处理方法、装置、设备和介质
CN111026983B (zh) 一种实现超链接的方法、装置、介质和电子设备
CN115994151B (zh) 数据请求变更方法、装置、电子设备和计算机可读介质
CN113760834B (zh) 文件分类方法、装置、设备及介质
WO2022184048A1 (zh) 文档标签的生成方法、装置、终端和存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21897091

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21897091

Country of ref document: EP

Kind code of ref document: A1