All Thumbs and No Fingers A bucket for all things

7Sep/090

Secure Copy How to

Heres a rough and ready introduction to using the power of SSH to perform a secure copy of a file or directory between computers.

> scp

usage: scp [-1246BCpqrv] [-c cipher] [-F ssh_config] [-i identity_file]
[-l limit] [-o ssh_option] [-P port] [-S program]
[[user@]host1:]file1 [...] [[user@]host2:]file2

So how does this matter for me well if you wanted to move a file from a server called Mojo.com to a server called Louis.com you'd enter


> scp file.txt my_login_name@louis.com:remote_directory

or if I want to copy a folder:


> scp -r my_login_name@louis.com:remote_directory my_files

Hope this helps.

By the way for those on Windows Penguinet has scp built in with a nice looking file browser/selection UI.

20Aug/090

Rails localisation bug

I've just gone through the challenge of working out what was wrong with the following piece of code:

<% form_tag :controller => '/' do %>
				<%= t(:'txt.language') %> <%= select_tag("locale", options_for_select(LOCALES_AVAILABLE, I18n.locale), { :index => nil, :o nchange => 'this.form.submit()'}) %>
			<% end %>

Our client reported that on a signup page where they choose an alternative language it got redirected and they could never reach the page in their native language.

How can this happen you might ask?

Well the request includes some values within the url which are used as a key. Only if the key is valid is the controller allowed to complete the request. The issue is the combining of maintaining the key and switching the language.

As it happens its a very simple fix and was pointed out to me by Juliana.

<% form_tag :controller => request.request_uri do %>
				<%= t(:'txt.language') %> <%= select_tag("locale", options_for_select(LOCALES_AVAILABLE, I18n.locale), { :index => nil, :o nchange => 'this.form.submit()'}) %>
			<% end %>

In this fixed second example the alteration for the controller has been updated to direct the language selector to the controller of the current page. The documentation for this suggests that its broken on IIS (really should you be even trying to use this?) in fact I found that the source has had a significant amount of work go into it to work around the issue and even make it work on that webserver. Its a great little solution to ensure that the reloaded page is returned to the user in the state it was with the addition of the correct language.

16Aug/090

quiet afternoon – try this…

Felt like a little distraction and a link to this popped up on twitter so I just couldn't resist having a play909

Try it for yourself over at http://www.themaninblue.com/experiment/JS-909/

18Jul/090

Rails – if I new when I started what I know now?

How would you answer this question?

I've been using rails for development of applications for what feels like a long time. I wasn't in the pre 1.0 crowd but I did spend many days hacking around in cgi scripts to make the website run in apache so I do feel like I've been here a while.

As brackground I came up through C++ operating systems development (loved it), delphi (blah blah), then on to Java (which I never liked) and into web technologies and scripted languages.

My day job doesn't allow more than 10-20% of development anymore (by choice). So although I'm still keen the time is not usually available. Interesting this has quite an impact on way you program.

For one thing change is an issue, changing technology requires great investment just to achieve the simplest of tasks. Something I can not afford.

Rails has always been for me about using a good language to enjoy my craft. For a variety of reasons enjoyment does enable better results. Further the rails stack goes all the way through the systems I need to utilise - database, ORM, MVC, and client side (javascript + tempaltes). By understanding one language and leveraging the well written information on Rails I avoid needing to care about most other areas.

However the trade off is that sometimes it just can't do what you need so some custom javascript or SQL query is required. I've never been particularly strong at either. So that usually gets less of my attention. I break the rules at this point and do what needs to be done to get the job done. Many in the community would disagree with this approach. And I applaude them, they are correct but realities/needs/timescales differ. As yet I've never had a hard time sleeping at night!

In many cases the Agile method of working is excellent. I was slow to value the testing framework built into the system. For a while I played with Selenium (amazing solution) but I have a regularly changing interface and could never get beyond the issue that tests broke because they were out of date (not the application was broken). Shoulda on the other hand has been very helpful as has rcov.

Of course the testing approach when time constrained is brief in some aspects. And not by design. Its just their is no documentation on how to achieve certain things - e.g. validate a upload dialog can import, parse and process an zip file + manifest. Of course this is domain specific but validation of file uploads is not, and as yet I've not found anything on this.

Google is a strong friend when there is trouble. I've found many articles and blogs to guide me. Although sometimes in the wrong direction - engines. There coming back and I'm scared I found them confused and difficult the first time around so I wonder (without a name change) who will be listening?

Would I do it all again: yes. In fact I'd do more. Its a fantastic stable platform which has I believe shaken up the entire 'intelligent' web development community along with its cousins DJango I'm looking at you. I'm sure that even in these difficult times we'll continue to see this is a fertile ground with many innovations and improvements yet to come.

Looking to the future I'm very aware of the tiny amount of knowledge I have. I've spoken to many in the community who are streets ahead. I wonder if I'll ever get to where they are? Do I need to perhaps not, if anything I can say that even with a small amount of knowledge and clear understanding of the principles (which you can pick up very quickly) creating the next application is available to almost any developer.

If only rails could create cross platform desktop applications?


Tagged as: No Comments
11Jul/091

Does accessible flash truly exist?

For a designer or software developer the appeal of flash content is compelling. It provides a strong interactive capability to deliver engaging media over the internet consistently across all browsers which have the flash player plugin installed. The speed and visual nature of the authoring tools make is quick and easy to work with. However the same problems crops up time and time again: that of your client wishing to provide accessibility, for me this usually entails complying with the W3C AA guidelines.

