• Hello,

    I’ve got the Json Api installed. But i want to output the get_recent_posts without all the “Read more” links.

    How can this be done?

    Thanks,
    Krielkip

Viewing 1 replies (of 1 total)
  • Thread Starter Krielkip

    (@krielkip)

    Solved:

    models/post.php:

    Replace the whole function ‘set_content_value’ with:

    function set_content_value() {
        global $json_api;
        global $more;
        if ($json_api->include_value('content')) {
        //	$content = $json_api->include_value('content');
          $more = 1;
          $content = get_the_content($json_api->query->read_more);
          //$content = get_the_content();
          $content = apply_filters('the_content', $content);
          $content = str_replace(']]>', ']]>', $content);
          $this->content = $content;
        } else {
          unset($this->content);
        }
      }

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: JSON API] Remove Read more in get_recent_posts’ is closed to new replies.