Showing posts with label greasemonkey. Show all posts
Showing posts with label greasemonkey. Show all posts

Thursday, March 19, 2009

A grease monkey script to view tab and new line characters in a browser

In certain cases its necessary to recognize tab and newline characters in a document. Microsoft word comes with an option to hide or show such punctuation marks like newline and tab characters. The short cut for enabling the display of punctuation marks is “Ctrl + *”. It can be very beneficial I differentiating space characters from tab characters.

Internet explorer or any other browser such as firefox, safari, opera or chrome does not come with such a option to view newline and tab characters. Simple one line greasemonkey script can do the job for firefox.

As can be seen in above screen, the newline characters in wikipedia home page been replaced by “q|” and tab characters have been replaced by “-->”.

The code for the oneline greasemonkey script is given below:

document.documentElement.innerHTML=document.documentElement.innerHTML.replace(/\t/g,"-->").replace(/\n/g,"q|");

Hopefully future versions of Internet browsers will provide this facility to view tab and newline characters when required.

Tuesday, August 7, 2007

Auto translate any page without identifying the language

Identifying the language is necessary to translate a web page using Babel Fish or Google Translate.

But the main problem i had was that i could not identify which language the page was in, for example if the page was in Spanish, i would not be able to identify it as spanish.

So what option should i choose in the "Select from and to languages"?

This problem is solved when using Google or yahoo, as it shows the appropriate Translate this page link beside the web link. What to do if you encounter a web page when you are not using any search engine..So the Auto Translate Greasemonkey can be used to lead you to the google page with the Translate this page link.

The Auto Translate Greasemonkey can be improved to directly redirect you to the translated page. But i thought the overhead was too much.

Wednesday, July 18, 2007

Getting unlucky after being too lucky

After feeling lucky and lcukier its time to be unlucky. So the present version of feeling lucky gives an option to unlucckify the queries that have been made lucky. Since, the lucky queries cant be seen on google,you will have to goto the unluckify page after installing the latest feel lucky greasymonkey.

The unlcukify page will remove the query from the lucky list. As soon as the query is removed it is displayed as an alert msg. Although this method works satisfactorily, their should be a more sensible method that does not require going to the unluckify page.

Tuesday, July 17, 2007

Feel luckier with google

This is an update to the previous post-Get lucky with google with input from Gautham pai. The new feel luckier script provides redirects to the suggested result.

For example if you were to search for nagarjunv you would get the suggestion of seeing results for nagarjuna.The script directly takes you to the suggested result page as in Yahoo. And a link to the original result is shown at the top as .

If you feel the word is correct on its own merit, that word can be added to the dictionary(on ur system only). Later it can be removed from the dictionary as well. The remove from dictionary link appears when the query is tried the next time, the redirect does not happen as the word is in the dictionary although Google suggests another result.

However, these scripts will be just as useful as bookmarks in their present form. They would be useful only if the redirects and made lucky queries are stored online. So the queries made lucky by other users of the script will also be lucky for us even if we are typing in the query for the first time. Google will have to do more than this simple script as it would have to take into consideration the language and other criteria as well.

Monday, July 16, 2007

Get lucky with google

Gauthampai said "Sometimes, 'we want to feel lucky' in the search result page as well. ;)" and here we are.

The greasymonkey feellucky makes it possible for us to bookmark search results as lucky. If you have made a particular query lucky by clicking on the make lucky link, the next time you put the same query you get lucky.

To install this greasemokey the firefox browser with greasemonkey is needed. To install just click on Install feellucky. The feel lucky script makes use of GM_setvalue and GM_getvalue to store the queries that need to be lucky. So the lucky feeling is limited to the system on which the gresymonkey is installed.

To make it useful for a wider audience, the lucky queries need to be stored on a server.

Wednesday, June 20, 2007

Rediffmail greasemonkey version 0.1

To use this greasymonkey script, u need to have installed the greasemonkey on your firefox browser. The script is for the new rediffmail which has the largest inbox in the world. It is the preliminary version and has just two features-
  1. Removes the banner ads from the free versions inbox.
  2. Provides google talk on rediffmail homepage and inbox.
The following screen shot shows the inbox without the right side banner ads. The Google talk is on the left side bar. To be able to use google talk you need to be logged into gmail. rediffmail greasemonkey
The main page of the rediffmail has been modified to remove the sponsored links and the advertisement at the left top corner has been replaced by gtalk.
rediff gtalk greasemonkey

To install the grease monkey just click on Nagarjunvs rediffmail version 0.1 in firefox and a dialog box will appaer which can be followed to install the greasy monkey.