How to embed a Wordpress blog into a website?

844 views Asked by At

Hope someone can help. I am building a simple CV website website which is to include a Wordpress blog. I did use as a temporary solution, but this did not render well on iPhone. I have seen solutions relating to php, but having no prior experience of php I wouldn't know where to start. What i have seen so far online hasn't really given any step by step instruction on how to use the php approach. Any help would be appreciated.

            <!DOCTYPE html>
            <html lang="en">
            <head>
            <meta charset=utf-8>
            <meta name="viewport" content="width=device-width, initial-scale=1.0">
            <title></title>


            <link rel="stylesheet" href="http://keeleyknight.com/styles.css">
            <link href='http://fonts.googleapis.com/css?family=Quattrocento+Sans' rel='stylesheet' type='text/css'>
            <script src="http://keeleyknight.com/_js/jquery-1.9.0.min.js"></script>
            <script type="text/javascript" src="http://keeleyknight.com/_js/modernizr.custom.86080.js"></script>
            <script src="_js/myscripts.js"></script>

            </head>

            <body>

            <div id="wrapper">
                <div id="content">
                    <div class="kk_background">
                        <div class="container">
                            <div class="blog">
                                <div class="contact_content">
                                    Blog Goes here

                                </div>
                            </div>
                        </div>
                    </div>
                </div>   
                <!-- / Homepage -->


            </div>
            </body>
            </html>
1

There are 1 answers

5
pinkal vansia On

You can use this word press plug-in in wordpress and can fetch posts with PHP Guzzle library like below

$client = new \GuzzleHttp\Client();
$response = $client->get("http://domain.com/wp-json/posts?filter[category_name]=test", array('auth' => ['username','password']));
$posts = $response->json(); 

And render posts in your website the way you want.