As this was public data I needed I just used simplexml_load_file to load the following:
http://www.blogger.com/feeds/blogId/posts/default.
I used the following tutorial: https://www.youtube.com/watch?v=4ZLZkdiKGE0
题
I've battled with this for hours and quite frankly I'm new to API's completely.
I've had blogger activated and generated an API key.
I have then used the following code to GET the posts (with YOUR-API-KEY) being the key i've generated:
GET https://www.googleapis.com/blogger/v3/blogs/2399953/posts?key=YOUR-API-KEY
a) This isn't showing up on my site at all.
b) My site currently has Blog posts marked up in the following way:
<section>
<h2>BLOG TITLE</h2>
<date>DATE OF POST GOES HERE</date>
<p>BLOG CONTENT HERE</p>
</section>
How can I display the posts to add this markup?
I expected there to be a tonne of tutorials out there for this but I've been unable to find one concise enough.
解决方案
As this was public data I needed I just used simplexml_load_file to load the following:
http://www.blogger.com/feeds/blogId/posts/default.
I used the following tutorial: https://www.youtube.com/watch?v=4ZLZkdiKGE0