CN110781418A - Webpage text editing method and device based on URL identification and storage medium - Google Patents

Webpage text editing method and device based on URL identification and storage medium Download PDF

Info

Publication number
CN110781418A
CN110781418A CN201810854256.7A CN201810854256A CN110781418A CN 110781418 A CN110781418 A CN 110781418A CN 201810854256 A CN201810854256 A CN 201810854256A CN 110781418 A CN110781418 A CN 110781418A
Authority
CN
China
Prior art keywords
template
url
editing
identification
text
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.)
Pending
Application number
CN201810854256.7A
Other languages
Chinese (zh)
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.)
Shanghai Bilibili Technology Co Ltd
Original Assignee
Shanghai Bilibili Technology 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 Shanghai Bilibili Technology Co Ltd filed Critical Shanghai Bilibili Technology Co Ltd
Priority to CN201810854256.7A priority Critical patent/CN110781418A/en
Publication of CN110781418A publication Critical patent/CN110781418A/en
Pending legal-status Critical Current

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

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention relates to a webpage text editing method, a webpage text editing device and a webpage text editing storage medium based on URL identification, and belongs to the technical field of the Internet. The method comprises the following steps: reading a URL link in a webpage text; identifying the type of the URL link, and calling a corresponding template; displaying the content corresponding to the URL link according to the template format; the device comprises a processor and a memory, wherein the memory is stored with a computer program, and when the computer program is executed by the processor, the method for editing the webpage text based on the URL identification is realized; the medium is stored with a computer program, and the computer program realizes the webpage text editing method based on URL identification when being executed by a processor. Compared with the prior art, the invention has the advantages of convenient editing, strong automation performance, wide application range and the like.

Description

