• Resolved issacchua

    (@issacchua)


    Hello Marko,

    I am trying to achieve convert all images to webp without having human to login to admin backend and manually click on the Convert All button.

    What I did was to register action hook somewhere in the ‘template_redirect’. Something like this:

    function temp(){
       if($_GET['temp'] === 'a very special unique link that can trigger convert all'){
            // user has already login via wp_set_current_user and wp_set_auth_cookie
            do_action('wp_ajax_w3tc_imageservice_all');
       }
    }
    add_action('template_redirect', temp);

    I think that should work but it isn’t. Looking for some help, thanks!

    • This topic was modified 2 years, 6 months ago by issacchua.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @issacchua

    Thank you for your inquiry and I am happy to help!
    I cannot help you with this since this is not something that we would suggest. While I understand your request and what you are trying to achieve, this is not something that is a normal procedure or something that we may suggest and it is out of the W3 Total Cache plugin scope.
    Thank you for understanding.

    Thread Starter issacchua

    (@issacchua)

    Thanks Marko for your reply, I will find some other way round, thanks!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Convert All images to webp via specific URL’ is closed to new replies.