Understanding REST

As a developer you may have heard of the term REST, you may have worked with or created an API that was called RESTful. However was it actually REST or was it missing some requirements? Below I will walk through what REST is to the best of my knowledge.

Website Request Forgery

A website request forgery or better known as Cross-site Request Forgery (CSRF)

Protractor, Saucelabs and File Upload

I’ve been doing quite a bit of work with Protractor recently using both Saucelabs and browserstack, up until now Ive never had a need to do file uploads. I have usually worked around any reason to upload files due to known issues people have had with uploading files. For my Uni project unfortunately I can no longer do workarounds and now need to resolve issues that have plagued others.

Unit Testing with Web2py

I am a big fan of web2py, however it does have its short comings one being the difficulties of unit testing. This is actually not surprising, it was only in the last 18 months or so the web2py framework got serious about doing unit testing, which means unlike other frameworks testing wasn’t at the forefront of the development. Fortunately there are several ways to do this which are surprisingly simple, however they do require a particular set up. Before I start I should make it clear unit testing isn’t the only way to do automated testing so do not be fooled in thinking this is the magic silver bullet.

Playing around with Youtube and Speech Recognition

I’ve had an interest in learning the Speech Recognition API for sometime, in this time I have seen some nice uses of the API. So in my spare 30mins I decided to develop a very simple application which would allow a user to control Youtube video. Controlling video seems to be fairly popular first attempt at using the API, it’s also pretty easy to get setup in a short period of time.

My experience with Web2py

I have been using Web2py for over a year at the place I work, and I believe its time to give my thoughts on it. I believe I am in a unique position to give my thoughts on this working on small projects, high traffic sites, and larger scale projects.

Is jQuery needed anymore ?

I’ve recently been thinking about completely ditching jQuery. The reason being its main purpose is no longer required. The reason jQuery came to be was to allow a single API to manipulate the DOM easily. Before we had to use a syntax like this:

Google maps detecting markers in a particular boundary

Its been a very long time since I last used the Google Maps API, think v2 of the API had just come out of Beta when I last used it which shows just how long ago it was. Thankfully v3.0 adds many cool features and makes things a hell of a lot easier. One of those things is being able to make a radius boundary, based off a marker or even the persons location. There are several drawing (overlay) like options for google maps in this example I am using the circle. Each overlay object comes with a getBounds method which allows us to see if a particular latitude and longitude is contained within that boundary. In my example I am detecting whether a draggable marker (after being dragged) lives within this boundary.

Zend and the Youtube API

The Zend Framework comes with a rather handy module called GData. The GData module handles basically everything Google Apps contain including support for the Youtube API. Youtube’s API documentation when first viewed can be rather scary to look at but thanks to the Zend_GData libary a lot of the heavy lifting has been done. The purpose of this post is to document how to use the browser based uploads to a central user and set particular permissions on the video uploaded.