Webpage text editing method and device based on URL identification and storage medium
Technical Field
The invention relates to the technical field of internet, in particular to the application field of editors, and specifically relates to a webpage text editing method and device based on URL identification and a storage medium.
Background
With the rapid development of internet technology, it is a very common popularization means to edit contents to be published on a web platform through an editor. In order to expand the popularization range and increase the popularization strength, when the edited content is released, the same content is often edited on a plurality of different platforms respectively.
In order to simplify the complexity of editing, for the same content, the current partial editor can identify the content of the link by inserting the link, so as to directly display the content on the current webpage text. However, because the displayed contents are different in category, corresponding editing is often required according to the format of the current editor in order to ensure the display effect, and therefore, in the existing editor, in the process of inserting links, corresponding links need to be copied through a fixed entry so as to display various types of contents, which is tedious and has a poor coverage. This undoubtedly increases the complexity of editing the web page text, resulting in waste of time and cost.
Disclosure of Invention
The invention aims to provide a webpage text editing method, a webpage text editing device and a webpage text editing storage medium based on URL identification.
The purpose of the invention can be realized by the following technical scheme:
a method for editing text of a web page based on URL identification, the method comprising the steps of:
(1) reading a URL link in a webpage text;
(2) identifying the type of the URL link, and calling a corresponding template;
(3) and displaying the content corresponding to the URL link according to the template format.
Preferably, the step (2) specifically comprises: and calling a template matched with the website type according to the website type corresponding to the URL link.
Preferably, the step (2) specifically comprises: and identifying according to the prefix and the parameters in the URL link, and calling the template matched with the identification result.
Preferably, the step (2) further comprises: and when the type of the URL link is identified to be failed, calling the corresponding template according to the selection result of the manual template editing option.
Preferably, the step (3) specifically comprises the following steps:
(31) reading the content corresponding to the URL link;
(32) and displaying the read content after the read content is distributed according to the template format.
Preferably, the step (31) specifically comprises: and scanning the page corresponding to the URL link, and reading the content contained in the page.
Preferably, said step (32) comprises in particular: and according to the type of the URL link, capturing a valid field in the read content, and displaying the valid field at a position corresponding to the template.
Preferably, the templates include a goods template, a video template, an audio template, a picture template, an article template, a topic template, and a ticket template.
A webpage text editing device based on URL identification comprises a processor and a memory, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the webpage text editing device realizes any one of the webpage text editing methods based on URL identification.
A computer-readable storage medium, on which a computer program is stored, which, when executed by a processor, implements the method for editing text of a web page identified based on a URL according to any one of the above.
Compared with the prior art, the invention has the following beneficial effects:
(1) according to the method provided by the invention, when the URL link is inserted into the webpage text, the type of the URL link is identified, and the type of the URL link is determined, so that the template matched with the content of the link can be called according to the identification result, and the corresponding content is displayed.
(2) When the URL is identified, the URL can be identified according to the website type corresponding to the link, the prefix and the parameter of the URL link, the identification mode is selected automatically according to the actual situation, the identification is flexible, and the application range of the method is expanded.
(3) When the URL link type identification fails, the corresponding template can be selected through manual editing, so that the editing flexibility is improved, and the editing accuracy is guaranteed.
(4) When the content of the URL link is displayed according to the template format, the content corresponding to the link is scanned at first, and then the content is displayed according to the automatic layout of the template format, so that the automation degree of editing is further improved, and the editing time of a user is saved.
Drawings
FIG. 1 is a flowchart illustrating steps of a method for editing text in a web page based on URL identification according to the present invention;
FIG. 2 is a schematic diagram of a page in which text editing of a web page is performed by URL identification in the embodiment;
FIG. 3 is a schematic diagram of a display in which various types of templates are assembled.
Detailed Description
In order to clearly understand the technical contents of the present invention, the following examples are given in detail.
Please refer to fig. 1, which is a flowchart illustrating a method for editing web page text based on URL identification according to the present invention.
In one embodiment, the method for editing the text of the webpage based on the URL identification comprises the following steps:
(1) reading a URL link in a webpage text;
(2) identifying the type of the URL link, and calling a corresponding template;
(3) and displaying the content corresponding to the URL link according to the template format.
Wherein, the step (2) specifically comprises the following steps: and calling a template matched with the website type according to the website type corresponding to the URL link, or carrying out identification according to the prefix and the parameters in the URL link and calling the template matched with the identification result. Besides, the step (2) further comprises: and when the type of the URL link is identified to be failed, calling the corresponding template according to the selection result of the manual template editing option.
The step (3) specifically comprises the following steps:
(31) reading the content corresponding to the URL link;
(32) and displaying the read content after the read content is distributed according to the template format.
In the above step, the step (31) specifically includes: and scanning the page corresponding to the URL link, and reading the content contained in the page. The step (32) specifically comprises: and according to the type of the URL link, capturing a valid field in the read content, and displaying the valid field at a position corresponding to the template.
In the method, the templates comprise a commodity template, a video template, an audio template, a picture template, an article template, a topic template and a ticket template.
In addition, the embodiment further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements any one of the above methods for editing web page text based on URL identification; the webpage text editing device based on URL identification comprises a processor and a memory, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the webpage text editing device realizes any one of the webpage text editing methods based on URL identification.
In practical applications, a specific implementation manner of the web page text editing method based on URL identification of the present invention is described by the following embodiments.
Example 1
In this embodiment, the user may input the URL link in the web page text of the editor by copying the paste or manually inputting, and when the editor reads the URL link in the web page text, the editor determines the type of the URL link by classifying the domain name and identifying the content in the domain name, thereby invoking the template to be presented. Two methods are used for identifying URL links, one is that a template matched with the type of a website is selected according to the type of the website corresponding to URL link through the classification of the existing symbolic websites (such as mainstream websites of Taobao, Amazon and the like, which can be classified into commodity websites, and in addition, ticket type websites or American image type websites and the like); or the type corresponding to the link is judged by identifying the prefix of the URL link, the parameters in the URL link and the like, so that the corresponding template is called. As shown in fig. 2, in this embodiment, the URL link explicitly indicates that the website is a mainstream website of bilibili, so that it is determined that the link corresponds to a website of a video class, and a template adapted to the video is called.
After the corresponding template is selected, the editor starts to further analyze and identify the URL link, specifically, the editor scans the page content corresponding to the URL link to obtain the content information and content description contained in the page, and after the content is obtained, corresponding fields are captured from the content according to the requirements of the template and displayed in the position of the template to be displayed, so that the editing of the webpage text is completed. The templates are shown in fig. 3, and as can be seen from fig. 3, there are many types of templates, including articles/novels, american, video, drama/tv, movie, audio, merchandise, ticket, and event/other types, each having a unique display format. In this embodiment, as shown in fig. 2, after the video template is called, the editor reads the content in the page corresponding to the link, captures the content such as the video title, the video content, the video introduction, the playing information, and the like in the page according to the template requirement, and displays the captured result at the position corresponding to the template, thereby completing the operation of inserting the video into the web text and displaying the video.
In the actual operation process, when the type of the URL link is identified, the situation of identification failure is easy to occur, the template cannot be called at this time, and the situation that the template is not matched may also be found when the content in the URL link is captured according to the template format.
Example 2
The interface display process in this embodiment is basically the same as the case and flow of embodiment 1, except that in this embodiment, the website is determined to be a panning website by identifying a prefix of a URL link, and thus a corresponding commodity template is called. After the commodity template is determined to be called, the editor acquires commodity title and commodity picture information through a page corresponding to the preview URL link, captures the part of contents, fills the part of contents into a corresponding module of the template, finishes webpage editing and displays the webpage. The process is otherwise identical to that of example 1.
In this specification, the invention has been described with reference to specific embodiments thereof. It will, however, be evident that various modifications and changes may be made thereto without departing from the broader spirit and scope of the invention. The specification and drawings are, accordingly, to be regarded in an illustrative rather than a restrictive sense.

