-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unexpected HTML returned in JSON #15
Comments
On a hunch I attempted to reproduce in a local env with Yoast SEO 3.4.2. This didn't produce the expected results ( in qw/wordpress). This is most likely due to the fact that cloning had previously succeeded. So I tried the deactivate oik-testimonials plugin method. The result of this was that the post was cloned to post ID 1. Another rather unexpected result! I manually corrected the
Trace output on the server does not show this being returned in the JSON ( see
|
Analysis of the functions attached to 'shutdown' is enlightening.
Clearly there's a lot going on during shutdown. What I realise is.
It appears that bw_jq_flush() shouldn't be echoing its output in AJAX processing. |
For a couple of posts which have been cloned, the ID for a slave's entry has been set to 0. This can happen when the
slave
returned in the JSON cannot be determined due to the JSON being malformed.A particular instance is qw/oikcom/oik-plugins/oik-testimonials, ID 7975, which had failed to clone to oik-plugins.com. The returned JSON includes the JavaScript generated for the [bw_testimonials] shortcode, which was part of the post's content.
This problem does not happen when the post is cloned to oik-plugins.co.uk, nor locally.
Workaround
Disable the shortcodes before cloning and re-enable after. Either edit the code so that it's not expanded or deactivate the https://github.com/bobbingwide/oik-testimonials plugin.
Problem explanation
The problem is caused by 'the_content' filter being run during shutdown processing. See below
Proposed solution
tbc
The text was updated successfully, but these errors were encountered: