CN114911534A - Page information extraction method, setting method, device, electronic equipment and medium - Google Patents

Page information extraction method, setting method, device, electronic equipment and medium Download PDF

Info

Publication number
CN114911534A
CN114911534A CN202110181055.7A CN202110181055A CN114911534A CN 114911534 A CN114911534 A CN 114911534A CN 202110181055 A CN202110181055 A CN 202110181055A CN 114911534 A CN114911534 A CN 114911534A
Authority
CN
China
Prior art keywords
page information
page
target
template
tag
Prior art date
Legal status (The legal status 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 status listed.)
Granted
Application number
CN202110181055.7A
Other languages
Chinese (zh)
Other versions
CN114911534B (en
Inventor
吴郑燕
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Uniview Technologies Co Ltd
Original Assignee
Zhejiang Uniview Technologies Co Ltd
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 Zhejiang Uniview Technologies Co Ltd filed Critical Zhejiang Uniview Technologies Co Ltd
Priority to CN202110181055.7A priority Critical patent/CN114911534B/en
Publication of CN114911534A publication Critical patent/CN114911534A/en
Application granted granted Critical
Publication of CN114911534B publication Critical patent/CN114911534B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • 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/451Execution arrangements for user interfaces
    • 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/957Browsing optimisation, e.g. caching or content distillation
    • 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/44505Configuring for program initiating, e.g. using registry, configuration files
    • G06F9/4451User profiles; Roaming
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

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

Abstract

The embodiment of the application discloses a page information extraction method, a setting device, electronic equipment and a medium. The method comprises the following steps: determining a target label from labels contained in a target page area of a display page; extracting page information corresponding to the target label according to the label code of the target label; and generating a page information template corresponding to the target page area according to the page information so as to import the page information to be set into the page to be set for page information setting. According to the scheme, the page information corresponding to the target label in the target page area is automatically extracted, and the page information template is generated to be directly imported, so that the problems that repeated input and copying and pasting are complex in the page information setting process and the fixed initial information template cannot be flexibly changed are solved, the customized generation of the page information template is realized, the form of the page information template is enriched, the subsequent page information setting can be conveniently and directly imported, and the page information setting efficiency is improved.

Description

Page information extraction method, setting method, device, electronic equipment and medium
Technical Field
The embodiment of the application relates to the technical field of computers, in particular to a page information extraction method, a setting device, electronic equipment and a medium.
Background
In the operation process of data input and the like at the web page side, for example, in the process of adding equipment to a management platform website, the process generally includes displaying parameter information to be input, including information such as an equipment name, an equipment model and equipment parameters, by popping up a page, and adding the parameter information to the equipment by a user.
When the parameter information to be input is large, the parameter information needs to be input repeatedly every time a new device is added. Some entries are regularly circulated, for example, only the last few characters need to be changed, and each repeated entry results in a cumbersome entry process. If newly added data is opened and copied and pasted, the copying and pasting process is complicated under the condition that more parameter information needs to be input. If a set of initial values is set for the page configuration item, the initial values are generally fixed and are difficult to flexibly change according to different conditions, so that the setting of the parameter information is difficult to efficiently and quickly complete.
Disclosure of Invention
The embodiment of the application provides a page information extraction method, a setting device, electronic equipment and a medium, so as to improve the efficiency of setting page information.
In one embodiment, an embodiment of the present application provides a page information extraction method, including:
determining a target label from labels contained in a target page area of a display page;
extracting page information corresponding to the target label according to the label code of the target label;
and generating a page information template corresponding to the target page area according to the page information so as to import the page to be set for setting the page information.
In another embodiment, an embodiment of the present application provides a page information setting method, including:
selecting a target page information template from the page information templates;
leading the target page information template into a to-be-set area of a to-be-set page;
setting page information of the page to be set according to the page information in the target page information template;
the page information template is determined based on the page information extraction method in any one of the above embodiments.
In an embodiment, an embodiment of the present application further provides a page information extracting apparatus, where the apparatus includes:
the target tag is a determining module, which is used for determining a target tag from tags contained in a target page area of the display page;
the page information extraction module is used for extracting page information corresponding to the target tag according to the tag code of the target tag;
and the page information template generating module is used for generating a page information template corresponding to the target page area according to the page information so as to import the page information to be set into the page to be set for page information setting.
In another embodiment, an embodiment of the present application further provides a page information setting apparatus, where the apparatus includes:
the selection module is used for selecting a target page information template from the page information templates;
the importing module is used for importing the target page information template into a to-be-set area of a to-be-set page;
the setting module is used for setting the page information of the page to be set according to the page information in the target page information template;
the page information template is determined based on the page information extraction method in any one of the above embodiments.
In another embodiment, an embodiment of the present application further provides an electronic device, including: one or more processors;
a memory for storing one or more programs;
when the one or more programs are executed by the one or more processors, the one or more processors implement the page information extraction method provided in any embodiment of the present application, or implement the page information setting method provided in any embodiment of the present application.
In yet another embodiment, an embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored, where the computer program is executed by a processor, and the page information extracting method provided in any embodiment of the present application is provided, or the page information setting method provided in any embodiment of the present application is implemented.
One of the above technical solutions has the following technical effects: determining a target label from labels contained in a target page area of a display page; extracting page information corresponding to the target label according to the label code of the target label; according to the page information, a page information template corresponding to the target page area is generated to lead in the page to be set for setting the page information, so that the problems that repeated input and copying and pasting are complicated in the page information setting process and a fixed initial information template cannot be flexibly changed are solved, the custom customization generation of the page information template is realized, the form of the page information template is enriched, the subsequent page information can be conveniently and directly led in during setting, and the page information setting efficiency is improved.
Drawings
Fig. 1 is a flowchart of a page information extraction method according to an embodiment of the present application;
fig. 2 is a schematic view of a display page for extracting page information according to an embodiment of the present application;
fig. 3 is a flowchart of a page information extraction method according to another embodiment of the present application;
fig. 4 is a flowchart of a page information setting method according to an embodiment of the present application;
fig. 5 is a schematic diagram of a page to be set according to page information setting provided in an embodiment of the present application;
fig. 6 is a schematic structural diagram of a page information extraction apparatus according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of a page information setting apparatus according to an embodiment of the present application;
fig. 8 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
The present application will be described in further detail with reference to the following drawings and examples.
Fig. 1 is a flowchart of a page information extraction method according to an embodiment of the present application. The page information extraction method provided by the embodiment of the application can be suitable for the situation that the page information in the target page area of the display page is extracted to generate the page information template. The method may be specifically executed by a page information extraction apparatus, which may be implemented by software and/or hardware, and may be integrated in an electronic device capable of implementing the page information extraction method. Referring to fig. 1, the method of the embodiment of the present application specifically includes:
s110, determining a target label from labels contained in a target page area of the display page.
The display page may be a page for displaying information. The display page may be, for example, a web page in a browser, a page in a software application, a page on a management system, and so forth. The tag is an element for displaying page information, and may be an html tag, for example. The display page in the embodiment of the application is a page which is developed and displayed. In the display page, a tag for displaying information has been assigned. The target page area is an area to be subjected to subsequent operations selected from the display page, and may be a whole area of the display page or a partial area of the display page, and the specific selection mode may be intercepting according to preset position information and size information of the target display area, or determined according to a circling operation of a user. The target label is determined from all labels, can be all labels or part of labels, is specifically set according to actual conditions, can be determined according to the attribute name and the attribute value of the label, and can also be selected in a personalized way.
Illustratively, in the target page area, multiple tags may be contained. It may not be necessary for page information corresponding to all tags to be extracted for generating the page information template. For example, the page information corresponding to a possible partial tag is not reusable information and is not suitable for generating the page information template. Alternatively, the partial tags may not include the page information required to generate the page information template. Therefore, the target tag can be determined from tags included in the target page area to generate the page information template.
In the embodiment of the present application, the process of determining the target page area includes: identifying a region selection operation acted on a display page by a user; and determining a target page area from the display page according to the area selection operation.
Illustratively, the user may perform the region selection operation on the display page by clicking or by circling the crop box. And identifying the area selection operation of the user on the display page, and determining the area selected by the user according to the area selection operation to be used as a target page area. As shown in fig. 2, the user may circle a target page area in the dashed line frame, and extract page information in the target page area in a targeted manner.
And S120, extracting page information corresponding to the target label according to the label code of the target label.
The label code may be a code segment corresponding to the target label. When the label code of the target label is programmed, page information displayed by the target label is programmed into the label code. Therefore, the page information corresponding to the target tag can be extracted according to the tag code of the target tag.
S130, according to the page information, generating a page information template corresponding to the target page area so as to import the page to be set for page information setting.
The specific form of the page information template can be set according to actual conditions. For example, the page information may be stored in a form of a table, and a page information template corresponding to the target page area is obtained. The page information can also be stored in a document form to obtain a page information template corresponding to the target page area. The page information template can be called, so that the page information template is directly imported into a page to be set, and page information setting is carried out.
Illustratively, a user can manually select a page information template, and the page information template is imported into a page to be set for setting page information. And when the page to be set exists, automatically selecting a page information template according to the matching result of the page to be set and the target page area, and importing the page information template into the page to be set for page information setting.
In this embodiment of the present application, generating a page information template corresponding to the target page area according to the page information includes: and binding the page information template with a triggerable label in the display page, so as to call the page information template through the triggerable label.
For example, the generated page information template may be bound with a triggerable tag, so that when a user triggers the triggerable tag, the page information template corresponding to the triggerable tag is called, and the page information is directly imported into the page to be set to set the page information. The triggerable label can be a draggable label, the user can click and drag the draggable label to a to-be-set area of a to-be-set page, so that a page information template bound by the draggable label is guided into the to-be-set area, page information setting is carried out on the to-be-set area, page information does not need to be input again or copied and pasted, the user can freely select the page information template to be dragged and guided, the page information template is richer, and the problem that a fixed initial value is difficult to flexibly change is solved.
According to the scheme in the embodiment of the application, the target label is determined from the labels contained in the target page area of the display page; extracting page information corresponding to the target label according to the label code of the target label; therefore, the page information in the target page area can be extracted in a targeted manner, the page information template corresponding to the target page area is generated according to the page information, the page information is set in the imported page to be set, the page information template corresponding to the target page area is generated in a customized manner, the problems that repeated input, copying and pasting are complicated in the page information setting process and the fixed initial information template cannot be flexibly changed are solved, the user-defined customized generation of the page information template is realized, the form of the page information template is enriched, the page information template can be directly imported during subsequent page information setting, and the page information setting efficiency is improved.
In an embodiment of the present application, the method further includes: and packaging the page information extraction method into a code frame which can be called so as to realize method multiplexing.
Illustratively, the method for extracting the page information provided by the embodiment of the application can also be integrated into a JavaScript library to implement the implementation of the above scheme, so that different webpages can load the JavaScript library conveniently, the method in the JavaScript library is directly called through a data interface to realize the extraction of the page information and the direct calling of the page information template, and the method can be conveniently and flexibly applied to other webpages.
Fig. 3 is a flowchart of a page information extraction method according to another embodiment of the present application. In order to further optimize the embodiments, details which are not described in detail in the embodiments of the present application are described in the embodiments. Referring to fig. 3, the method for extracting page information provided in the embodiment of the present application may include:
s210, selecting a target attribute identification with a mapping relation from the attribute identifications of the page tags.
The attribute identifier of the page tag is used to indicate the uniqueness of the attribute of the page tag, and the attribute generally appears in the form of an attribute name/attribute value, for example: the name is "value", and the attribute is typically the content following the tag name in the start tag. There may be a plurality of attributes of the page tag. For page tags, not all attributes need to be assigned. In addition, all attributes and attribute values of the page tag do not need to be extracted, some attributes may not be required by the user, or the attribute values may not be reused as a template, so that a target attribute identifier having a mapping relationship may be selected from the attribute identifiers of the page tag in a targeted manner, so as to extract the attribute name and the attribute value associated with the target attribute identifier in a targeted manner. The target attribute identifier having the mapping relationship may be an identifier capable of representing an attribute name and an attribute value, for example, a target attribute identifier id and a value of a selected page tag are selected, so that the attribute name and the attribute value of the page information are correspondingly extracted.
And S220, in the development process of the display page, respectively associating the target attribute identification with the attribute name and the attribute value configured for the page tag.
The attribute name and the attribute value configured for the page tag may be the attribute value set by the user according to the actual situation, for example, the device name and the specific content set by the user for the device to be added, and the set device name and the specific content need to be displayed in the display page. In the development process of the display page, the target attribute identification is associated with the attribute name and the attribute value configured for the page tag, so that the attribute name and the attribute value associated with the target attribute identification are locked by searching the target attribute identification.
Illustratively, for a target attribute identifier id, if a user assigns a value of "softName" to the target attribute identifier id, the target attribute identifier id and an attribute name softName are associated, and for a target attribute identifier value, if the user assigns a value of "Notis _ Android-R2021" to the target attribute identifier value, the target attribute identifier value and the attribute name Notis _ Android-R2021 are associated, so that the attribute name and the attribute value associated with the target attribute can be found through the target attribute in the following process.
It should be noted that, the above-mentioned scheme may be performed once before performing the subsequent steps in the embodiment of the present application each time, or may be performed only once, and then the subsequent steps in the embodiment of the present application are performed multiple times.
And S230, traversing the tags contained in the target page area.
Illustratively, when extracting the page information, the tags included in the target page area need to be completely traversed and identified, so as to completely and fully search and acquire the required page information. The traversed tags may be text tags (e.g., Input, textarea tags), table tags (e.g., table tags), picture tags (e.g., img tags), and so forth.
And S240, if the attribute name and the attribute value are associated with the target attribute identifier of the label, taking the label as the target label.
Illustratively, the target attribute identifier corresponds to an attribute selected by the user and can be used for generating the page information template, so that the target attribute identifier is searched in a targeted manner. If the target attribute identification of the existing label is associated with the attribute name and the attribute value, the attribute of the label is assigned, and the assigned label is taken as the target label.
Specifically, for example, if the target attribute identifier is id and value, the tags included in the target page area are traversed, and it is determined that the tags of the target attribute identifier id and the target attribute identifier value exist. For a tag having a target attribute identifier id and a target attribute identifier value, whether an attribute name and an attribute value are associated is determined, for example, id is associated with an attribute name softName, and value is associated with an attribute value Notis _ Android-R2021. And if the target attribute identification id and the target attribute identification value of the tag are associated with the attribute name and the attribute value, determining the tag as the target tag so as to perform targeted subsequent processing on the target tag and extract page information according to the content contained in the target tag.
And S250, extracting the attribute name and the attribute value associated with the target attribute identifier of the target tag according to the tag code of the target tag so as to generate a page information template.
Illustratively, for the tag to be assigned, the target attribute identifier is already assigned in the tag code, so that the attribute name and the attribute value associated with the target attribute identifier of the target tag can be extracted from the tag code of the target tag, and thus the page information template can be generated by comprehensively and accurately reflecting the attribute name and the attribute value associated with the target attribute identifier of the target tag of the page information.
Specifically, for example, for the tag code of the target tag: and extracting target attribute identification id and an associated attribute name softName, target attribute identification value and an associated attribute value Notis _ Android-R2021 from < textarea id ' value ' Notis _ Android-R2021 ', thereby extracting page information for generating the template.
S260, locally storing the attribute name and the attribute value associated with the target attribute identifier of the target tag in the page information as an object array, and using the object array as a page information template corresponding to the target page area.
For example, the attribute name and the attribute value associated with the target attribute identifier may be stored as an object array, so as to facilitate corresponding storage and management of the attribute name and the attribute value associated with the target attribute identifier. In the embodiment of the application, the object array is locally stored, for example, the object array is stored in a global variable, a localStorage, a sessionstorage and the like in a browser, where localStorage is a database for directly storing data to be local and is equivalent to a database for a page. sessionstore is used to temporarily store the data of a page, and the stored data is deleted after the page is closed. The technical scheme has the advantages that the page information template is directly stored locally and does not need to be transmitted to a server, so that the safety of the page information template is improved, and the page information template is prevented from being illegally stolen.
And S270, visually displaying the page information template.
Illustratively, the page information template may be visually displayed on a display page or other display areas, so that the generated page information template is displayed for the user, and the user can conveniently select to import and use the page information template. For the visually displayed page information template, the page information template can be imported into the page to be set according to the operation of a user or automatic operation, and the attribute name and the attribute value associated with the target attribute identifier in the page information template are assigned to the corresponding label in the page to be set. The visual display form can be set according to the actual conditions.
In an embodiment of the present application, visually displaying the page information template includes: and assigning the attribute name and the attribute value associated with the target attribute identifier of the target tag in the page information to a display tag of the display page, so that the page information template is displayed on the display page through the display tag.
The display tag may be a tag capable of displaying the attribute name and the attribute value associated with the target attribute identifier, for example, a table tag, a text tag, and the like, and is used for visually displaying the attribute name and the attribute value associated with the target attribute identifier. And assigning the attribute name and the attribute value associated with the target attribute identifier to a display tag of the display page, so that the page information template is displayed on the display page through the display tag, a user can conveniently and intuitively determine the generated page information template, and the user can conveniently and directly select a required page information template from the displayed page information templates for importing and using. As shown in fig. 2, the attribute name corresponding to the target attribute identifier id and the attribute value corresponding to the target attribute identifier value are displayed in a table form on the display page, so that the user can conveniently view and select the attribute name and the attribute value, and the required page information template is determined.
Another technical scheme in the technical scheme has the following technical effects: the target attribute identification with the mapping relation is selected and bound with the attribute name and the attribute value, and the attribute name and the attribute value associated with the target attribute identification are extracted, so that page information is extracted from a target page area in a targeted manner, page information required by a user is obtained, and a page information template is convenient to generate. Through the visual display of the page information template, a user can conveniently and visually determine the generated page information template, so that the page information setting can be directly called and imported, the efficiency of the page information setting is improved, and the operation of the user is facilitated.
Fig. 4 is a flowchart of a page information setting method according to an embodiment of the present application. The page information setting method provided by the embodiment of the application can be suitable for setting the page information. Typically, the page information setting method in the embodiment of the present application may be applied to the case of setting page information based on a page information template. The method may be specifically executed by a page information setting apparatus, which may be implemented by software and/or hardware, and may be integrated in an electronic device capable of implementing the page information setting method. For details which are not described in detail in the examples of the present application, reference is made to the above-mentioned examples. Referring to fig. 4, the method of the embodiment of the present application specifically includes:
s310, selecting a target page information template from the page information templates.
The page information template is determined based on the page information extraction method in any one of the above embodiments.
The page information template can be displayed on the page to be set or other pages so as to be convenient for the user to view. Selecting the target page information template from the page information templates can select the target page information template for the operation of identifying the user, or automatically select the target page information template according to the information of the position, the size and the like of the area to be set of the page to be set.
In the embodiment of the present application, selecting a target page information template from page information templates includes: and if the triggering operation of the user on the visually displayed page information template is detected, determining a target page information template bound by the triggerable label triggered by the user, and calling the target page information template.
For example, the page information template may be presented on a page to be set or other page. The page information template displayed visually can be bound with the triggerable label, when a user performs trigger operation on the triggerable label, such as clicking selection, dragging and the like, the target page information template bound with the triggerable label is determined according to the triggerable label triggered by the user, and the page information template is called, so that information is directly filled into a to-be-set area of a to-be-set page according to the target page information template, and page information setting is performed. The draggable label is arranged and bound with the page information template, so that a user can directly select and import the target page information template by dragging the draggable label, the operation of the user is facilitated, and the target page information template is directly imported. As shown in fig. 5, the user may perform a trigger operation on the displayed page information template, so as to directly select and call the target page information template through the trigger operation.
In the embodiment of the application, at least two visually displayed page information templates are provided; correspondingly, the step of selecting the target page information template from the page information templates comprises the following steps: and selecting the same or different target page information templates from at least two visually displayed page information templates aiming at different areas to be set in the page to be set.
Illustratively, at least two page information templates may be presented in FIG. 5. When a user sets information in at least two different areas to be set on a page to be set, the same target page information template can be selected from the at least two page information templates and imported into the at least two different areas to be set for information setting. Or different target page information templates can be selected from the at least two page information templates and respectively imported into at least two different areas to be set to set information. By the aid of the scheme, the page to be set is automatically set by leading in the target page information templates, information setting efficiency is improved, and operation of a user is facilitated.
And S320, importing the target page information template into a to-be-set area of a to-be-set page.
Illustratively, the target page information template comprises the page information for setting the area to be set, so that the target page information template is led into the area to be set of the page to be set, the page information can be directly set for the area to be set through the page information in the target page information template, repeated filling or copying and pasting are not needed, a fixed initial template is not needed, and the page information template can be flexibly selected for setting the page information.
In this embodiment of the present application, importing the target page information template into a to-be-set area of a to-be-set page includes: determining the area to be set according to a target operation area defined by the trigger operation; and importing the target page information template into the area to be set.
For example, a user may perform a trigger operation on a page to be set, and determine a region to be set according to a target operation region defined by the trigger operation. For example, the user may circle the target operation region on the page to be set, and take the target operation region as the region to be set. The user can also drag the draggable label, and the target operation area dragged by the draggable label is used as the area to be set, so that the page information in the area to be set is set in a targeted mode, and the flexibility of regional page information setting is improved.
In the embodiment of the application, the triggerable label is a draggable label, and the triggering operation is a dragging operation; correspondingly, determining the area to be set according to the target operation area defined by the trigger operation comprises the following steps: and determining a region to be set associated with the target point according to the target point to which the dragging operation is carried out.
For example, the user may preset a corresponding relationship between a point and an area in the page to be set, for example, a circular area within a preset radius range with a point as a center of a circle is used as an area corresponding to the point. Or, a rectangular area with a point as the center and a preset diagonal length is used as the area corresponding to the point. Dragging the draggable label to a target point, and determining a preset area corresponding to the target point, namely the area to be set.
S330, setting page information of the page to be set according to the page information in the target page information template.
Illustratively, the page information in the target page information template can be directly filled into the corresponding position of the page to be set, so that the automatic setting of the page information of the page to be set is realized, manual input and setting are not needed, the automatic setting is realized, and the operation of a user is facilitated.
In this embodiment of the present application, performing page information setting on the page to be set according to the page information in the target page information template includes: determining an attribute name and an attribute value associated with a target attribute identifier of a target tag contained in the page information according to the page information in the target page information template; and determining a page tag matched with the attribute name in the area to be set, and assigning an attribute value corresponding to the attribute name to the page tag.
Specifically, the attribute name in the target page information template can be matched with the attribute name of the page tag in the region to be set according to the target attribute identifier in the target page information template, and if the matching is successful, the attribute value corresponding to the attribute name in the target page information template is assigned to the page tag, so that the page information setting of the page to be set is realized.
For example, as shown in fig. 5, a user may select and drag a target page information template in a right page information template, and drag the target page information template into a left to-be-set area, where an attribute name corresponding to a device name in the to-be-set area is softName and is consistent with the attribute name softName in the target page information template, and assign an attribute value Notis _ Android-R2021 corresponding to the softName in the target page information template to a value of a page tag corresponding to the device name in the to-be-set area, so that Notis _ Android-R2021 is automatically filled in a text input area corresponding to the device name in the to-be-set area, and automatic filling of page information is achieved.
One of the above technical solutions has the following technical effects: the target page information template is selected from the page information templates, the target information template is guided into the to-be-set area of the to-be-set page, and page information setting is carried out on the to-be-set page according to the page information in the target page information template, so that automatic guiding-in setting of the page information is achieved, the problem that manual filling and copying and pasting processes are complicated is solved, and information setting efficiency is improved. And the page information template has various forms and can be reused, so that the flexibility of the page information template is improved.
Fig. 6 is a schematic structural diagram of a page information extraction apparatus according to an embodiment of the present application. The device can be applied to the condition of extracting the page information in the target page area of the display page to generate the page information template. The apparatus may be implemented by software and/or hardware, and the apparatus may be integrated in an electronic device. Referring to fig. 6, the apparatus specifically includes:
a target tag determination module 410, configured to determine a target tag from tags included in a target page area of a display page;
a page information extraction module 420, configured to extract, according to the tag code of the target tag, page information corresponding to the target tag;
the page information template generating module 430 is configured to generate a page information template corresponding to the target page area according to the page information, so as to import the page information into a page to be set for setting the page information.
In an embodiment of the present application, the apparatus further includes:
the target attribute selection module is used for selecting a target attribute identifier with a mapping relation from the attribute identifiers of the page tags;
and the association module is used for associating the target attribute identification with the attribute name and the attribute value configured aiming at the page label respectively in the development process of displaying the page.
In an embodiment of the present application, the target tag determining module 410 includes:
the traversing unit is used for traversing the labels contained in the target page area;
and the determining unit is used for taking the label as the target label if the target attribute identification of the label is associated with the attribute name and the attribute value.
In this embodiment, the page information extracting module 420 includes:
and the searching unit is used for extracting the attribute name and the attribute value associated with the target attribute identifier of the target label according to the label code of the target label so as to generate the page information template.
In an embodiment of the present application, the apparatus further includes:
the identification module is used for identifying the region selection operation acted on the display page by the user;
and the region determining module is used for determining a target page region from the display page according to the region selection operation.
In this embodiment, the page information template generating module 430 includes:
the storage unit is used for locally storing the attribute name and the attribute value associated with the target attribute identifier of the target tag in the page information as an object array as a page information template corresponding to the target page area;
and the display unit is used for visually displaying the page information template.
In an embodiment of the present application, the display unit is specifically configured to:
and assigning the attribute name and the attribute value associated with the target attribute identifier of the target tag in the page information to a display tag of the display page, so that the page information template is displayed on the display page through the display tag.
In this embodiment of the present application, the page information template generating module 430 includes:
and the binding unit is used for binding the page information template with the triggerable label in the display page so as to call the page information template through the triggerable label.
In an embodiment of the present application, the apparatus further includes:
and the packaging module is used for packaging the page information extraction method into a code frame which can be called so as to realize method multiplexing.
The page information extraction device provided by the embodiment of the application can execute the page information extraction method provided by any embodiment of the application, and has the corresponding functional modules and beneficial effects of the execution method.
Fig. 7 is a schematic structural diagram of a page information extraction apparatus according to an embodiment of the present application. The device is applicable to the situation of setting page information. Typically, the page information setting method in the embodiment of the present application may be applied to the case of setting page information based on a page information template. The apparatus may be implemented by software and/or hardware, and the apparatus may be integrated in an electronic device. Referring to fig. 7, the apparatus may include:
a selecting module 510, configured to select a target page information template from the page information templates;
the importing module 520 is configured to import the target page information template into a to-be-set area of a to-be-set page;
a setting module 530, configured to perform page information setting on the page to be set according to the page information in the target page information template;
the page information template is generated based on the page information extraction method provided by any one of the above embodiments.
In this embodiment, the template determining module 510 includes:
the detection unit is used for determining a target page information template bound by a triggerable label triggered by a user and calling the target page information template if the triggering operation of the user on the visually displayed page information template is detected.
In this embodiment, the importing module 520 includes:
a to-be-set region determining unit, configured to determine the to-be-set region according to a target operation region defined by the trigger operation;
and the template leading-in unit is used for leading the target page information template into the area to be set.
In the embodiment of the application, at least two visually displayed page information templates are provided;
accordingly, the selecting module 510 is specifically configured to:
selecting the same or different target page information templates from at least two visually displayed page information templates aiming at different areas to be set in a page to be set;
in the embodiment of the application, the triggerable label is a draggable label, and the triggering operation is a dragging operation;
correspondingly, the to-be-set region determining unit is specifically configured to:
and determining a region to be set associated with the target point according to the target point to which the dragging operation is carried out.
In this embodiment, the setting module 530 includes:
the attribute information determining unit is used for determining an attribute name and an attribute value associated with a target attribute identifier of a target tag contained in the page information according to the page information in the target page information template;
and the assignment unit is used for determining a page label matched with the attribute name in the area to be set and assigning the attribute value corresponding to the attribute name to the page label.
The page information setting device provided by the embodiment of the application can execute the page information setting method provided by any embodiment of the application, and has the corresponding functional modules and beneficial effects of the execution method.
Fig. 8 is a schematic structural diagram of an electronic device according to an embodiment of the present application. FIG. 8 illustrates a block diagram of an exemplary electronic device 612 suitable for use in implementing embodiments of the present application. The electronic device 612 shown in fig. 8 is only an example, and should not bring any limitation to the functions and the scope of the application of the embodiments.
As shown in fig. 8, the electronic device 612 may include: one or more processors 616; a memory 628 configured to store one or more programs, when the one or more programs are executed by the one or more processors 616, so that the one or more processors 616 implement the method for extracting page information provided in the embodiment of the present application, including:
determining a target label from labels contained in a target page area of a display page;
extracting page information corresponding to the target label according to the label code of the target label;
and generating a page information template corresponding to the target page area according to the page information so as to import the page to be set for setting the page information.
Or the method for setting the page information provided by the embodiment of the application is realized, and comprises the following steps:
selecting a target page information template from the page information templates;
importing the target page information template into a to-be-set area of a to-be-set page;
setting page information of the page to be set according to the page information in the target page information template;
the page information template is generated based on the page information extraction method provided by any one of the above embodiments.
The components of the electronic device 612 may include, but are not limited to: one or more processors or processors 616, a memory 628, and a bus 618 that connects the various device components (including the memory 628 and the processors 616).
Bus 618 represents one or more of any of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, and a processor or local bus using any of a variety of bus architectures. By way of example, such architectures include, but are not limited to, Industry Standard Architecture (ISA) bus, micro-channel architecture (MAC) bus, enhanced ISA bus, Video Electronics Standards Association (VESA) local bus, and Peripheral Component Interconnect (PCI) bus.
The electronic device 612 typically includes a variety of computer device-readable storage media. These storage media may be any available storage media that can be accessed by the electronic device 612 and includes both volatile and nonvolatile storage media, removable and non-removable storage media.
The memory 628 may include computer device readable storage media in the form of volatile memory, such as Random Access Memory (RAM)630 and/or cache memory 632. The electronic device 612 may further include other removable/non-removable, volatile/nonvolatile computer device storage media. By way of example only, storage system 634 may be used to read from and write to non-removable, nonvolatile magnetic storage media (not shown in FIG. 8, and commonly referred to as a "hard drive"). Although not shown in FIG. 8, a magnetic disk drive for reading from and writing to a removable, nonvolatile magnetic disk (e.g., a "floppy disk") and an optical disk drive for reading from or writing to a removable, nonvolatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical storage medium) may be provided. In such cases, each drive may be connected to bus 618 by one or more data storage media interfaces. Memory 628 may include at least one program product having a set (e.g., at least one) of program modules that are configured to carry out the functions of embodiments of the application.
A program/utility 640 having a set (at least one) of program modules 642 may be stored, for example, in memory 628, such program modules 642 including, but not limited to, an operating device, one or more application programs, other program modules, and program data, each of which examples or some combination thereof may comprise an implementation of a network environment. Program modules 642 generally perform the functions and/or methods of the embodiments described herein.
The electronic device 612 may also communicate with one or more external devices 614 (e.g., keyboard, pointing device, display 624, etc.), one or more devices that enable a user to interact with the electronic device 612, and/or any devices (e.g., network card, modem, etc.) that enable the electronic device 612 to communicate with one or more other computing devices. Such communication may occur through input/output (I/O) interfaces 622. Also, the electronic device 612 may 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 the network adapter 620. As shown in FIG. 8, the network adapter 620 communicates with the other modules of the electronic device 612 via the bus 618. It should be appreciated that although not shown in FIG. 8, other hardware and/or software modules may be used in conjunction with the electronic device 612, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID devices, tape drives, and data backup storage devices, among others.
The processor 616 executes at least one of the other programs stored in the memory 628, so as to execute various functional applications and data processing, for example, implement a page information extraction method provided by the embodiment of the present application.
One embodiment of the present application provides a storage medium containing computer-executable instructions that when executed by a computer processor perform a method of page information extraction, comprising:
determining a target label from labels contained in a target page area of a display page;
extracting page information corresponding to the target label according to the label code of the target label;
and generating a page information template corresponding to the target page area according to the page information so as to import the page to be set for setting the page information.
Or the method for executing page information setting comprises the following steps:
selecting a target page information template from the page information templates;
leading the target page information template into a to-be-set area of a to-be-set page;
setting page information of the page to be set according to the page information in the target page information template;
the page information template is generated based on the page information extraction method provided by any one of the above embodiments.
The computer storage media of the embodiments of the present application may take any combination of one or more computer-readable storage media. The computer readable storage medium may be a computer readable signal storage medium or a computer readable storage medium. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor device, apparatus, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, 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 disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In embodiments of the present application, a computer readable storage medium may be any tangible storage medium that can contain, or store a program for use by or in connection with an instruction execution apparatus, device, or apparatus.
A computer readable signal storage medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal storage medium may also be any computer readable storage medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution apparatus, device, or apparatus.
Program code embodied on a computer readable storage medium may be transmitted using any appropriate storage medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Computer program code for carrying out operations for aspects of the present application may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + +, and conventional procedural programming languages, such as the "C" programming 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 device. In the latter scenario, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
It is to be noted that the foregoing is only illustrative of the preferred embodiments of the present application and the technical principles employed. It will be understood by those skilled in the art that the present application is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the application. Therefore, although the present application has been described in more detail with reference to the above embodiments, the present application is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present application, and the scope of the present application is determined by the scope of the appended claims.

