Wednesday, 10 November 2010

3 Days In: Some RockMelt Tips and Tricks

UPDATE: I have 50 Rockmelt invites, on a first come, first served basis. Click here for your invite! Sorry, all the invites were used in only 45 minutes...

It's been almost 3 whole days since I got hold of RockMelt, a new social media web browser. It has been fun playing with the new features, and I've learnt a few tricks that have made it more fun. I thought I'd share them here. This isn't a complete list, please let me know if you want to contribute your own tip.

Learn the lingo, get an edge

An "edge" is a simply a toolbar that appears at the edge of the screen. RockMelt has two edges out of the box, the friend edge (on the left) and the app edge (on the right).

The friend edge will show you either your friends that are online, or your favorites (more on that later). The app edge integrates with Facebook and other apps to shows you feeds (perhaps it should be called the feed edge?). Common feeds to have here are your Facebook feed, your Facebook notifications and your Twitter stream. You can also consume other feeds such as blogs or news. Read on for a easy way to choose your feeds.

Side note: Graph geeks amongst you may well have though an edge was a relationship between two friends - but no, in RockMelt, it's just a toolbar.

Share a link with a friend, in a couple of clicks

Like a page you're looking at? Want to share it with someone in particular? That's pretty easy.

Drag and drop the URL from the address bar (using the globe or the padlock ) onto your friend in the friend edge on the left. Then choose one of the options:

Type your own message, and your done!

Open search results in way that suits you

Take a close look at the search results pane, and you'll see two features you may find useful:
  • If you would rather open each search result in a new background tab, click on the small plus icon that appears when you move your mouse over each result.
  • If you decide you want to see your search results in one tab, just like a search in most other browsers, then click the "View in tab" link at the top.

I also use the arrow keys to quickly preview each result, then the enter key to go there.

Let RockMelt feed you

After a little while, RockMelt can start suggesting new feeds for you to consume. Use the browser for a few days, then use the the "Add Feeds" button on the app edge (on the right) to have RockMelt automatically suggest feeds for sites you've been using. Click the star next to a feed to add it to the app edge.

Get friendly with the address bar

You can get to your friend's Facebook profile pages easily in RockMelt. Just type their name into the address bar, click on the suggestion, then click on your friend's profile image that appears.

Pick favorites

Chances are you've got a lot of friends. Cut down the noise and choose some favorites. The easiest way is to add favorites is to:

  1. Click on the star in the online/favorite toggle button at the top of the friend edge.

  2. Click the "Show Friends" button towards the bottom of the friend edge.

  3. Use the search box to find the friends you really want to know about, then make them a favorite by clicking the star next to their name.

  4. (Optional) Unfriend everyone else. :-)

Business up front, party in the back

Being so connected to your friends is great, but what if you need to focus on your work and not get distracted? Use the Ctrl-Shift-Space key combo to take the edges off your RockMelt. Think of it as a modern-day Boss Key. If you want to hide just one of the edges you can use the Ctrl-Shift-LeftArrow and Ctrl-Shift-RightArrow to control your "friend edge" and your "app edge" respectively. The same key combo will bring them back.

Use your invites, wisely

RockMelt seems to give out an invite or two every couple of days (so far!) It also very cleverly suggests friends that have requested an invite, so hook a friend up, send them an invite - you're sure to get more. Use the "Open Invites" button to send invites to the friends who you know really want one.

Monday, 25 October 2010

virtuwell launches

Note: The opinions expressed in this post (and all others) are my own and are not necessarily representative of those of AKQA, HealthPartners or any party involved in virtuwell. Please read this press release for more information.

Today is a good day. This morning, at around 7am PST, HealthPartners launched an application called virtuwell. It was created in partnership with AKQA (the company I work for) over the last 15 months or so.

The premise of the application is simple. If you or your kids are feeling sick and you are short of time, or perhaps if you don't have insurance, then virtuwell may be for you. It offers online diagnosis and treatment (including prescriptions) at a very affordable cost - it may even be covered by your health plan.

As Technical Architect, virtuwell was definitely the most challenging project of my career. We were responsible for developing the entire application, and had to meet the strict security and quality requirements that come hand in hand with a healthcare app without sacrificing a clean, friendly user interface. On top of that, I've had to master an entirely new technology stack. We have all learned a lot.

As a recent arrival in the USA, I have barely began to understand the challenges facing the health system here, but I am proud to have been part of a passionate and dedicated team that has made strides towards making healthcare more accessible to all.

It is also my mother's birthday.

As I said earlier, today is a good day.

Friday, 18 June 2010

Alfresco 3.1.1 and paragraph tags

