开发者

retrieve posted blog content in wordpress based on id or permalink

开发者 https://www.devze.com 2022-12-19 17:34 出处:网络
I hope somebody know the answer of my question. How do I retrieve posted blog content in wordpress开发者_StackOverflow社区 based on id or permalink? I need the API.

I hope somebody know the answer of my question.

How do I retrieve posted blog content in wordpress开发者_StackOverflow社区 based on id or permalink? I need the API.

Thank you


Wordpress documentation is your friend: get_post

e.g:

<?php
$my_id = 7;
$post = get_post($my_id); 
$content = $post->post_content;
?> 
0

精彩评论

暂无评论...
验证码 换一张
取 消