HTML 5, whats to know

The new web standards HTML 5 and CSS 3 seem to be getting a lot of good press at the moment. So what’s out there for the working web dev to learn from?

Some very interesting demo’s of what can be done are available around the web but I’m in need of some good tutorial recommendations. So what you got that offers more than http://www.w3schools.com/html5/html5_reference.asp

Please share your links in the comments

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

No Comments

Gardening

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

No Comments

Android Emulator Problems

I’ve been having loads of problems getting the Android Emulator that comes with the SDK to load anything. After successfully running it when i made the Hello World App I could never get it running again. Googled the problem and tried everything i read to no avail. However last night I got it running again after I’d had to do a reboot, not something that happens often with a Linux machine.

With the emulator running I managed to get through some of the chapters in Pro Android by Apress , I now have a better understanding of the android architecture and the development environment and I’m now starting to get my head around Resources, content providers and Intents and how they tie together.

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

,

No Comments

Setting up an android development enviroment on FC10

A newbie guide to android development

One of the reasons  I wanted an Android based smart phone was that I was feeling the need to try something different from the daily php based work . It was time to learn something new , something a little exiting and on the forward edge.

Any time access to the web from mobile platform’s is without doubt the culmination of the dream. This is the killer app aspect of the Internet and people are waking up to this reality. Smart phones , net book’s and in the near future pad style devices will change the way we interact with the cloud. By its open nature I believe android will play a big part in this.

First task then was to get the environment set-up.

To do this we need two pieces of software installed eclipse the popular cross platform IDE and  the Android SDK. You will also need to ensure you have Java installed and set-up on your machine.

I tried to set this up using the version of eclipse available to FC10 via Yum but encountered real issues late in the process so I downloaded the classic version from the eclipse website http://www.eclipse.org/downloads/, which just needs extracting and then runs with out any futher installation .

Download the Android SDK from Google and install it

This is easy enough just unpack the download into a directory. Like eclipse the software runs in place

Set up your path

While not an essential step adding the location of the CLI android tools to your path will probably make life a little easier.

To do this edit your ~/.bashrc file and add a line to the bottom:

export PATH=${PATH}:/home/matt/android/android-sdk-linux_86/tools

Install the Android Development Tools (ADT) for Eclipse

Firstly launch Eclipse.

Follow the excellent instructions at http://developer.android.com/sdk/eclipse-adt.html to install the development tools.

Install packages for eclipse

Next you need to install a bunch of packages . In Eclipse, click “Window->Android SDK and AVD Manager.” In the resulting window, on the left-hand side will be an “Available Packages” option. Click that, then click the checkbox beside the “repository.xml” package to select all available packages and then click “Install Selected“. Once this has completed your ready to begin developing your first android application

Create you first application

The traditional starting point for learning any new language is the humble ‘Hello world’ and is android is no different. Follow the tutorial at
http://developer.android.com/guide/tutorials/hello-world.html for a nice introduction to the android architecture.

Set up a connection to your hardware

The hello world tutorial introduces you to the emulator included with the SDK. But if you have an Android powered handset you’ll find it a lot less pain to set up a debug/test connection to your hardware.

To do this first, set your phone for USB debugging.
In your Android phone, go to Settings -> Applications -> Development menu, and make sure “USB debugging” is checked (activated).

Connect the phone to your computer via USB cable.
In a terminal type the lsusb command to list all USB devices.

Identify the VendorID and ProductID of your device

Bus 001 Device 065: ID 22b8:2d66 Motorola PCS

VendorID in my case is 22b8 the ProductID is 2d66

As root type

vi  /etc/udev/rules.d/51-android.rules
to create a new file and paste the following rule into the file

UBSYSTEMS=="usb", ATTRS{idVendor}=="22b8", ATTRS{idProduct}=="2d66", MODE="0666"

Re-connect your phone.
Your phone should be detected if you unplug and reconnect it to the computer.

Restart the ADB server

adb kill-server
adb devices

You should see your device listed.
You can now access your phone from the Eclipse IDE and run/debug applications on it.

Useful links

http://www.mattcutts.com/blog/install-android-on-ubuntu/

http://developer.android.com/guide/tutorials/hello-world.html

http://www.futuredesktop.org/developing_android_apps_on_ubuntu.html

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

1 Comment

Hello android

I made my first android app

hello android

OK its just a glorified hello world but we all got to start some where ;)

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

No Comments

Six useful tips and tools for web developers

