Skip to content

Categories:

spigot on chrome mac os x

So I’ve googled on trying to remove this yahoo search home page (with spigot in the querystring).

I did not find any extensions that could have contained spigot (but perhaps I did remove one months ago) and also did not find anything in any LaunchAgent or LaunchDaemon folder.

However, in ~/Library/Application Support/Google/Chrome/Default there’s a file called Preferences which contains a large json blob with two instances of the yahoo url listed. Edit out those urls (I simple removed the urls so that chrome will start empty).

Problem solved.

 

Posted in misc.


windows activation KMS fails on ec2 instances

I’ll make this really short, but for some reason the windows 2008 instances in the amazon cloud showed that windows wasn’t genuine “Windows not genuine” – and when trying to activate using
slmgr.vbs /ato the error received was:
0xC004F074 with description “The Key Management Server (KMS) is unavailable” (this error: https://support.microsoft.com/en-ca/kb/974998)

Trying to set the KM server to various ips I found in amazon documentation did not work.
For example some IPs for various regions are listed here:
http://cloudstacking.com/posts/windows-product-activation-for-aws-ec2-imported-vms.html

But looking in the settings file for the ec2 client helped: c:\program files\amazon\Ec2ConfigService\settings\ActivationSettings.xml (more info: http://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/UsingConfig_WinAMI.html)

That’s where the private IP of the KMS server is hidden.

So, then executing
slmgr.vbs /skms privateip-from-xml-file
and then
slmgr.vbs /ato
worked!

further info:

Windows Server: KMS client behind firewall


https://forums.aws.amazon.com/message.jspa?messageID=227937#418321

Posted in code.


mysql “NOT IN” not working as expected

Last night, I was trying to extract all users that were not listed in one of several other tables. Thinking that I could simply use

SELECT * FROM users WHERE users.id NOT IN (SELECT othertable.id FROM othertable)

and receiving a result, I was on my way.

However, after analyzing the data a little bit I was surprised to see records in the set that should not have been there. “NOT IN” was not working as I expected it to.

A quick search also yielded similar experiences from other users on stackoverflow. I changed the query to use LEFT JOIN as follows:

SELECT * FROM users LEFT JOIN othertable on users.id = othertable.id WHERE othertable.id IS NULL

This query yields the expected data and according to the stackoverflow discussion even performs a little better. It is easy extendable to more than two tables as well.

Time to go back and check similar code I’ve used in the past!

 

Posted in code.


Tangerine Orange Key

Here’s the Orange Key to get free cash from Tangerine:

40549740S1

Tangerine has a referral program in place that rewards the owner of this orange key with a referral bonus whenever a new customer signs up.

I’ve had a great experience with Tangerine. Once I figured out how much my previous bank (CIBC) was charging me on a monthly basis, switching to a no-fee account was a no-brainer. I can only recommend you do it as well. The ATMs are usually located centrally (of course, any Scotiabank ATM will work for free) and haven’t made a difference to any of my usual banking habits. I also like their online banking user interface. Best of all, looking at any of the cheques you’ve written is free.

 

Posted in misc.


Bitcoin primer – great articles to get started

I’m very excited about bitcoin and I’ve listed some great articles below that I’ve found really interesting.

These articles cover the basics, but many of them also give hints of the effects bitcoin may have not just on our own money transactions but on the financial industry as well as governments and their tax base.

 

The Bitcoin Bubble and the future of currency – the best article on the whole idea and implications I’ve come across so far.

Why VCs love the bitcoin market  – very interesting numbers on the market capitalization we can expect from bitcoin.

Future of Bitcoin – makes me a fan of the New Yorker.

surely more to come.

 

Posted in bitcoin.


Javascript / Jquery Event and browser autofill / autocomplete

Using a browser’s autofill functionality does not trigger the onkeyup or onchange events.

If you have a form that is dependent on dynamic user input, you may want to check out the following bindings.

To catch a user using a browser autofill, I bound the following events to an element:

$(‘#element’).bind(‘change keyup blur input’, function () { …. {);

It worked. However, it may give you trouble in IE, but what doesn’t?

 

Posted in misc.


XBox 360 can’t see Time Capsule WLAN

The solution here seems to be:

a) set the Time Capsule to provide 802.11 b/g compatible mode (in Airport Utility, select your TC and make a change to the Radio mode WHILE holding the option key. Otherwise you will not see the available b/g compatible mode.

b) set the password used to WPA/WPA2 personal. Do not use WEP. XBox will not see your network otherwise.

c) connect on XBox.

 

Posted in misc.


Remove MS Word Smart Quotes in Vbscript

just a little tidbit that was driving me crazy.

Haven’t used ASCW and CHRW much, but here it goes:

strtitle = Replace(strTitle,ChrW(8211),”–“)
strtitle = Replace(strTitle,ChrW(8212),”–“)
strtitle = Replace(strTitle,ChrW(8216),”‘”)
strtitle = Replace(strTitle,ChrW(8217),”‘”)
strtitle = Replace(strTitle,ChrW(8220),””””)
strtitle = Replace(strTitle,ChrW(8221),””””)
strtitle = Replace(strTitle,ChrW(8226),”*”)
strtitle = Replace(strTitle,ChrW(8482),””)
strtitle = Replace(strTitle,ChrW(8230),”.”)

Posted in code.


MSXML Object ASP

2 errors today:
msxml6.dll threw
The host name in the certificate is invalid or does not match
-2147012858

which can be fixed by using the following code:

http.open “GET”, url, True
Const SXH_SERVER_CERT_IGNORE_ALL_SERVER_ERRORS = 13056
http.setOption 2, SXH_SERVER_CERT_IGNORE_ALL_SERVER_ERRORS

then msxml6.dll threw
The connection with the server was terminated abnormally
-2147012866

In the code I found the following line which caused the trouble:
http.setRequestHeader “Connection”, “Close”
Why oh Why?

Posted in code.


Facebook connect blocked by company internet / firewall

We recently had the problem that our site was loading very slowly for some users because their firewall blocked any access to facebook (company guidelines). After a quick search I found a great solution by the guys at tripadvisor.
http://tech.tripadvisor.com/

Posted in code.

Tagged with , , .