DraftCode – PHP on iPad


I’ve written a lot about how I program on my iPad, and DraftCode, an offline PHP development app for you iPad and iPhone, takes that to the next level. PHP code in the app is executed using the standard, open source PHP version 5.6.30 (at time of writing), and this includes all the extensions you typically use such as MySQL, FTP and XML. Another great feature of DraftCode is that it includes a WebKit preview of your code, so your app looks exactly like it would on Safari. The app will alert you of errors in your code, and you can also run your code when you are offline.

DraftCode is a completely self powered and contained environment for editing PHP on the go, and you don’t even need and internet connection or a server to do this. The app supports PHP offline editing, which is perfect for making theme changes, plugin changes and fixes on the bus, on a walk or elsewhere. The app has a very shallow learning curve – the interface is very simply, just showing files and folders that you have open. The environment in which your app runs is standalone, in the app and self contained, meaning that you can develop on the go, without the need of internet. The advantage of this is that your web app runs as if it was on the internet, with working cookies, forms and sessions.

Getting files into DraftCode is easy. DraftCode includes a Document Browser that allows you to access iCloud, Working Copy, Dropbox and other apps you have on your iPad. You can also export the files when you have finished making the changes.

Of course, DraftCode also offers syntax highlighting for your PHP code, and two themes – a light mode and a dark mode. The app features extensions that allow you to insert common code snippets and characters that are a struggle to find on the keyboard quickly and with ease, only with a few taps. If you are using an external keyboard, good news. DraftCode allows you to use keyboard shortcuts.

When you run your code, an inspection panel shows you the PHP error messages and warnings that occur in your code. The app shows you the problems are in the code, and highlights the issues. You can also inspect the cookies in each session, as well as purge them to start again fresh.

Another advantage of DraftCode is that it includes PHP apps such as WordPress, PHPMyAdmin and similar apps, allowing you to install these as packages.

I really recommend checking out DraftCode, especially if you develop using PHP. You can check out DraftCode on the App Store here.

Thanks for reading!