Month: February 2013
-
WordPress loops: with_posts() is my way of dealing with them
One of the most boring, cumbersome and dangerous things with WordPress is getting and working with posts in custom loops. A common situation is like this: That’s a bit cumbersome I think. Do I really need to do that while-thingie, that the_post()-method-thingie and that wp_reset_postdata()-thingie each time? It feels a bit… repetitive. And dangerous, since…
-
How we created an API to our coffee machine and how we abused the 418 I’m a teapot
We needed(?) a REST API to our coffee machine. So I put a Twine next to it, and made it call back over HTTP to a webhook on one of our servers. This webhook logs all the temperature changes, and now anyone can query the dataset via our REST API. It just returns if the coffee…