How to deal with the keyword and description of the page, the program automatically retrieves the body from other websites, then saves it as an html file, and how to obtain the keyword information in the body, replacing the keyword and Description content on the static page is troublesome. Try regular expression extraction and replacement. what is the keyword information in the body ?, Word Segmentation. if you want to get a keyword that can replace keywo, how can you process the page?
News class, the program automatically obtains the body from other websites, and then saves it as an html file, how to obtain the keyword information in the body, replacing the keyword and Description content in the static page
------ Solution --------------------
Troublesome. Try regular expression extraction and replacement.
------ Solution --------------------
What is the keyword information in the body?
------ Solution --------------------
Word Segmentation
------ Solution --------------------
To obtain data that can replace the keyword content, you must extract keywords from the database,
The data storage format is similar to the parent-child relationship between Forum partitions and posts.
However, the question is how to generate keywords.
I think there are two ways to generate keywords:
1. manually submit
That is, when submitting a news report, there is a keyword bar where you can manually enter the required keywords.
2. automatically generate the information based on the content when submitting the news
Extracting keywords from an article is a tedious operation, usually called word segmentation, and is also one of the key technologies of search engines.
It is impossible to extract data. There are two types:
2.1 automatically input when submitting news
When submitting news, you can use JavaScript to extract keywords from the content. of course, if the content is too long, the extraction time will also be longer.
However, it takes a little longer to submit the content, which usually does not affect the operation quality of the UI. In addition, the specific step to be analyzed can be determined based on the situation.
2.2 automatic background program generation
In short, it is to use a background program to analyze news content, then automatically generate keyword information, and save it to the database.
DZ Forum Keyword extraction is the combination of Method 1 and 2.1.
Lz can select a method that suits its needs.
------ Solution --------------------
Word segmentation, very troublesome
Mainly word segmentation and word frequency statistics
Intelligent Text retrieval and Keyword extraction
You can develop search engines and intelligent translation systems if you can.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service