[wp-testers] **OT** Variable definitions in functions.php
Paul Robinson
pablorobinson at gmail.com
Mon Mar 22 12:54:29 UTC 2010
Thanks John, I'll give that a read. :)
Thanks again for the help with this.
On 22 March 2010 11:48, John Blackbourn
<johnbillion+wp at gmail.com<johnbillion%2Bwp at gmail.com>
> wrote:
> On Mon, Mar 22, 2010 at 11:21 AM, Paul Robinson <pablorobinson at gmail.com>
> wrote:
> >
> > Another quick question though, how come the overhead on get_option is so
> > small, doesn't it access the db each time it's called?
>
> The result of get_option('my_option') is stored in an object cache.
> This is basically just a fancy wrapper around storing the result in a
> global variable array. Any subsequent calls to get_option('my_option')
> during the same page load fetch the value from the cache instead of
> the database.
>
> See http://codex.wordpress.org/Function_Reference/WP_Cache if you're
> interested in the details.
> _______________________________________________
> wp-testers mailing list
> wp-testers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-testers
>
More information about the wp-testers
mailing list