If we consider the accessibility specifications and tools available it is quickly apparent that flash is lacking in this regard. Understood the paper work is in order from both Adobe, the browser manufacturers and main assistive software providers. But have you actually tried it?

In this 2 part series I will comment on first hand experience developing solutions to provide accessible flash and contrast this against the information available from webAim who have taken great care to survey validated users on their use of flash websites.

Finally I will provide some bold recommendations on how to navigate this difficult field to improve the user experience for all concerned. Please don't take my approach as correct it stems from years putting large amounts of content together and trying to meet clients opposing requirements.

Screen Design & Presentation

Lets start by considering the quick, obvious and beneficial to all wins: Organise your screen design so that the layout is easy on the eye, visual ques and information is well positioned, logical and correctly marked up.

Flash: Strong Support

How: By organising the materials on screen in a clear, consistent and meaningful way is easy in even the oldest of flash players. Careful selection of colour palettes is essential and avoiding the use of text on graduated backgrounds is good practice. Other requirements including ensuring that any content presented to users is not time bound, this ensures that those who need longer to read are not disadvantage.

Oh and please please no blinking, moving, animated text.

Scaling

With more recent version of flash comes the introduction of scalable vectors graphics support. This allows content to be scaled to any size without loss of any quality. For those requiring accessibility options taking advantage of this feature is desirable. Unlike providing text only resizing controls the entire flash content is resized. This approach ensures that the use of scroll bars, text overruns, pagination are avoided.

The Timeline

Flash operates very differently to traditional web development. HTML is largely static and has no support without complex programming to support a timeline. A timeline allows content, actions and experiences to be triggered in response to a time event occurring.

As a result this can provide engaging content however it can also severely limit the accessibility capability.

So what to do...

Consider the impact your timeline events will have on users who may need longer to take in the content. Perhaps the use of a pause, rewind/replay controls will provide all that is required to ensure that the widest range of users can access the content.

In the next session I'll continue the discussion and look at keyboard accessibility, closing down of the 'open web', navigation and interactions. Also included will be the use of video and audio and how to handle screen readers and where there may be the case for alternative formats such as separate accessible formats such as a essay document.


18Jun/090

Requirements are not the measure of success but the beginnings of a conversation.

15Jun/090

IE 6 will out live IE 7 – and I have proof

Microsoft have gone and released IE 8 (19/03/08) and with it finally gained ground on being a ’standards conformant’ web browser. This is excellent for the average user and long overdue. In fact it should in time make our lives as web developers easy simply because cross browser checking should be less demanding - will we ever be able to test in one browser?But then I was left thinking about how quickly this would be adopted particular within the elearning industry and I realised it may cause an interesting issue:Our user base has 2 principal operating systems

  1. Windows XP / Vista
  2. Windows 2000

The vast majority fall into the Windows XP group and therefore have the ability (from the manufactuer not necessarily company IT) to update. It is not unreasonable to assume the Microsfot update tool will push this out shortly. So everyone currently on IE7.0 moves on to IE8.0 probably within 6-12 months. But hang on a moment what about all those people on Windows 2000. There is no IE7.0 for them and certainly therefore no IE8.0.
Consequence: IE 6.0 is actually the last option here without an operating system upgrade which lets face it is unlikely if the machine has been around this long.So it therefore becomes conceivable that we’ll be left supporting IE6.0, 7.0 & 8.0 in the very near future, with decreasing attention given to IE 7.0.

And the proof...

http://ajaxian.com/archives/ie8-vs-ie6-rise-of-the-new-machine

15Jun/090

Firefox collections plugin

Firefox has released a useful extension which I’ve been hunting for for some time now.

Simply: the ability to define a collection of plugins and install all of them with a single instruction. In fact they’ve gone further than this and allowed us to create collections of plugins which are available for others to click and grab. It really is simple and very useful.

Head over to https://addons.mozilla.org/en-US/firefox/collections/editors_picks to see more. And if you’d like to access my all things google related collection check out the following: https://addons.mozilla.org/en-US/firefox/collection/cdb63c71-9c70-f92a-5d80-554beb600806

7Feb/090

HTML meta data – MSThemeCompatible

Be aware this <META HTTP-EQUIV="MSThemeCompatible" CONTENT="no"> which is there to disable the Windows XP teletubby theme causes Safari and Firefox to completely remove scrollbars.

The issue is tracked in a Firefox bug report.

7Feb/090

Localising a rails app – in 20 mins

I had an existing rails app which has nearly completed and during its development its been upgraded from 1.2 all the way up to 2.2.2. Anyway I sat down with the latest updates and figured that acts_as_paranoid and will_paginate needed to be altered but beyond that it seems it just worked.
Suffice to say I'd managed to configure the locales and make heavy use of google translate to begin adding an alternative language.
It is impressive how easily this has come together.

Pages

Amazon Favs:

new posts

My Photos

Bright blue skies

Sarah in the hamock

We won the drinks list!

Charlie's morning feeding ritual for sooty

More Photos

tag cloud

accessibility apple astronomy navigation observatory british beck bug council design development dunning kruger psychology elearning facebook flash flickr browsing web photos pictures general i8n induction wordpress opensource resuse iphone itunes javascript languages learning localisation localise mehrabian motorcycle music myth my_learning parking plan programing programming proxy rails rest socks ssh star synth tech iphone travel theme threshold money value spending tips health weight obesity advice welcome words

categories

Blogroll

Life is too short

Friends