Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

wordpress get text of wordpress post

<?php 
$my_postid = get_the_ID(); // Get Current Page ID or just use the number like 315
//get_the_ID() gets the page/post id of the current page/post. We use it here to make it dynamic in templates / shortcodes
$content_post = get_post($my_postid);
$content = $content_post->post_content;
$content = apply_filters('the_content', $content);
$content = str_replace(']]>', ']]>', $content);// Strip Symbols
echo $content; // Outputs Content
?>
 
PREVIOUS NEXT
Tagged: #wordpress #text #wordpress #post
ADD COMMENT
Topic
Name
8+9 =