[wp-hackers] Is WP_INSTALLING constant here to stay?
otto at ottodestruct.com
Wed Jan 23 03:41:31 UTC 2013
On Tue, Jan 22, 2013 at 7:20 PM, Mike Schinkel <mike at newclarity.net> wrote:
> So how would you in a plugin set SHORTINIT
Obviously, you can't. SHORTINIT doesn't load plugins at all.
> we ran into latency issues that the person developing it said he could only resolve the latency issues by directly loading a PHP file via AJAX and setting the SHORTINIT constant to true before including wp-load.php.
Well, like I said earlier, there is a difference between custom
one-off's and things that you intend to release to the public. Without
more specific details about the situation, it's hard to state what an
alternative method might be. A "predictive search drop-down" can be
done in a lot of different ways, but presumably you're talking about a
slowness involved between the time that the text is entered and the
time that the HTTP hit returns your data from the AJAX request. That
is indeed a problem, but other ways might exist to solve that as well,
depending on circumstances. Pre-loading possible search results, for
example, to give a limited dropdown with additional ones loading in
the background, maybe. Hard to say without specifics, but generally
there are ways of rethinking the problem.
But again, if it's a custom job for a specific case, then sure,
loading wp-load directly can be fine. In a custom case, where you
control everything, you don't have to code generically.
More information about the wp-hackers