Ok, thanks to Google for putting their dictionary out there, which I wrote about a couple of posts ago, but the quality of the results pales in comparison to Wordnik, which I've just discovered. It won't do language translation for you, but as far as the English language is concerned, this is pure word porn. So here's an updated bookmarklet for you:
wordnik
Just drag that to your bookmarks bar, select a word or phrase on the page, and click. Happy bonus: just clicking on the bookmarklet without highlighting a word first will give you a random word (thanks to Wordnik, not me). Cool!
Tuesday, December 22, 2009
Tuesday, December 15, 2009
Chrome Frame's Shifty User-Agent
One of the security measures we have in place at Wesabe is to invalidate a session and log the user out if their User-Agent or IP address subnet changes between requests. However, we recently had a number of complaints that users were getting logged out prematurely. Looking at one user's session in the logs, I noticed that their user agent string had "chromeframe/4.0" appended for some requests, but not others. It turns out that Google's Chrome Frame only modifies the user agent for top-level requests, and not for subsequent requests sent as that page loads:
This fix on our side was to just strip the chromeframe identifier from the user agent string, although it makes me wonder what other browser extensions cause similar issues and whether invalidating a session when the user agent changes is even a worthwhile security measure.
It was a compromise to keep code complexity down. In order to tag every request from IE...we have to have hooks in place at many more places (not to mention supporting the different things IE6, 7 and 8 do). So, as a compromise we decided to keep it down to only the single hook that allows us to tag top level requests.
This fix on our side was to just strip the chromeframe identifier from the user agent string, although it makes me wonder what other browser extensions cause similar issues and whether invalidating a session when the user agent changes is even a worthwhile security measure.
Friday, December 4, 2009
Google Dictionary Bookmarklet
Google recently launched a decent dictionary, so for you logophiles, here's a bookmarklet that will bring up the definition of whatever text you have selected on the page: gDefine. Just drag it to your bookmarks toolbar, then double-click a word somewhere and click the button to get a definition.
It is set to use the English dictionary, but if you want to use it in a different language (or even translate between languages), just change the
Here are a few to get you started:
gDefine (French)
gDefine (Spanish)
gDefine (German)
And translations:
gTranslate (French>English)
gTranslate (English>French)
Enjoy!
It is set to use the English dictionary, but if you want to use it in a different language (or even translate between languages), just change the
langpair
parameter from en|en
to, say, fr|fr
for French, de|de
for German, etc. (try a search on the Google Dictionary site in the language you want and look to see what the langpair
parameter is in the url). Also, the hl
parameter controls the language of the results page, so if you want your results to be in that language as well (as opposed to English), change that accordingly.Here are a few to get you started:
gDefine (French)
gDefine (Spanish)
gDefine (German)
And translations:
gTranslate (French>English)
gTranslate (English>French)
Enjoy!
Subscribe to:
Posts (Atom)