Claims (10)

1. A method for extracting page information is characterized by comprising the following steps:
determining a target label from labels contained in a target page area of a display page;
extracting page information corresponding to the target label according to the label code of the target label;
and generating a page information template corresponding to the target page area according to the page information so as to import the page to be set for setting the page information.
2. The method of claim 1, wherein before determining the target tab from the tabs contained in the target page area of the display page, the method further comprises:
selecting a target attribute identifier with a mapping relation from the attribute identifiers of the page tags;
and in the development process of displaying the page, associating the target attribute identification with the attribute name and the attribute value configured aiming at the page tag respectively.
3. The method according to claim 1 or 2, wherein extracting page information corresponding to the target tag according to the tag code of the target tag comprises:
and extracting the attribute name and the attribute value associated with the target attribute identifier of the target tag according to the tag code of the target tag so as to generate a page information template.
4. The method according to claim 1, wherein generating a page information template corresponding to the target page area according to the page information comprises:
and binding the page information template with a triggerable label in the display page, so as to call the page information template through the triggerable label.
5. A page information setting method is characterized by comprising the following steps:
selecting a target page information template from the page information templates;
leading the target page information template into a to-be-set area of a to-be-set page;
setting page information of the page to be set according to the page information in the target page information template;
wherein the page information template is determined based on the page information extraction method of any one of claims 1 to 4.
6. The method of claim 5, wherein selecting the target page information template from the page information templates comprises:
if the triggering operation of a user on the visually displayed page information template is detected, determining a target page information template bound with a triggerable tag triggered by the user, and calling the target page information template;
selecting the same or different target page information templates from at least two visually displayed page information templates aiming at different areas to be set in a page to be set;
according to the page information in the target page information template, performing page information setting on the page to be set, including:
determining an attribute name and an attribute value associated with a target attribute identifier of a target tag contained in the page information according to the page information in the target page information template;
and in the area to be set, determining a page tag matched with the attribute name, and assigning an attribute value corresponding to the attribute name to the page tag.
7. An apparatus for extracting page information, the apparatus comprising:
the target tag is a determining module, which is used for determining a target tag from tags contained in a target page area of the display page;
the page information extraction module is used for extracting page information corresponding to the target tag according to the tag code of the target tag;
and the page information template generating module is used for generating a page information template corresponding to the target page area according to the page information so as to import the page information to be set into the page to be set for page information setting.
8. A page information setting apparatus, characterized in that the apparatus comprises:
the selection module is used for selecting a target page information template from the page information templates;
the importing module is used for importing the target page information template into a to-be-set area of a to-be-set page;
the setting module is used for setting the page information of the page to be set according to the page information in the target page information template;
wherein the page information template is determined based on the page information extraction method of any one of claims 1 to 4.
9. An electronic device, characterized in that the electronic device comprises:
one or more processors;
a memory for storing one or more programs;
when executed by the one or more processors, cause the one or more processors to implement the page information extraction method of any one of claims 1-4, or implement the page information setting method of claim 5 or 6.
10. A computer-readable storage medium on which a computer program is stored, the program realizing the page information extracting method of any one of claims 1 to 4 or the page information setting method of claim 5 or 6 when executed by a processor.
CN202110181055.7A 2021-02-09 2021-02-09 Page information extraction method, setting method, device, electronic equipment and medium Active CN114911534B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110181055.7A CN114911534B (en) 2021-02-09 2021-02-09 Page information extraction method, setting method, device, electronic equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110181055.7A CN114911534B (en) 2021-02-09 2021-02-09 Page information extraction method, setting method, device, electronic equipment and medium

Publications (2)

Publication Number Publication Date
CN114911534A true CN114911534A (en) 2022-08-16
CN114911534B CN114911534B (en) 2024-02-20

Family

ID=82761003

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110181055.7A Active CN114911534B (en) 2021-02-09 2021-02-09 Page information extraction method, setting method, device, electronic equipment and medium

Country Status (1)

Country Link
CN (1) CN114911534B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102279862A (en) * 2011-05-10 2011-12-14 中兴通讯股份有限公司 Data processing device and method based on Ajax
CN109840083A (en) * 2018-12-27 2019-06-04 杭州亚信云信息科技有限公司 Web pages component template construction method, device, computer equipment and storage medium
CN110297999A (en) * 2019-05-09 2019-10-01 京东方科技集团股份有限公司 A kind of web page template generation method and device, webpage loading method and front-end server and Website server
CN110879937A (en) * 2019-10-12 2020-03-13 平安国际智慧城市科技股份有限公司 Method and device for generating webpage from document, computer equipment and storage medium
CN110941784A (en) * 2019-11-13 2020-03-31 北京三快在线科技有限公司 Page generation method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102279862A (en) * 2011-05-10 2011-12-14 中兴通讯股份有限公司 Data processing device and method based on Ajax
CN109840083A (en) * 2018-12-27 2019-06-04 杭州亚信云信息科技有限公司 Web pages component template construction method, device, computer equipment and storage medium
CN110297999A (en) * 2019-05-09 2019-10-01 京东方科技集团股份有限公司 A kind of web page template generation method and device, webpage loading method and front-end server and Website server
CN110879937A (en) * 2019-10-12 2020-03-13 平安国际智慧城市科技股份有限公司 Method and device for generating webpage from document, computer equipment and storage medium
CN110941784A (en) * 2019-11-13 2020-03-31 北京三快在线科技有限公司 Page generation method and device