Claims (10)

1. A webpage text editing method based on URL identification is characterized by comprising the following steps:
(1) reading a URL link in a webpage text;
(2) identifying the type of the URL link, and calling a corresponding template;
(3) and displaying the content corresponding to the URL link according to the template format.
2. The method for editing text on a web page based on URL identification as claimed in claim 1, wherein the step (2) specifically comprises: and calling a template matched with the website type according to the website type corresponding to the URL link.
3. The method for editing text on a web page based on URL identification as claimed in claim 1, wherein the step (2) specifically comprises: and identifying according to the prefix and the parameters in the URL link, and calling the template matched with the identification result.
4. The method for editing text on a web page based on URL identification as claimed in claim 1, wherein the step (2) further comprises: and when the type of the URL link is identified to be failed, calling the corresponding template according to the selection result of the manual template editing option.
5. The method for editing text on a web page based on URL identification as claimed in claim 1, wherein the step (3) specifically comprises the following steps:
(31) reading the content corresponding to the URL link;
(32) and displaying the read content after the read content is distributed according to the template format.
6. The method for editing text on a web page based on URL identification as claimed in claim 5, wherein the step (31) specifically comprises: and scanning the page corresponding to the URL link, and reading the content contained in the page.
7. The method for editing text on a web page identified based on a URL as claimed in claim 5, wherein the step (32) specifically comprises: and according to the type of the URL link, capturing a valid field in the read content, and displaying the valid field at a position corresponding to the template.
8. The method for editing text on a web page based on URL identification as claimed in claim 1, wherein the template includes a goods template, a video template, an audio template, a picture template, an article template, a topic template and a ticket template.
9. A device for editing web page text based on URL identification, comprising a processor and a memory, wherein the memory stores a computer program, and the computer program is used for implementing the method for editing web page text based on URL identification according to any one of claims 1 to 8 when being executed by the processor.
10. A computer-readable storage medium, on which a computer program is stored, the computer program, when being executed by a processor, implementing a method for editing text of a web page identified based on a URL according to any one of claims 1 to 8.
CN201810854256.7A 2018-07-30 2018-07-30 Webpage text editing method and device based on URL identification and storage medium Pending CN110781418A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810854256.7A CN110781418A (en) 2018-07-30 2018-07-30 Webpage text editing method and device based on URL identification and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810854256.7A CN110781418A (en) 2018-07-30 2018-07-30 Webpage text editing method and device based on URL identification and storage medium

Publications (1)

Publication Number Publication Date
CN110781418A true CN110781418A (en) 2020-02-11

