How to extract articles from html files?

mareks

Power Member
Joined
Sep 23, 2013
Messages
568
Reaction score
254
Hi!

I am looking for over half day for method/software which can extract articles from custom html files. I have couple sites in HTML and I want put articles from them to new Wordpress sites. So I just need get articles from each page in .txt format and get rid of any html tags...

Any ideas or maybe there is software for that? ohh and yes, html files are on my computer...

Thank You!
 
Last edited:
:1: or just double click the html files so it open in browser then copy paste
 
You can mass edit those articles in notepad++. Use regex to replace everything between "<" to ">".
I'm not entirely sure about this, but if you have Adobe Dreamweaver, you can get the website to display using the software and then try to copy the articles from there.
Just like any webrowser then? xD
 
You can mass edit those articles in notepad++. Use regex to replace everything between "<" to ">".

Just like any webrowser then? xD

Yeah, I have used notepad++ for mass edit, but I am looking for more automated method :) ;)

I need smart extractor which can get me .txt files just with title and body of article, so I can mass post wp sites...
 
Last edited:
Yeah, I have used notepad++ for mass edit, but I am looking for more automated method :) ;)

I need smart extractor which can get me .txt files just with title and body of article, so I can mass post wp sites...
I figured there was more to your question that what you mentioned in your original post.

There's a program called BoilerPipe that extracts the articles from the website, although I don't believe they have a bulk option.

Another program called Purifyr does something similar, although it ma not have a bulk option as well.

I do not know of any programs which can scrape mass articles from the pages and then create text documents for them, although I'll let you know if I find any.
 
I can make you a software that extracts the articles from html files.
Grab all the text (text, no html tags) between <body> and </body> or <div> depending on how the website's source looks like :)
If you're still looking, let me know.
 
I figured there was more to your question that what you mentioned in your original post.

There's a program called BoilerPipe that extracts the articles from the website, although I don't believe they have a bulk option.

Another program called Purifyr does something similar, although it ma not have a bulk option as well.

I do not know of any programs which can scrape mass articles from the pages and then create text documents for them, although I'll let you know if I find any.

Thank You very much! Yeah I didn't said what I tried, sorry :D

Try this,



There are other tools and online converters you can use too.

Thank You very much! ;) I will test it. :)


-------------------------------------------------------

Right now best what I got was with notepad++ and CMD commands. But I will post if I will get better results with any other method/soft. ;)
 
Okay, update:

Tried convertor html to txt, good idea, but needs more custom visual code analysis, like check which tags to keep, so tags used around articles are kept with articles. Then it will work, didn't found any software which can do like that.

Checked Purifyr and Boilerpipe, also doesn't solve this. So notepad++ and CMD commands is the best way to go, or make custom soft... But there is no point right now for custom software, at least for me.

If You know good converter which can understand which tags to keep in html, then it will solve everything, but please only for multiple files, i have a lot pages... ;)

Thank You all!
 
A few more to try, 2 are paid programs that offer a free trial:

Thank You buddy!

sourceforge .net/projects/html2text/ - not working
jafsoft .com/detagger/ - works but just strip tags, leaving unnecessary text.
softinterface .com/Convert-Doc/Features/Convert-HTML-To-TEXT.htm - just converts.

I think only way to automate it and make it simple, is to make soft... :) Will get coder make software when there will be bigger need, I will be fine with notepad++ right now... ;)

Thank You very much for help!
 
Take a look at this site:
Code:
templates.mailchimp.cXm/resources/html-to-text/
 
You might be able to do this with the SEOTools plugin for Excel, by Neils Bosma. The plugin is free, and can extract content from web pages rather easily into an Excel cell, with the functions XPathOnURL and HTMLFirst. I've not tried it on local files, but I would imagine it should work since you would just be using the path to the file on your hard drive in place of a URL. If it works, the only other thing you would probably need is a small freeware tool that can give you a list of all the files in a folder, so you can paste that list into Excel.

The other one I might look into is WebHarvy, which might work on local files as well. It's not free but there are pirated copies out there. In fact, there may be some copies shared on these forums if you look around.
 
The best what I can suggest is use Purifyr :) as it is mentioned above,it will work the best for you.
Good Luck :)
 
You might be able to do this with the SEOTools plugin for Excel, by Neils Bosma. The plugin is free, and can extract content from web pages rather easily into an Excel cell, with the functions XPathOnURL and HTMLFirst. I've not tried it on local files, but I would imagine it should work since you would just be using the path to the file on your hard drive in place of a URL. If it works, the only other thing you would probably need is a small freeware tool that can give you a list of all the files in a folder, so you can paste that list into Excel.

The other one I might look into is WebHarvy, which might work on local files as well. It's not free but there are pirated copies out there. In fact, there may be some copies shared on these forums if you look around.


Thanks Webharvyy seems can do the job, but not for files on computer. Notepad++ seems the best, I already converted both sites into txt file articles. :)

The best what I can suggest is use Purifyr :) as it is mentioned above,it will work the best for you.
Good Luck :)

Thanks, but there is only api and site is down. I already done the work... :)
 
You can try this plugin for wordpress: https://wordpress.org/plugins/import-html-pages/

I've used it before a few times with success. If your html files are local, maybe you could install wamp and run wordpress on localhost so you can do this. It looks complicated, but it does work well if you set the plugin right.
 
Back
Top