javascript to automatically log into page with httpAuth

March 13, 2012

I recently had to get a security camera to continually update an image on a publicly viewable webpage. The security camera demanded httpAuth with username and password to obtain an image. I didn’t expect this to be a problem as I expected to be able to enter the username and password as part of the url. For example, in my case, the username is “a”, the password is “a”, and the url is so I expected to be able to visit:

http://a:a@” + Math.random();

to obtain the image. Worked great in FF and Chrome. However, Internet Explorer does not allow usernames and passwords to be entered in a URL. After much fussing I got this attached code to work for FF, Chrome, IE and Konqueror. Untested on Safari as of yet.



to-do: 1st in a 357 part series…

January 12, 2009
  • get rid of “input format” option in text field (blog)
  • get rid of image from url option in tinymce editor
  • figure out easy way to upload more than just pics but any media (or at least audio)

blah blah blah

individual categories for users

January 2, 2009

looked like one taxonomy with taxonomy access and hierarch select would do the trick, but the problem is that taxonomy access doesn’t understand the hierarchy i.e. if user has permission to post to category “fred” and user creates category fred -> subfred, then users can’t see category “subfred” at all, even though they created it.

More later.

drupal: immediate to-do list

December 31, 2008
  1. 1. document conflict between hierarchical menus and taxonomy-other
  2. test to see if taxonomy-access will allow users to post to only branches of a taxonomy
  3. test to see if in combination with tax-access will allow users to see only branches of a taxonomy in a menu.

flash FINALLY working in ff/ubuntu

December 22, 2008

I don’t know how long I’ve dealt with the stupid flash issue of flash content showing up on the wrong layer on webpages with ff. Menus would be underneath flash content. Popular sites like and even would have unreadable menus because they would be underneath other content instead of above.

Finally it appears to be fixed with FF 3.0.5 and flash10. Getting flash10 installed on my 8.04 “Hardy” 64 bit wasn’t obvious. Synaptic reported that I already had flash10 but ff’s about:plugins was showing flash9.

I installed flash10 64 bit native. That’s available here:

First I completely removed flash-plugin-nonfree in Synaptic. Then I copied from the link above to /usr/lib/xulrunner-addons/plugins, then restarted FF.

I confirmed I was running Flash10 here:

Might be a better reference than mine:

cadence video editing for mencoder and ffmpeg

December 4, 2008

to add the audio file to the video:

mencoder -ovc copy -oac pcm -audiofile 2008-12-04_002924-single0001.wav -o test4.avi

add a mask:

ffmpeg’s vhook needs a gif and doesn’t use transparency. The mask I used had a white hole (where I want the image) on a black frame. I wanted the black frm to mask the image:

ffmpeg -i test5.avi -vhook ‘/usr/lib/vhook/ -f mask.gif -t eeeeee’ aout.avi

the final incantation:

ffmpeg -i test5.avi -acodec pcm_s16le -b 2214k -vhook ‘/usr/lib/vhook/ -f mask2.gif -t eeeeee’ aout.avi

wm6 changing memory location of storage of programs

November 8, 2008


Change the location of Temporary Internet Files

When browsing the web, pages and images are saved in the ‘Temporary Internet Files’ location. You can change this location to, for example, your Storage Card:

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders\Cache = “\Storage Card\cacheie” (REG_SZ string, no quotes)

To return to the original location:

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders\Cache = “\Windows\Profiles\guest\Temporary Internet Files” (REG_SZ string, no quotes)

from it appears the contacts cannot be moved out of the main memory.
the googlemaps cache is apparently \My Device\Application Data\GoogleMaps\cache-GLM

I can’t say enough bad things about wm6. Never again.