Family

ID=69382656

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810854256.7A Pending CN110781418A (en) 2018-07-30 2018-07-30 Webpage text editing method and device based on URL identification and storage medium

Country Status (1)

Country Link
CN (1) CN110781418A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111597805A (en) * 2020-05-21 2020-08-28 上海创蓝文化传播有限公司 Method and device for auditing short message text links based on deep learning
WO2021196281A1 (en) * 2020-03-30 2021-10-07 北京金堤科技有限公司 Multimedia file generation method and apparatus, storage medium and electronic device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040019849A1 (en) * 2002-07-19 2004-01-29 Jen-Hwang Weng Method and system for providing online web page editing
CN102567337A (en) * 2010-12-15 2012-07-11 盛乐信息技术(上海)有限公司 Method and system for quickly recognizing webpage types through links
CN105550165A (en) * 2015-12-23 2016-05-04 深圳市八零年代网络科技有限公司 Plug-in and method capable of importing webpage article into webpage text editor
CN106095743A (en) * 2016-06-21 2016-11-09 武汉斗鱼网络科技有限公司 A kind of RichText Edition method and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040019849A1 (en) * 2002-07-19 2004-01-29 Jen-Hwang Weng Method and system for providing online web page editing
CN102567337A (en) * 2010-12-15 2012-07-11 盛乐信息技术(上海)有限公司 Method and system for quickly recognizing webpage types through links
CN105550165A (en) * 2015-12-23 2016-05-04 深圳市八零年代网络科技有限公司 Plug-in and method capable of importing webpage article into webpage text editor
CN106095743A (en) * 2016-06-21 2016-11-09 武汉斗鱼网络科技有限公司 A kind of RichText Edition method and device

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
信息技术教材编写委员会: "《综合实践活动信息技术八年级》", 30 June 2013, 北京理工大学出版社 *
黑面: "《单反龙之卷主题摄影实践攻略第2版》", 31 December 2014, 中国青年出版社 *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021196281A1 (en) * 2020-03-30 2021-10-07 北京金堤科技有限公司 Multimedia file generation method and apparatus, storage medium and electronic device
CN111597805A (en) * 2020-05-21 2020-08-28 上海创蓝文化传播有限公司 Method and device for auditing short message text links based on deep learning
CN111597805B (en) * 2020-05-21 2021-01-05 上海创蓝文化传播有限公司 Method and device for auditing short message text links based on deep learning

Similar Documents

Publication Publication Date Title
US20120060087A1 (en) System and method for converting an existing website into a mobile compatible website
CN107888978B (en) KEY code burning method and device and computer readable storage medium
US20100211865A1 (en) Cross-browser page visualization generation
US20160062963A1 (en) Synchronizing DOM Element References
CN108259620B (en) Advertisement editing and previewing method, intelligent terminal, system and storage device
CN106201489A (en) A kind of page editing method and apparatus
CN104834753A (en) Webpage screenshot generating method and device
US20150227276A1 (en) Method and system for providing an interactive user guide on a webpage
US20090094579A1 (en) Method and software for editing web documents
CN106804011B (en) Method and system for loading subtitle file during video playing
CN105786969A (en) Information display method and apparatus
CN112417338B (en) Page adaptation method, system and equipment
CN110968314B (en) Page generation method and device
CN104144357A (en) Video playing method and system
CN103514271A (en) Method and device for providing thumbnail image corresponding to webpage content
CN106294413A (en) The loading method of picture and device
CN104573001A (en) Mobile terminal-based webpage data acqusition and classification method
CN110781418A (en) Webpage text editing method and device based on URL identification and storage medium
US10606935B2 (en) Transforming a website for dynamic web content management
CN110619103A (en) Webpage image-text detection method and device and storage medium
US20150161160A1 (en) Application Localization
CN104899203B (en) Webpage generation method and device and terminal equipment
CN112882933A (en) Script recording method, device, equipment and storage medium
CN103514272A (en) Method and device for providing thumbnail corresponding to webpage content
CN113286196A (en) Vehicle-mounted video playing system and video split-screen display method and device

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