Wordpress API Create post content
I am basically trying to duplicate wordpress pages using the Wordpress API. I do get the page content using GET /wp/v2/pages/ endpoint.
I receive the the JSON data which includes:
content: style/*! elementor - v3.5.5 - 03-02-2022 */\n.elementor-heading-title{padding:0;margin:0;line-height:1}.elementor-widget-heading .elementor-heading-title[class*=elementor-size-]a{color:inherit;font-size:inherit;line-height:inherit}.elementor-widget-heading .elementor-heading-title.elementor-size-small{font-size:15px}.elementor-widget-heading .elementor-heading-title.elementor-size-medium{font-size:19px}.elementor-widget-heading .elementor-heading-title.elementor-size-large{font-size:29px}.elementor-widget-heading .elementor-heading-title.elementor-size-xl{font-size:39px}.elementor-widget-heading .elementor-heading-title.elementor-size-xxl{font-size:59px}/styleh3Abi '22 me
But when I use this content to send a request to POST /wp/v2/pages endpoint including the same content it looks really crappy.
As you can see, I use elementor. Is that the reason it looks weird?
This is how it should look like. Beautifully designed, background image...
And this is how it looks...
Does anyone know what I am doing wrong? I know there are plugins to duplicate pages but this duplicating process is just a first step for me to then change the page's content to my specific needs...
Thank you very much, Richard
Topic post-content api Wordpress
Category Web