WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] XMLHttpRequest 404 but response OK?? (2 posts)

  1. 3dolab
    Member
    Posted 3 years ago #

    Hello,
    what's new with URL query string handling in WP3/3.0.1?
    In 2.9.2, I was able to include other pages via ajax with javascript, mootools and a loader php page in my template, now it seems that custom URLs don't work anymore.

    The ajax inclusion of
    http://www.domain.com/wp/wp-content/themes/mytheme/ajaxloader.php?pagename=my_page/my_subpage
    is OK

    but using custom query string variable names and values (usually later processed by the loader php)
    http://www.domain.com/wp/wp-content/themes/mytheme/ajaxloader.php?custom_variable_name=my_page/my_subpage
    http://www.domain.com/wp/wp-content/themes/mytheme/ajaxloader.php?pagename=dummy_value/my_page/my_subpage
    it throws out 404 errors even if the actual content is correctly shown by Firebug in the response content and html tabs.
    Also, opening the link in a new window will work as expected.

    It sounds like a kind of cross-checking of default variables and corresponding existing values. How could I find a workaround?

  2. 3dolab
    Member
    Posted 3 years ago #

    Solved:
    the loader template file should require wp-load.php and not wp-blog-header.php

    http://wordpress.org/support/topic/integrating-wp-in-external-php-pages
    http://www.questionhub.com/StackOverflow/3445270

Topic Closed

This topic has been closed to new replies.

About this Topic