Right now I am getting to grips with the finer details of an Alfresco v3.1.1 installation. It has been fun*.

Today's quest was all about stopping the TinyMCE plugin that Alfresco uses from wrapping absolutely everything in a <p> tag. Usually I love <p> tags. Way more than I love <br>tags. But not all content entered through a CMS should be wrapped in them.

I found this bug report, which mentioned a rather drastic way of fixing it, but also gave some clues as to another, less invasive, way. The hunt was on. A few hours later (it would have been a few minutes if I had thought to clear my browser cache), I came up with the following:

(DISCLAIMER: The following changes will be lost if you upgrade/replace your Alfresco installation. But since this issue doesn't occur in any other version of Alfresco, that should be ok.)

Step 1: Open up <tomcat>/webapps/alfresco/scripts/ajax/xforms.js

Step 2: Find the definition of alfresco.constants.TINY_MCE_DEFAULT_SETTINGS (it is near the end) and change it to be:

alfresco.constants.TINY_MCE_DEFAULT_SETTINGS =
theme: "advanced",
mode: "exact",
plugins: alfresco.constants.TINY_MCE_DEFAULT_PLUGINS,
width: -1,
height: -1,
auto_resize: false,
force_p_newlines: false,
encoding: "UTF-8",
entity_encoding: "raw",
add_unload_trigger: false,
add_form_submit_trigger: false,
theme_advanced_toolbar_location: "top",
theme_advanced_toolbar_align: "left",
theme_advanced_buttons1: "",
theme_advanced_buttons2: "",
theme_advanced_buttons3: "",
urlconverter_callback: "alfresco_TinyMCE_urlconverter_callback",
file_browser_callback: "alfresco_TinyMCE_file_browser_callback",
forced_root_block: false,
force_br_newlines: true

Note the two last lines.

When you are done, all you need to do is clear your browser's cache, and go edit some web content in Alfresco. Anything you create from now on will no longer be wrapped in the usually wonderful <p> tags.

*This depends on your definition of fun.

Wednesday, 16 June 2010

New version of FBConnectAuth released: 1.0

One year on, I've just released a minor enhancement to the tiny open source project I created called FBConnectAuth - Facebook Connect Authentication for ASP.NET.

This release contains two enhancements:
  • It supports Facebook's new Graph API Javscript SDK (but remains backwards compatible)
  • It works in partially trusted environments
It is specifically targeted at .NET 2.0 (as was the previous release) for the benefit of those who don't have control over their production environment.

Interestingly, I noticed that the new Graph API requires the use of the Facebook Application's "Application ID", rather than "API Key". This means that an example of using FBConnectAuth looks with the Graph API like this:

//Note this is the "app id", not "api Key"
FBConnectAuthentication auth = new FBConnectAuthentication(appId,appSecret);
if (auth.Validate() != ValidationState.Valid)
// The request does not contain the details
// of a valid Facebook connect session.
// You'll probably want to throw an error here.
FBConnectSession fbSession = auth.GetSession();

string userId = fbSession.UserID;
string sessionKey = fbSession.SessionKey;

//This is the Graph API access token
//(available only when using the Graph API)
string accessToken = fbSession.AccessToken;

// The above values can now be used to communicate
// with Facebook on behalf of your user,
// perhaps using the Facebook Developer Toolkit

// The expiry time and session secret is also available.

If you are interested, go take a look.

Tuesday, 11 May 2010

Random Grails tip: Using a DB reserved word as a domain class name in Grails

We recently came across a situation where we couldn't our Grails app was failing because it was trying to create a table with the name of 'Condition', which turns out to be a reserved word in MySQL... We worked around it by changing the name of the table to 'conditions' by using the Grails ORM DSL, but it turns out there is another way.

Backtick to the rescue...
Hibernate allows you to use backticks (`) to indicate that a name should be escaped - you can simply use this in your grails mapping. For example, we could have used:

class Condition {
String property1
String property2

static mapping = {
table '`condition`'

To be honest, I'm not sure why Grails and/or hibernate don't escape all table and column names by default (I'm sure there is a good reason) - there is an open JIRA issue in Grails around this very problem...

Friday, 30 April 2010

The location of the User Profile for Network Service on Windows Server 2008 & 7

This kind of thing should be easy to find, but I couldn't hunt it down on google. So to save someone else some pain, here it is - the location of the %USERPROFILE% / home directory for the NT AUTHORITY\NetworkService user:

(drum roll...)


which usually translates as:


The user profiles for other "well known" service accounts (such as LocalService) are siblings of this directory.

I hope that saves someone some time...