• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Input Making hotlink optional in Wordpress websites

Denis Gomes Franco

Regular Pleskian
So here's the thing: if i open the Security page under Wordpress I can see the security status of all my websites and I can quickly apply all the recommended security settings to all websites - and that includes hotlinking protection. While I understand the importance of this protection, this also makes Woocommerce notification emails lack the site's logo in their headers, due to the hotlinking protection kicking in.

So what I'm doing is that I'm manually applying security settings without the hotlinking protection. But then I have to do it one site at a time.

I would like to find a way to do it semi-automatically or at least make hotlinking optional when applying the security settings to all sites at once. Another way to do this would be to apply all settings and then disable hotlinking in all websites at once. And yet another way would be a screen where I choose which settings I want enabled and then a button APPLY TO ALL SELECTED WEBSITES or something like that (currently, Plesk only allows applying all the security measures to all websites at once).
 
semi-automatically
Bash:
plesk bin hotlink_protection --update example.com -enabled false
If you want to keep the hotlinking protection without disabling it, You can exclude a source domain from hotlinking by executing this command:
Bash:
plesk bin hotlink_protection --update example.com -friendly-domains woocommerce.com
If that woocommerce logo is a PNG format you can exclude the format itself: (Currently has a bug not yet reported, don't use it now, you'll lose the default settings)
Bash:
plesk bin hotlink_protection --update <yourdomain.tld> -enabled true -protected-extensions bmp;dib;rle;emf;wmf;gif;jpg;jpeg;jpe;jif;jfif;pcx;tga;tiff;tif
^Note that all pictures format except PNG
 
Back
Top