Support » Fixing WordPress » How to get pages along with styles using REST API?

  • Here is the context of my problem:
    I want to read the content of the pages created on wordpress and display in my website.
    I am able to do that by making http://host-name/wordpress/wp-json/wp/v2/pages/page-id and read the content and display on my website using REST API.

    My problem:
    I am not getting the styles of the pages. So the page looks really weird. I know that we get only the page’s content and styles are not included in it. I was wondering if there is a way create the pages in such a way that we get css and content together. (Don’t want to write complete HTML in page editor. User should be able to build page)
    Is there a plugin or some thing that will use inline css?
    If I can get all the css in a file, I can include that in my website. So I can get the page display well. Is there a way for it?

    As this is not straight forward, I am open for any ideas to implement it. Please share your thoughts.

    I am looking for ideas on how to implement this and thought this is the right place to ask knowing this can not be done automatically.


Viewing 2 replies - 1 through 2 (of 2 total)
  • Hey vdasari,

    Do you find any solution to it ? Actually I am also trying to make it happen.
    If you find any work around, then please share.


    I don’t have any solution for it.
    I built the page with inline styles while creating it in wordpress and I was able to read the styles and display it in my site with same look and feel.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to get pages along with styles using REST API?’ is closed to new replies.