WordPress.org

Ready to get started?Download WordPress

Forums

JSON API
URL redirect me to Homepage (7 posts)

  1. razarahil
    Member
    Posted 1 year ago #

    The JSON api url is redirecting me to the homepage.

    Here is my url: http://www.razzil.com/api/get_recent_posts/?dev=1

    When you open the above url, it'll redirect you to the homepage. No JSON data is shown on the page.

    My Permalink setting: /%postname%.html

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

  2. dphiffer
    Member
    Plugin Author

    Posted 1 year ago #

    Hi razarahil, it looks like ?json=1 doesn't work either. Is the plugin still enabled? Maybe there's another plugin doing the redirect?

  3. razarahil
    Member
    Posted 1 year ago #

    Yes the plugin is still enable and no other plugin redirecting it.

    Redirect happened because of my permalink. I created a test blog on a server with permalink structure /%postname%.html The plugin didn't work

    Then I changed the permalink structure to /%postname%/ and this time plugin works.

    Can you please add fix so that we can use it with a later one. I can't change permalink structure right now I'll affect my blog badly.

  4. dphiffer
    Member
    Plugin Author

    Posted 1 year ago #

    I don't think it's the permalink structure (see: https://mlkshk.com/p/S319). Maybe it's a server setting? I would check your Apache configuration for mod_rewrite rules.

  5. razarahil
    Member
    Posted 1 year ago #

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    I'm also using W3TC.

  6. dphiffer
    Member
    Plugin Author

    Posted 1 year ago #

    Those rewrite rules look pretty standard. If you disable W3TC does that make any difference?

  7. mavtrevor
    Member
    Posted 4 months ago #

    Any tip on how i can solve WordPress SEO plugin & JSON API plugin conflict? JSON API feed URL http://www.netmediablog.com/?json=1 redirects to homepage. I am trying to pull feeds from my blog http://www.netmediablog.com via JSON API to an Android app am building but the JSON Feed URL http://www.netmediablog.com/?json=1 keeps redirecting to the homepage, so i figured if i disable all the plugins i can narrow down the source of the trouble, so i did and discovered that any time i active the WordPress SEO plugin the JSON feed url redirects to my homepage.

    Anyone got any idea how i can fix this? I really need the WordPress SEO plugin and i also need to get the JSON feed url working.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags