WordPress Dev Seacoast Meetup Announcement for January 6, 2014: WordPress JSON REST API

I’m preparing a talk for our local WordPress MeetUp on January 6, 2016.  You’ll learn why WordPress is getting a REST API, why it’s in JSON format, and what do all these acronyms mean.

WordPress JSON REST API Post-Holiday Extravaganza

You may have heard that WordPress has begun the process integrating a JSON REST API in version 4.4.  In this presentation we’ll cover these topics:

  • Why it’s important for WordPress to have an API.
  • What is CRUD, REST, JSON, and how to interface with a REST API.
  • How to configure and interface with the JSON REST API in WordPress
  • We’ll review some code examples in PHP and Javascript.

WordPress started as an open-source blogging tool.  The introduction of custom post types meant WordPress could be used as a full-fledged content management system.  The JSON REST API is a new opportunity for WordPress to become a web application platform.  Come learn about the future of WordPress web development.

See you there. WordPress Dev Seacoast Meetup,  January 6, 2014.

Learn Javascript, deeply.

learn-javascript-deeplyThat’s the homework assignment given to the WordPress community from Matt Mullenwegg’s State of the Word address.  To repeat: ‘Learn Javascript, deeply’.

A lot of sessions and conversations at WordCampUS 2015 backed up the notion of WordPress and the rest of the web moving towards JavaScript development.  The examples were many:

Adam Silverstein of 10up said that the framework that one chooses is not that important.  He likes Backbone because it stays out of the way.  React is a very opinionated about how to do things.  He also agreed with the point that it may be unwise to use a technology that originates from Facebook, with their history of inconsistency, and always doing what’s best for Facebook.  Backbone gives you granular control, while other JavaScript frameworks make assumptions and do everything for you.

Dirty Stylus had 4 completed projects. See their talk ‘Decoupled Development with WordPress JSON APIs’.  The advantages included parallel development by PHP developers on the back end, and JavaScript developer working on the front end.  They demonstrated technologies using AngularJS, RiotJS, MapBox, and an ACF-to-WP-API plugin.

The new Calypso app for Mac was built for WordPress using React, Flux and node.js.

Rachel Baker, part of the team building the JSON REST API, showed WordCamp US how to build a WordPress theme with a JavaScript front end.

The WordPress JSON REST API is going to be an important part of advancing the web, and knowing how to use JavaScript on the front end will be very important for developers.  Matt Mullenwegg’s message, and the speakers at WordCamp US 2015 have helped set a course for the future of WordPress and the Internet.

 

WordCamp US 2015, Day 2

The Setting

Another day of great people and interesting conversations.  Lunch was amazing today, for a conference.  BBQ chicken, beef brisket, corn bread!  Soda! Not just water, ha.  The after-party at Lucky Strike bowling alley was perfect.  Open bar, catered food, fun people, though I couldn’t find the ping pong tables.  I wanted to challenge Derek Smart (Automattic Table Tennis Champion) to a game.

The Talks

Decoupled Development with WordPress JSON APIs:  Watch this talk.  Another inspirational talk about using JavaScript on the front end of a WordPress installation.  Lots of good technical data in this talk.

Make WP_CLI Work For You: Extending WP-CLI With Custom Commands: A talk about writing code to build tools to build websites.  Geek heaven.  If you’re not using WP-CLI, get started.

Gamify WP:  A fun talk on gamification, and how a developer Automattic used the technique to motivate people to test using Calypso to write blog posts.

High Performance WP: A quick talk on all the things one should do.  Yes, I need a better checklist.

Low Tech is Future of WP:  Another solid talk by Eric Mann now how slow WIFI, slow internet connections are an opportunity for WordPress websites.  And l learned Chrome Development Tools can mimic a slow connection for testing.

HTTP API:  Use REST, CRUD in communication with 3rd party APIs?  WordPress has built in functions to make this stuff easier to use.

WP and Museums, Mel Choyce:  A great 2 person talk with a client and a developer and their approach in putting together a website for a museum collection with 40,000 potential pieces of data.  These case study talks are great.

WP for Enterprise, Taylor Lovett: 10up has the best employees, and they give away their best practices.  Cool company.

State of the Word: Matt Mullenwegg maps out the potential future of WordPress.  Great stuff.  Watch this.

Best. WordCamp. Ever.

WordCamp US 2015, Day 1

The Setting

From the beginning, this WordCamp US felt a little different than the WordCamps I’ve attended previously.  Many people I’d seen as speakers previously were attendees.  Many popular WordPress twitter folks and bloggers were there, just walking around.  The topics of the talks seem higher level, more for developers and there was a lot of ‘I wish I could be at 3 talks at once’.

The attendees were friendly and every person I spoke to had something interesting to say about their work with WordPress.  All the organizers were kept solving problems, especially when the WIFI was overwhelmed in the first few hours of the conference.  Volunteers were everywhere and also helpful.

Philadelphia is a great city.  Easy access to downtown via Septa train from the airport, AirBnb rentals were plentiful if hotels aren’t your thing.  We stayed in the Rittenhouse Square neighborhood just SE of downtown.  An easy walk to the conference.  My new favorite hangout in Philadelphia is Monk’s Cafe, an excellent Belgian Beer bar with great food too.  Heaven.  Downtown has some amazing architecture,  interesting sculptures,  great food and drink.   Even the restaurant staff were down-to-earth in the city, though you felt like you were in Manhattan.

The Talks

Curing a Critical Security Bug: This talk was about the MySQL vulnerability fixed earlier this year.  It feels good to know such experts are working on core.

A Bolt of Backbone: use it, learn it:  This talk confirmed everything about my goals to learn more JavaScript.  Adam Silverstein is a good speaker.

WordPress + The Internet of Things: Lots of opportunities for WordPress here, and RC Lations always give a great talk.  How does he stay so chill all the time?  Must be that clean Maine living.

The Future  Stack: Runnning WordPress with Tomorrow’s Technologies: This covered Http/2, php7, CSS4, Free SSL, JS2015.  Very fun presentation, and the talk made potentially dry material very interesting.  Short take is that  WordPress is ready for all the changes coming down the road.

React + WordPress: A motivating talk on using JavaScript.  Re-usable components sound pretty good and it looks like React removes a lot of the complexity of Single Page Application development.

Build a Theme with REST API: Rachel Baker comes out of the JSON REST API trenches to show us how to build a theme with JavaScript and the REST API.  Great cutting edge talk.

REST in Action: The Live Coverage Platform at the NYTimes: This talk was a bit of a disappointment since the title topic was only covered in the last 5 minutes of the talk, and no technical tips, no time for questions.  I think the speaker was busy making sure WordPress 4.4 would get out the door 3 days later as its lead developer, so it’s understandable.

A great first day, and I still need to see the talk by Nacin.  Always listen to Nacin.  Cheers, and off to Monk’s Cafe.

 

 

Web Developer Productivity, Workflow, and Motivational Tricks

Being self-employed also means being a self-starter, and keeping yourself motivated, because no one else will be there to tell you to get started.   I’ve read a lot of books and increasing productivity, and tried a lot of things.

The best productivity book I’ve read recently is Essentialism by Greg McKeown.  Letting go of distracting projects is maybe the most important thing to do, because it allows you to focus on the important projects.  Also, ask oneself, What’s Important Now? (WIN)  I find that simple question stops a lot of time wasting.  I highly recommend this book.

Some iOS apps that I use for productivity: Calm, the directed meditations really help me clear my head when my wheels are spinning.  Yes, meditation can really help when you’re stuck on a project.  The Simplenote app is  a great way to keep a quick list, or take some notes.  The best part is that it’s shared among all one’s devices.  Build a shopping list through the week as you think of things when on your laptop?  Then the same list is with you on your smartphone at the grocery.  I find the similar shared device aspect for To Do lists on Wunderlist to be similarly effective. I have To Do list for Work, Personal stuff, and quick focused projects, like taking a trip, or launching a site.

Caffeine is an obvious productivity tool for programmers, and I have to say the Starbucks app is pretty useful.  They’re going to get my money either way, so I may as well use their digital equivalent of a frequent buyer card.

My new favorite Chrome browser Extension is Momentum. It shows up on your new tab, rather than the default bookmarks.  It allows you to type in your focus for the day (see Essentialism). Gives the time, which is easy to lose track of.  Show the local weather, prevents checking the weather sites.

MyNoise.net is a website that provides any kind of background noise you might need while working.  Nature sounds, ambient noise, industrial drones, event cats purring.  Great stuff.

Email is unavoidable, but it has it’s problems.  Looking and finding information in email, and being distracted by new email is a common problem.  Tools like Slack are good if there is a defined list of people in a project.  It’s quick and cuts down on the email noise.  Using the P2 Theme by WordPress to organize projects is nice because it leaves a history of ideas, and decisions.

My programming environment has changed over the years. Currently most of my work is WordPress Theme development.  I’ve switched over to more of Linux command line environment along with Mac OSX to achieve a better workflow.  I use the Grunt Task Manager running on node.js.  Grunt compiles my SASS files, and SASS is a productivity boost in itself since it’s easier to write CSS.  I use twitter Bootstrap as a CSS framework to get mobile responsive websites right out of the gate. I use the latest version of the WordPress.org Underscores starter theme to make my themes consistent over projects, and waste less time fixing incompatibility bugs.

For learning new techniques Google search is the obvious choice, but finding the right tutorial can be exhausting.  Google is best for quick, small solutions.  For ‘big’ learning I’ve had excellent results with Lynda.com classes, EdX.com (MOOC), and good old-fashioned books from the  Public Library.

A travel efficiency, that is kind of obvious, is carry on luggage only.  I’m a big fan of RedOxx, and their Sky Train carry on bag is perfectly suited to me.  Great sticky single shoulder strap, and backpacking straps as well.

That’s if for now, time to be productive, and motivated.

Seacoast Dev WordPress Meetup, December 2, 2015

After introductions among a dozen folks we learned we had a mix of developers, users, and those curious about WooCommerce.

WooCommerce

David Long is talking about his experience with WooCommerce and WordPress.  WooCommerce (WC) is the rare, really solid WordPress plugin that is used to create online stores using WordPress.  David had a client with an existing website with static pages and lots of tables.   His task was to convert the site into a catalog/shopping site.  The client didn’t want financial transactions, so WC was used a customer ‘request for quote’ system.  No prices!  The products required an interaction between the client and customers before a sale.  David had to customize WC a lot to turn off checkout, shipping but that’s what is great about WC.  He used TablePress for converting grids of data into product lists.  Excel data was transformed into tables and then integrated into WooCommerce.  David went over the  administrative backend of WooCommerce looking at settings, products, orders.   The customer had a lot of requests and customizations which lead to 41 active plugins, a very high number, yikes.  David was very happy with the plugin that does rollbacks (WP-Rollback).  The combination of the complexity of WC and all the plugins can lead to incompatibilities when there is an update.  Rolling back is a great tool for that situation.

Amanda Giles was up next to show up some code used with WooCommerce.  Amanda likes all the customizable templates in WC.  Amanda is not afraid to roll up her sleeves and get into the code.   We went over all the action hooks and filters (100+) in the templates that allow a programmer to change what’s output, and how the data looks in the existing templates.  Figuring out what template is being used by WC is half the challenge before making a change.  WC is solid product and will be around for a while.  It was just purchased by WordPress.com and WordPress team members are taking rotations through WooCommerce learning the code.

Next month the group will return and hear a talk about the WordPress JSON REST API done by yours truly.

 

 

WordPress, JavaScript, and Me

With the release of Calypso, Automattic has shown their view of the future of WordPress.com and how users will interact with sites.  JavaScript driven applications offer a faster interaction for folks working on their sites.

Time to jump in and learn how to use JavaScript to create interfaces and allow clients to interact with their custom WordPress.org sites that I create for them.

My strategy has been to read some of the better JavaScript books: Javascript – The Good Parts,  and Functional Javascript.  After an overview there, the next step is to use Lynda.com courses and get some hands on experience.  Internally WordPress uses jQuery, underscores, and backbone.  That seems like a good place to start.  Lynda courses on my playlist: Up and running with Underscores, Javascript: Functions, Up and running with Backbone, Up and running with React, and WordPress REST API (WP-API): First Look.

Time to write some code.

Seacoast NH WordPress Dev Meetup – An Open Forum

wordpress-developmentA Seacoast NH WordPress Developers Meetup took place on June 3, 2014 and, due to a last minute schedule change, we had no presentation.  This gave us the opportunity to switch to an open forum, because there’s nothing easier for us than to talk about WordPress development for 2 hours.  Thanks to Alpha Loft on Green Street in Portsmouth, NH for providing our venue.

Custom Templates for Custom Post Types

We started off talking about an issue David Long was having with creating custom templates for custom post types. David found himself generating a bunch of templates to query a custom post type for different meta values on a meta key.   David wanted to re-use WordPress Loop code and not repeat the code in the templates (DRY).  One solution (of a few) was to pass in the desired query meta value in the page URL and use the HTML/PHP $_GET[ ‘value_name’] variable .  Code was then written to grab the value of this variable (with error checking) and pass it to the Loop query.  Now David could write one template to handle all the queries.

(more…)