WordPress.org

Forums

JSON API
Remove WordPress automatic paragraph tags (1 post)

  1. monkeypunch3
    Member
    Posted 1 year ago #

    Is there a way to disable the auto formatting and auto smart-quote conversion when returning the content?

    I found this code in a plugin called WP-Unformatted.

    // disable auto-p
    remove_filter('the_content', 'wpautop');

    // add conditional auto-p
    add_filter('the_content', 'wp_sponge');

    // disable texturize
    remove_filter('the_content', 'wptexturize');

    // add conditional texturize
    add_filter('the_content', 'wp_sandpaper');

    If I add some custom fields to the post in WordPress it disables these options across the whole site but I don't want them disabled for the live site (because it is screwing up the formatting), only when making the calls through the JSON-API.

    http://wordpress.org/plugins/json-api/

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • JSON API
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic