Category: Uncategorized
-
Fixing the Feeling Lucky extension for FF 2.0
Brad Kowalczyk’s Feeling Lucky extension…
“Performs Google’s ‘I’m Feeling Lucky’ search with any selected text and opens the result in new a tab.
This is the first ever Firefox extension that I’ve created. I found myself selecting, copying, pasting text into the location bar to do an ‘I’m Feeling Lucky’ search all too often so I figured I should make an extension to make it just a little simpler.
Simply select some text and either hit ‘Enter’ or right-click it and select ‘Feeling Lucky’ The web page of the first Google search result for that text will open in a new tab.”
I felt I needed this, but it wasn’t FF 2.0 compatible, so I fixed it. Apparently, the only thing needed for that was replacing a call to
gContextMenu.searchSelected()in feelingLucky.xul with a call togetBrowserSelection(). In addition to that, the em:maxVersion in install.rdf needs to be set for 2.0, naturally.I’ve packed one fixed version of this, but I haven’t tested it (too lazy). Try it at your own risk.
-
Lääkealalle avattiin Wiki-sivusto
EyeforPharma on avannut ensimmäisen lääkealan Wiki-sivuston. Tavoitteena on luoda hyödyllinen ja maailmanlaajuinen lääketeollisuuteen keskittyvä tietolähde.
Mediuutiset via Ampparit
linkitys omani -
Led-kynttilöistä povataan joulun hittituotetta
Tavaratalojen myyjät ja Turvatekniikan keskus Tukes uskovat, että led-kyntteliköt korvaavat perinteiset kyntteliköt useissa kodeissa tänä jouluna. Led-valosarjat ovat huomattavasti tavallista kynttilää tai valosarjaa turvallisempia, sillä ne eivät juuri kuumene käytön aikana, ja koska ne toimivat pienitehoisen muuntajan avulla, ne kuluttavat myös paljon vähemmän sähköä kuin perinteinen sähkökynttelikkö. Led-kyntteliköt ovat samalla kuitenkin vielä hieman perinteistä kynttelikköä kalliimpia.
-
K-Meleon
K-Meleon on nopea, kustomoitava ja kevyt selain [Windows-alustalle]. Se pohjautuu [Gecko-layout-moottorille], jota myös Mozilla käyttää. K-Meleon on ilmainen, vapaan lähdekoodin ohjelma, joka on julkaistu GNU General Public [-lisenssillä].
-
Replacing changed directory names with .htaccess
After poking around with some Rewrite rules and nearly losing my nerve with what seemed to be a choice between a
500 Internal Errorand WordPress’ 404 pages, I finally came up with a redirect instruction for my .htaccess file that replaces a subdirectory name in URLs which end in .html.I need this because when I started marginaali, I used Blogger which outputs html files. I then moved on to WordPress and imported everything I had blogged thus far – apart from the comments that I had received. Therefore I didn’t have the heart to delete all those .html files and was sort of stuck between the two.
After activating pretty permalinks, all requests to those old posts were redirected to the WordPress ones, and so the comments were, in effect, not available. Not until I changed the old posts’ directory name from both Blogger’s and WordPress’ standard naming by the year, by prefixing the (thankfully only) 2004 directory with an ‘o’, into ‘o2004’.
There was one additional problem: that of old links out there in the Net pointing to these old posts and the comments in them – they were now broken of course. Here’s where I figured a relatively simple rewrite rule should do the trick: in all requests to files ending in .html under /marginaali/, replace the 2004 with the o2004.
Well, like I implied in the beginning, this was surprisingly difficult to achieve with my little experience in tweaking .htaccess files. I finally succeeded, however, and here’s my solution:
RedirectMatch /marginaali/2004/(.*)\.html$ http://mummila.net/marginaali/o2004/$1.htmlI placed this directive after the segment added by WordPress, in the the same .htaccess file that controls the permalinking, in /marginaali/. It leaves requests to the WP versions of posts (such as this one) intact, while fixing the requests to their html versions with the added ‘o’ so that, for example, 2004/11/sepe.html gets redirected to o2004/11/sepe.html. (That is an actual example of a page being referred to out on someone else’s page, which I have no control over.)