Skip to main content

Posts

Showing posts from March, 2007

Web Application specific Configuration

I was looking for a way to easily manage web application specific configuration in separate properties file. In our current version of application, a properties file was included in a war file of web application. However, this was problematic since the properties file had to be updated every time we deployed a new war file. I tried passing the name of the properties file in Tomcat command-line but that did not work well for multiple web applications. Then I came across Environment tags in Tomcat context definition that can be configured for each individual application. So I decided to us the following solution. 1. Add Environment entry for name of a properties file in context definition of web application. <Context path="/app1" docBase="C:/app1/web-dir" debug="0" reloadable="true"> <Environment name="appconfig" value="WebApp1.properties" type="java.lang.String" overri

Unlocking Nokia Phone

I misplaced my Motorola Razr and wanted to use my old Nokia phone in the mean time. So I went to a local operator outlet store and they gave me a new SIM card but refused to unlock the old phone. I also tried calling the customer service but got the same answer. So I did a search on google to see if any third-party could help me unlock the Nokia phone. That is when I came across Free SIM Unlock Nokia online . I was able to unlock my Nokia phone in a matter of few minutes without any issues. The steps were very precise and simple. I wonder if it is worth the time and money operators have to invest in enforcing this restriction, when the phones can be unlocked so easily.

Taking snapshot Image of Website

Recently I came across an article that mentioned Pearl Crescent Page Saver extension for Firefox that allows users to save a snapshot of the website as an image. It is a very handy tool that lets you save either the visible portion of the website or the entire website to an image file. That is very helpful as I remember I had to use Paint tool to manually merge the snapshots of a website that did not fit all in one page.

Extract a column from text file

In order to extract a column values from a text file where each line contains several words separated by space, following can be used; cut -d' ' -f6 file.txt > result.txt This would extract values from 6th column in a file named file.txt where each line contains words separated by white spaces.