Posts related to: How-To

101: How to fetch a git pull request

  You should test pull requests locally before you merge them with your code. Fetching a pull request from a remote repository is simple, just do: In your local project folder, do: git ls-remote You'll get a list like this: From https://github.com/soderlind/myproject.git 15438eca8b7f62f371985823fe6fa8c60d7a3b50 HEAD 15438eca8b7f62f371985823fe6fa8c60d7a3b50 refs/heads/master 4abd4e393cc1bc57af576a67a1a56b3dae6ecabd refs/pull/2/head e05af83eeebb01e52d8b42f24c570c8290e0b351 refs/pull/4/head...

WordPress, how to modify the HTML of an oEmbed link

Introduction Background: EPiServer is the CMS for the Norwegian Government main site, www.regjeringen.no and we use WordPress for more ad hoc sites. Task: Based on the design guide for regjeringen.no, add 23 video to WordPress. 23 video supports oembed, so adding it is easy <?php // replace NAME with your...

Continuous Deployment from GitHub to WordPress Azure

  TL;DR: Create a .deployment file and push it to GitHub: [config] DEPLOYMENT_TARGET=D:\home\site\wwwroot\wp-content\themes\my-theme At work we are developing a new theme for our WordPress sites. We use git and GitHub, and to test changes we do continuous deployment to a free WordPress site at Azure. Setting up contious deployment from GitHub to...

Debug WordPress with Sublime Text 2 and XDebug

XDebug installation Run the Xdebug wizard and follow the instructions.I develop on Mac OS X Mountain Lion, and phpize complained that autoconf is missing. Cannot find autoconf. Please check your autoconf installation and the $PHP_AUTOCONF environment variable is set correctly and then rerun this script. Luckily Sebastien has the recipe on how to...

WordPress and Pow

Here is my second take on running WordPress and WordPress Multisite locally on my Mac (first is here). I just discovered Pow; "Pow is a zero-config Rack server for Mac OS X. Have it serving your apps locally in under a minute", and my first thought was "can I run WordPress on Pow?"....

WordPress plugins and permalinks, how to use pretty links in your plugin

I'm working on a plugin, Read Offline, and one of the wishes was for url friendly links. After intensive googling, here's how I did it: "My Permalink Demo" plugin: <br /> &lt;?php<br /> /*<br /> Plugin Name: My Permalink Demo<br /> Plugin URI: http://soderlind.no/archives/2012/11/01/wordpress-plugins-and-permalinks-how-to-use-pretty-links-in-your-plugin/<br /> Description: Demo plugin to show...