As part of my day to day working and reading I often come across useful tips and tools which I  add to my Delicious bookmarks. I share these automatically in the right  hand bar of this site. From time to time I will highlight some of the best and  most useful of these links.

Use JavaScript to move items between two select lists

Html multiple selects are probably the most unfriendly form elements in the html specification as they provide no visual clues on how to interact with them. By applying some JavaScript however you can use them to create an intuitive user experience for selecting  multiple values. The link below will take you to a nice tutorial with code samples and downloads that can easily be integrated with some CSS and back end scripting to produce a powerful select control.

http://www.mredkj.com/tutorials/tutorial_mixed2b.html

Fixing your footer with CSS

One of the most frustrating aspects of CSS based layout is getting the footer of a site to stick to the bottom of the page no matter the screen size or content on the page. This link will take you to a great article that describes how to achieve this in a cross-browser friendly way. It even works with IE6.

http://fortysevenmedia.com/blog/archives/making_your_footer_stay_put_with_css/

Fixed table headers

Tables are an essential tool for displaying data in web applications but can become difficult to understand and interpret if you have to scroll down to see lots of data. By fixing the header if a table in place and just scrolling the data your tabular data will be far more user friendly and easier to understand.  The example located at this link will show you how to achieve this by applying some CSS to your table header and body.

http://www.imaputz.com/cssStuff/bigFourVersion.html

Toggle visibility of a page element

Some times you  need to make the display of information optional . This link illustrates a number of methods to do this.

http://www.dustindiaz.com/seven-togglers/

Maximum and Minimum height and width support in Internet Explorer

IE6 doesn’t support them and IE 7 only supports them when you declare a strict DocType. This article describes how you can use some proprietary IE features to simulate these incredibly useful features.

http://perishablepress.com/press/2007/01/16/maximum-and-minimum-height-and-width-in-internet-explorer

Test your PHP regular expressions

Regular expressions are a powerful programming tool . I’ve used many test platforms when creating regular expressions but for designing expressions for use with PHP’s  regular expression functions this tool rocks.

http://www.spaweditor.com/scripts/regex/index.php

Do you have a useful tool or tip you’d like to share? Why not add a link into the commonts of this post.

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

, , , , ,

No Comments

Living with the Android

In an earlier post I mentioned my plans to get a new smart phone running the Google Android operating system. After some deliberation I settled on the new Motorola DEXT phone.

motorola dext

motorola dext

The DEXT is  a nicely sized handset that comes complete with  a slide out physical qwerty keyboard with nicely bevelled buttons that allows for easy two thumb typing. The touch screen interface provides access to 5 home screens much like the multiple desktops that are a feature of many Linux  Desktops. This provides and easy to organise and uncluttered interface to access your most used applications.

It has all the features you would expect to find on a modern mobile phone, such as a camera for still and video and a decent media player as well as some nice extras like  GPS and WiFi support.

Billed as the ‘first social phone’  the phones address book and messaging systems are fully integrated with a number of social media and cloud based services making the whole social networking experience seamless and the thousands of applications available in the Android market place allow you to easily expand the phones social networking functionality. Obviously being an Android phone integration with Google’s services such as Gmail, Google Calender and Google maps is excellent. It will interesting to see how the new Buzz service Google launched this week and supported in android version 2 will  integrate in any future  upgrades to the installed operating system.

My only criticism is that the battery can take a pounding due to its always connected nature especially if using the WiFi or you have the GPS turned on. However this is helped by the fact that charging is via the new micro USB standard so at work or home  I can easily keep the battery topped up by leaving it connected to a USB port on the PC. An in car charger will be a wise buy if you intend to make use of the GPS with any SatNav application.

In the earlier post I highlighted what I felt were some of the limitations of using the mobile web on a handset rather than via a netbook as my colleague does. So does this new generation of handsets address these limitations? The answer would have to a very resounding yes.

Using the new phone with some additional applications downloaded from the market place I have been able to do the following.

  • Surf the web using the built in browser either via the 3G network or on any available WiFi network A simple but effective zoom option even allows for the resizing of non fluid pages to avoid the horror of horizontal scrolling .
  • Read and manage all my personal email through my Gmail account.
  • Write this and other posts via the Wordpress Android application.
  • Login to and control my home server via a SSH terminal application.
  • Carry out some work for a friend on his remote web server again via the SSH terminal application.
  • Upload pictures taken on the phones camera to my Flickr and Facebook accounts.
  • Carry out micro blogging tasks such as posting to Twitter  or updating my Facebook status.

Offline I’m now using the phone to store all my passwords in an encrypted vault application and to read and edit documents in common formats such as .doc and .pdf.

With the hardware in place I am now looking forward to getting an android development enviroment setup on my home machine so I can investigate the writting and building of some homebrew applications to fulfill some perosnal wants. It’s definatly an interesting time to be a web developer.

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

No Comments

php cli script for automatically updating your dynamic DNS record.

So I brought my son an Xbox 360 for Christmas and after a few teething troubles with the hardware he now comes home from school and jumps onto the Xbox live service to chat and play with his friends. I’m cool with this however it did cause a few problems on the network level.

Firstly Xbox live makes use of port 80 and every time he turned it on my web server, with this site on it, would drop out despite the port forwarding rules set-up in the router. This was solved by editing the httpd.conf so that the server only listened for requests on port 80 of the servers internal ip address.

The other problem encountered was that every so often the Xbox live service would just die and the only way to get it back was to restart the router. This in turn would lead to the isp assigning a new public IP address. At this point obviously my DNS record would become stale. Getting rather fed up with losing access to the server while at work I decided to write a php cli script that would run every 15 minutes via cron to check the public IP address of the connection and if needed update the remote dynamic DNS service I use. Read the rest of this entry »

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

, , , ,

No Comments

Remote working in the 21st Century

The snow and big freeze that affected the UK recently meant that for a week I had the pleasure of working from home.

Not that this in itself is anything unusual having spent 6 years working as a self-employed developer running ,with a partner, a small web service company from our respective living rooms. This however was my first real experience of  how it works being part of a larger development team in a corporate enviroment.

In order to effectively work from home the first thing needed was access to the development network I use on a daily basis. To facilitate this my emplolyers have very kindly supplied me with a Windows Vista laptop configured to connect via IPSec to our VPN.

The native Remote Desktop Connection program allows me to access the the the two VM windows XP machines we use for testing. Putty gives me shell access to the development servers and Vim our inhouse editor of choice. I’ve supplemented putty with a program named putty connection manager which wraps putty into a tabbed interface making it much more like the tabbed konsole I use on the KDE desktop normally.

An install of the windows PSI IM client on one of the VM’s completed the setup and allowed me to chat with the other team members.

While not as productive as being sat at my office desk this setup has proved valuable. It allowed me to safely work without the need to venture out into the difficult weather on what would have been a very difficult commute and continues to allow me to put in overtime without the inconvinience of getting home at a very unsociable hour.

Frustrations were few . Putty’s select to copy – right click to paste behaviour caused a few choice words and the need to logout of the VPN every two hours to avoid getting locked out caused a few frantic moments racing to save and logout. And despite the 6 years of working from home I did find the distractions at home a little difficult to deal with.

Could i do it everyday ? No but for occasional access when needed it’s fine.

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

No Comments

Mud and Ice

The most prominent parts of my solo ride today. Determined to start the new year with a ride I loaded the hardtail into the car and headed over towards the signal hill trails.

On arrival it was instantly obvious that the FC have been busy with a large part of the hill up from the car park being cleared of trees as well as the lower run area that has seen us lose some old favourite trails. Even the foot path up from the car park has been mangled by the work.

Icy trail

Chopped to ribbons :(

Undaunted I hacked up to the top of the hill and set off on the squirrel trail from the lookout down to the timber stacks. Felt sketchy as hell at the top all mud and slime but I soon settled into the flow on the traverse of the hill that was until I came to the frozen bottom section, a deep rutted run down that had ice in the ruts and was frozen solid. Still all good fun though.

At this point the month and half of not riding intersected with the ‘not over the top’ Christmas indulgences had be breathing out of my arse. So a stop to tweak bars ,I changed the stem the day before, and catch my breath before I headed off back into the woods aiming to climb back up signal hill and do another run down to the car park.

How ever on the climb back up I couldn’t help but notice that the end of an old trail now had a matching start on the other side of the road. Having lost so many trails this last year to the FC harvesting I just had to take a look. 10 minutes later I emerge back on the road the start of a new trail has begun . Looks like it could be a nice twisty bit of singletrack through the recently thinned trees with a little bit of pixie dusting.

A quick climb then it’s back down the edge of the hill aiming for a last blast down the foot path to the car park. But woh just as I’m enjoying the open feeling as the top of the path twists down the hill  the path  is chopped to ribbon.  Huge great ruts across the trail necessitate a quick demount and a a slippery hike with the bike back to the start of the ride.

But despite the good and bad today it sure felt good to be back out .

The Hardrock

The Hardrock

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

,

No Comments