Forums

Delete cache with GUID as Id? (2 posts)

  1. Bjorn van der Neut
    Member
    Posted 8 months ago #

    Hello,

    I have a question how to delete the cache in the following situation.
    A user add's a widget and in the widget the give a unique key (GUID).

    This key I use to store the cache:
    wp_cache_set( $guid, $cache, 'bvdn_looptijden_cached_widget', 43200 );

    And also when using a shortcode I store the guid in the cache:
    [looptijden code="F68FB11E-9A2C-4704-8F0A-88DE8E0A4525"]

    wp_cache_set( $guid, $cache, 'bvdn_looptijden_cached_shortcut', 43200 );

    So how do I receive these quid values to delete the cache on "uninstalling" the plugin?

    wp_cache_delete ( $guid, 'bvdn_looptijden_cached_widget' );
    wp_cache_delete ( $guid, 'bvdn_looptijden_cached_shortcut' );

    Thanks for the help!
    Bjorn

  2. Bjorn van der Neut
    Member
    Posted 8 months ago #

    Hum, I think the question was not clear or to difficult?
    If more info is needed just let me know!

Reply

You must log in to post.

About this Topic