update_site_option( ) fails for (pretty) large data
I cannot test this on 3.0.1 right now.
By the way, I’m trying to cache a result set for 5 minutes into a site option with update_site_option( ) and get_site_option( ), but update_site_option( ) fails.
The variable array is there, I dumeped the serialized version into a .txt, it comes out a 1.09MB file.
But if I try to store it with:
The function doesn’t return false.
The meta_value corresponding to the ‘my_result_set_cache’ meta_key turns out to be empty.
I tried to bypass the automatic serialization by serializing the variable myself, but I’m not sure it would work dued to THIS, I fear a double serialization and if I do that by the way the function return false.
I tried to deflate the serialized version to reduce the size to about 350KB, but it failed again.
Testing with a smaller variable or simple string, works normally.
What am I doing wrong?
edit: I did a test with update_option( ) and it’s the same.
edit2: tested on my local web server (Vista, Apache2, PHP5, MySQL5, WP 3.0.1 no plugins, php memory_limit=512M) and it fails too, no option is created and the add_option function returns false.
- The topic ‘update_site_option( ) fails for (pretty) large data’ is closed to new replies.