It works, thank you for your help!
Sorry for the late response.
I have done all you suggested, the plugin works fine locally with the same theme and plugins. The only difference is that my online site is part of a multisite installation. Can that be the problem?
For now, I will try other plugins, but I’m still interested in your ideas about a possible multisite problem.