Join Morten Rand-Hendriksen for an in-depth discussion in this video Build a basic plugin, part of WordPress REST API (WP-API): First Look.
- Now it's time to create the plugin.…If you have never created a plugin before,…I will give you a really brief crash course…on how to get that started.…First of all, in my code editor, in this case Atom,…I've opened up the folder that contains WordPress,…so here you see the three WordPress folders…and all the other files that are associated with WordPress.…These are all locally on my computer,…and these are the files that are running the WordPress site…you see in my browser.…Now I need to go to the wp-content folder…and the plugins folder, and from here…I'll create a new folder and call it gofurther.…
You can call this folder whatever you like,…but this is where the plugin's going to go.…Now, to create a plugin in WordPress,…all you need to do is create a PHP file…with the name of the plugin, and then…place some specific commented-out code at the top.…And to make that process easier for you,…I've already prepared that in the…exercise files for this movie.…So if you go to the exercise files for this course,…Go to movie 04_03, and then find gofurther.…
With the WP API, developers can access the data on a WordPress site—such as users, posts, and categories—programmatically. The result is an expansion of the already limitless field of possibilities where theme and plugin development is concerned.
This course is a first look at the WP API: what it is, how to get it running, how to interact with it, what it can do for us, and what we can do with it. Join Morten Rand-Hendriksen, your guide and WordPress guru, as he walks through the tools and major features (such as routes and endpoints) of the WP API, as well as a short project that shows how this new API will be used in real-world workflows.
- Installing the WP API
- Exploring common routes
- Examining WP API output
- Building plugins with the WP API
- Crafting WP API URL requests
- Creating AJAX functions with the WP API