[ad_1]
[ad_2]
Hi. I've recently come to a job offer that requires me to build a new WP site, but migrate content (posts, images) for a custom made cms. That custom made cms doesn't have such an option as exporting data. Is there any relatively easy way to do this?
Thx
How is data stored in the custom CMS? Can you get the data out of the database in either CSV or XML format? I’ve found [WP All Import](https://www.wpallimport.com/) works really well if you can get XML data and ok if you can get CSV based data.
Most MySQL database programs like Navicat, etc can do an export of a database as XML which would probably be the best option for working with data from the CMS.
As far as images, you can copy those off of the old server and place them on your server somewhere, then update the file paths in the .xml file you feed to WP All Import.
I haven’t had to do this in a while, but last time I did I used the [HTML Import 2 plugin](https://wordpress.org/plugins/import-html-pages/#description).
Yes I would say using WP CLI, is the easiest way, I once wrote a script to migrate from WordPress to Processwire, what you would do, is get the details from the custom cms in WP Script, then loop over all the content and save to WP using `wp_insert_post` rather than the database.
is the custom CMS written in PHP ?