Code

The concept of organising your JavaScript to this level may seem alien to some, but the advantages are limitless. This greatly improves maintainability and scalability, and as JS gets more and more advanced, so will the structure (from an architectural point of view).

Some of the best browsers to date have improved their JS rendering engine so much that you can basically build a full fledged application and wouldn't be able to tell the difference between a stand-alone app and the one running in your browser - amazing huh? Have you ever heard of OpenGL? Well, they're also coming out with WebGL, which will obviously be powered by JavaScript - say bye bye to flash and hello JS. If this alone doesn't convince you that it's growing extremely rapidly, then I don't know what will.

jon | April 22, 2010 | Comments (0)

The new OAuth protocol has been quick to becoming the standard for accessing secure data via APIs - it's also mandatory on some sites, or soon to become.

I'm about to show you a 3-legged process for obtaining an access token, which will give you access to the persons account that approved your request. With this token, you'll be able to update their status, and pretty much do what they can do, minus altering crucial account details.

jon | April 22, 2010 | Comments (0)

One majorly annoying issue that I stumbled upon, was the fact that I couldn't send multiple attachments using Intents to the Google Mail app. The quickest way around that was of course to compress all of the files into one (ZIP).

After searching around online, I didn't really find much on zipping files on your Android device - most of the articles were for standard java applications, which assumed that all your files were in the current directory that you wanted to zip.

So, I used what I could and whipped up my own wrapper class that allows you to easily zip files in Android!

jon | April 22, 2010 | Comments (6)

Have you seen other applications with Buttons (or other views, but mainly Buttons) that stay in one spot, even if you're scrolling through a list? These are commonly known as floating Buttons or Views.

This is actually used a lot on websites as well, and they may seem hard to produce at first glance, but it's actual quite easy.

I'll run you through an easy application that uses one floating button within a ListActivity, which is aligned to the bottom right of the screen - on top of the ListView.

jon | April 22, 2010 | Comments (0)

This is a subject that's seldom talked about, but can be quite important. The NDK basically allows you to port any native C/C++ code/libraries into your Android project, using JNI (Java Native Interface).

I'm going to go through a quick and simple example of how you can display "Hello World" in your Android application using some native C.

jon | April 22, 2010 | Comments (0)

The Android SDK makes it very easy to send emails from an application, but unfortunately, that's only if you want to send them via the built-in mailing app. For most situations this works fine, but if you want to send something out and don't want any input/intervention from the user, it's not as easy.

In this article I'm going to show you how to send an email in the background without the user even knowing - the application will do everything behind the scenes.

jon | April 22, 2010 | Comments (1)

The process for capturing, saving and displaying an image in Android can be quite annoying, especially if you want it to work across all devices.

With the release of the Sense UI (an HTC creation), it's made things 1 step more difficult. So, the reason I'm writing this article is because I've been stuck on this same issue for quite awhile, and there isn't enough information out there to let us know why it simply won't work.

Simply put, the Sense UI handles things differently when it comes to saving a new image after an intent was called (ie. new Intent(MediaStore.ACTION_IMAGE_CAPTURE)). In this article I'll show you how I overcame this problem and walk you through my code.

jon | April 22, 2010 | Comments (2)

Have you been trying to find a quick and easy way to format dates from a String? It can be quite tricky with Java (if you're new to it). So, I'm going to go through a few very simple steps to accomplish just that.

jon | April 22, 2010 | Comments (0)

If you're maintaining a blog and want a way to highlight code within your articles (for ease of reading), then this article may interest you.

I can't even begin to say how annoying it is to read a large chunk of code that has no color highlighting - this will improve readability and traffic to your blog (or whatever you decide to use it on).

jon | April 22, 2010 | Comments (0)

The Zend Config component is mainly used to access configuration files, but can also be customized to suit many different situations.

In this article I'll be going through an example of how you can extend Zend_Config and customize it to your liking (or my liking in this case). You'll also need to know (or should know) a little bit about the Zend Framework to understand what I'm talking about, and how to fit it into your projects.

jon | April 22, 2010 | Comments (0)