and it can be deployed by topping the code to let me show you what I mean here so if we get out of this cancel I’ll wait what was an example so you see here if using an if 4 for these are role at coming it’s a structure that you might employ so for and you can see it it’s trying to help you with setting up a fully so that’s a snippet
but an easy way is something that I use cold textexpander so I got a whole bunch of Snippets that I used and what’s for all code as well so if I go remove objects except so this one here is his typing semicolon remove and I get a nice bit of code so I go
remove and then to make a popping sound and then I got here so it’s going to remove everything except for this thing here so it was imported. Let’s say over here it’s the one object that I want to keep so I just replace that in the list
and then if I run that code it’s gone head include everything except for imported. I’m so once again that’s a semicolon remove
but I I can use it for lots of stuff so Excel a lot of different code chunks that I often deploy that I can’t really remember so I use this text expander application I would have paid is like $3 a month or something like that but I think it’s very useful and I think it would come really handy if you’re maybe just loaning out letting out things and it’s really hard to remember things all the time
I think also there’s a process of of actually stipulating that you want to record it somewhere will help reinforce it okay so that is that’s a bit about Snip-Its and also that textexpander about moving a lot except okay let’s go
I’m sure you’ll be able to choose whether you want to create a snippet or configure Snippets for a specific language or Global which applies to all files that are opened with the F code I’ll be using JavaScript
scroll down here you will see these snippet that I already created earlier for the Subscribe we will now be using this template down here in the comments to create our snippet of the random number generator tell anyone, this the name or just call the RNG for random number generator prefix this is what is used to select a snippet the word that you type in to activate it so I’m going to type in R and Jen and here’s the body which is the code will be pasted in there we will have not thought floor not. Random
and plus and sure we will have the maximum variable I’m going to call it a dollar sign one I’ll explain real quick after real quick what this means and all the time too so using the dollar sign in a number allows tab stops and you’ll see it when I demonstrate that this allows me to Paces in and then enjoy this value khattab and injured about you first get this and then last week we have the description here which I would just say creates a random number generator and go back to the Snippets file let our equals and we had Ranch and so if I Type R engine will see it comes up I can hit Tab and now automatically move the cursor there so for the first number this is our maximum so we can say let’s say we want to generate between 50 and it stabbed and 3 so this will generate a number between 50 and 3 so there’s a bunch of existing Snippets they can also use for many different languages infrastructures and tools they can download just threw vs get extensions it’s a
go to the left hand side over here and click on extensions and here in the search you type at category colon quote Snippets and quote hit enter and here’s a bunch of already existing Snippets for variety of different packages and languages that you can download and go ahead and use so hopefully found this video helpful you did hit that subscribe button and I’ll see you next month thank you so much for watching
So much time saved I like to do my plugins and must-use plugins, but I like much more to just write or paste my snippets directly on the site and see it working at once.
All those little tweaks don’t need to pass by Git or Visual Studio Code and FTP anymore. Straight to action!
Brilliant, thanks for this!
Great I’m new to WordPress, but not PHP. Snippets allows me to write and use the PHP code that I’m used to.
Just doesn’t work Just want to move “add_filter, add_action” codes from function.php to this plugin. And the code is simple, works in function.php, but just doesn’t work in this plugin, try to figure things out, but it’s really hard to. At this point of view, I would suggest you to improve the user experience of this plugin better, especially the debug part.
Time saver I use to my every wp site
Great plugin UI is very Intuitive and friendly, deserve five star vote
Amazing Very practical
So Helpful! So Helpful! I don’t like going into the functions php area, so this tool is⦠So Helpful! lol
And if I mess up my code, this tool just roles back to a working state. OMG!
I also love the code you can place into the “config file” for SAFE MODE.
A vital plugin for my website development It handles so many use cases, I can’t recommend this plugin enough. For me, this is one of the plugins I will install no matter what website I am creating.
Installed on all of my sites This plugin gets installed on every site I develop. It allows for consolidation of all functions in one place, instead of having them scattered throughout templates and functions.php. Document them in the description field and you’ll never wonder what a function does again.
I use the plugin on every website. I have a whole collection of snippets that I have programmed over time that I can click clack reuse.