Running multiple code snippets on websites

Hi guys,

I’m trying to use the Code Snippets extension to manage around 40 snippets that I need to install and run on all my websites.

Every time I add a new site, I need to load the snippets one by one, mark the checkbox for the site, and hit “Save & Execute the Snippet”. Needless to say, it’s a very time-consuming process.

Is there a way to bulk select snippets to install on a given site, either via the UI or directly in the database?

Thanks.

1 Like

You might want to use a must-use plugin for this, like I do. I’ve placed mine on Github with the instruction how to use it with MainWP.

2 Likes

Your plugin looks really cool. In my use case, I have rather large code snippets that I need to distribute to the sites, so it might become a bit of a challenge to use it. Anyway, I’ll look into it. Thanks!

2 Likes

Hey @juliano

Welcome to the MainWP community!

Right now, each snippet must be loaded individually and then applied to a new site.

There is an open suggestion for a very similar feature on our official feedback site: See which Code Snippets apply to a Child Site at a glance - MainWP

Please feel free to give it an upvote or a comment. That lets us know which features our users want the most.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.