Also Published As

Publication number Publication date
CN114911534B (en) 2024-02-20

Similar Documents

Publication Publication Date Title
US20190243848A1 (en) Generating a structured document guiding view
CN105868166B (en) Regular expression generation method and system
CN108427731B (en) Page code processing method and device, terminal equipment and medium
CN110955428A (en) Page display method and device, electronic equipment and medium
CN106919711B (en) Method and device for labeling information based on artificial intelligence
CN107391561B (en) Advertisement processing method in content source page, server and computer readable medium
CN111796809A (en) Interface document generation method and device, electronic equipment and medium
CN111797351A (en) Page data management method and device, electronic equipment and medium
CN107592334A (en) A kind of information popularization method, apparatus and equipment
CN114416667A (en) Method and device for rapidly sharing network disk file, network disk and storage medium
CN110955481A (en) Label task generation method and device, storage medium and electronic equipment
US20160328110A1 (en) Method, system, equipment and device for identifying image based on image
CN110659210A (en) Information acquisition method and device, electronic equipment and storage medium
CN115599386A (en) Code generation method, device, equipment and storage medium
CN105808630B (en) Android application auditing method and device
CN110321504B (en) Page processing method and device
CN113360106B (en) Webpage printing method and device
US9898467B1 (en) System for data normalization
CN110716804A (en) Method and device for automatically deleting useless resources, storage medium and electronic equipment
CN113869789A (en) Risk monitoring method and device, computer equipment and storage medium
CN113760894A (en) Data calling method and device, electronic equipment and storage medium
US10140278B2 (en) Computer-implemented methods and systems for associating files with cells of a collaborative spreadsheet
CN114911534B (en) Page information extraction method, setting method, device, electronic equipment and medium
CN108628909B (en) Information pushing method and device
CN112528189B (en) Data-based component packaging method and device, computer equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant