<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0"><channel><atom:id>tag:blogger.com,1999:blog-20715940</atom:id><lastBuildDate>Thu, 05 Jan 2012 17:28:07 +0000</lastBuildDate><category>cooking</category><category>javascript</category><category>funny</category><category>swing</category><category>C</category><category>perl</category><category>how to</category><category>UI</category><category>tomcat</category><category>teamsite</category><category>cookbook</category><category>solutions</category><category>note to self</category><category>algorithms</category><category>firefox</category><category>grails</category><category>linkage</category><category>tcsh</category><category>css</category><category>python</category><category>websphere</category><category>spring</category><category>xpath</category><category>freebsd</category><category>eclipse</category><category>webdev</category><category>cron</category><category>solaris</category><category>greasemonkey</category><category>ibatis</category><category>xml</category><category>hibernate</category><category>ant</category><category>fucking hp</category><category>catman</category><category>java</category><category>internet explorer</category><category>shameless plug</category><category>jsp</category><category>lucene</category><category>music</category><category>intellij</category><category>note to self books</category><category>RMI</category><category>oracle</category><category>tellurium</category><category>regex</category><category>jquery</category><category>infusion</category><category>sql</category><category>groovy</category><category>unix</category><category>subversion</category><title>Note to self</title><description>Code, cooking, catman</description><link>http://notetodogself.blogspot.com/</link><managingEditor>noreply@blogger.com (Mikhail Koryak)</managingEditor><generator>Blogger</generator><openSearch:totalResults>199</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/blogspot/notetoself" /><feedburner:info uri="blogspot/notetoself" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-6236607228660529827</guid><pubDate>Sat, 03 Dec 2011 22:20:00 +0000</pubDate><atom:updated>2011-12-03T17:20:21.326-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">solutions</category><category domain="http://www.blogger.com/atom/ns#">how to</category><title>configure boxee to work as a second monitor with sound over hdmi</title><description>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;My HTPC setup is simple:&lt;br /&gt;
I ran a 40 foot HDMI cable from my computer room into my bedroom through the basement. I hooked up my TV in the bedroom to be the 2nd monitor on my PC and set boxee to run on that monitor. &lt;br /&gt;
&lt;br /&gt;
The problem:&lt;br /&gt;
I wanted to have Boxee use sound over hdmi, but also be able to listen to to music and play games on my computer as usual without the sound coming from the bedroom TV.&lt;br /&gt;
&lt;br /&gt;
Solution:&lt;br /&gt;
In your windows sound prefs set:&lt;br /&gt;
&lt;ul style="text-align: left;"&gt;&lt;li&gt;"Speakers" as your default audio device&lt;/li&gt;
&lt;li&gt;"HDMI digital output" as your default communication device&lt;/li&gt;
&lt;/ul&gt;In boxee sound config set:&lt;br /&gt;
&lt;ul style="text-align: left;"&gt;&lt;li&gt; primary soundcard: HDMI digial sound&lt;/li&gt;
&lt;/ul&gt;restart boxee. Now you should be able to hear HDMI sound only on the TV, and all other sound will come from your speakers.&amp;nbsp; &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-6236607228660529827?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/USPXlB5gPSY" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/USPXlB5gPSY/configure-boxee-to-work-as-second.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/12/configure-boxee-to-work-as-second.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-1483245347085981877</guid><pubDate>Wed, 19 Oct 2011 03:03:00 +0000</pubDate><atom:updated>2011-10-18T23:03:19.315-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">fucking hp</category><title>Photosmart CN216 no LCD or power lights</title><description>I have a brand new (POS) HP Photosmart CN216 all in one print/scan/copy/web printer.&lt;br /&gt;
The only trouble is that sometimes it will power on, but no lights come on. The power light is not not blue, and the LCD is off. At the same time, the printer is on because its making the normal noises.&lt;br /&gt;
&lt;br /&gt;
I was about to return it to HP since once this happens no amount of pressing the power button will "turn it back on". I found a solution:&lt;br /&gt;
&lt;br /&gt;
The fix is to open the printer as if you were about to replace the ink cartridges, then SLAM it shut. It helps if you are are angry, but you will be when your brand new 100$ wireless printer doesnt work. This will cause it to turn on properly. &lt;br /&gt;
&lt;br /&gt;
The downside to this solution is that it cannot be done at night when people are sleeping&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-1483245347085981877?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/kx-ShvtNpsc" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/kx-ShvtNpsc/photosmart-cn216-no-lcd-or-power-lights.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/10/photosmart-cn216-no-lcd-or-power-lights.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-4810085324801929530</guid><pubDate>Thu, 29 Sep 2011 15:18:00 +0000</pubDate><atom:updated>2011-09-29T11:18:00.236-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">sql</category><title>mysql function example</title><description>delimiter //&lt;br /&gt;
create function mytest ()  returns char(50) deterministic&lt;br /&gt;
begin&lt;br /&gt;
declare c int;&lt;br /&gt;
select count(*) into c from table;&lt;br /&gt;
return c;&lt;br /&gt;
end&lt;br /&gt;
//&lt;br /&gt;
delimiter ;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-4810085324801929530?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/SRsAFCAoGi0" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/SRsAFCAoGi0/mysql-function-example.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/09/mysql-function-example.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-2174018467114007588</guid><pubDate>Fri, 08 Jul 2011 18:24:00 +0000</pubDate><atom:updated>2011-07-08T14:31:30.373-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">python</category><category domain="http://www.blogger.com/atom/ns#">how to</category><title>Python: remove some entries from a dict</title><description>&lt;b&gt;Problem&lt;/b&gt;: &lt;br /&gt;
Remove a bunch of entries from a dict in an elegant way&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Solution 1&lt;/b&gt;:&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;map(lambda name: dict.pop(name, None), ['some_key', 'some_other_key', 'bleee'])&lt;br /&gt;
&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Solution 2&lt;/b&gt;:&lt;br /&gt;
My coworker &lt;a href="http://ohthehugemanatee.net/"&gt;Dave&lt;/a&gt; came up with an even better way to do this thing:&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;map(dict.pop, ['some_key', 'some_other_key', 'bleee'], [])&lt;/b&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-2174018467114007588?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/PoHkvC1RQd8" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/PoHkvC1RQd8/python-remove-some-entries-from-dict.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/07/python-remove-some-entries-from-dict.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-4737666585483595386</guid><pubDate>Thu, 07 Apr 2011 03:36:00 +0000</pubDate><atom:updated>2011-05-17T09:03:25.300-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">how to</category><category domain="http://www.blogger.com/atom/ns#">grails</category><title>Grails: Securing CKEditor URLs</title><description>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;b&gt;Problem:&lt;/b&gt;&lt;br /&gt;
I am using the grails &lt;a href="http://grails.org/plugin/ckeditor"&gt;CKEditor plugin&lt;/a&gt;&lt;b&gt; &lt;/b&gt;and i wanted to secure the file manager urls to be accessed only by a site admin. I am using the &lt;a href="http://www.grails.org/plugin/spring-security-core"&gt;Spring Security Core&lt;/a&gt; plugin for site security, but i was already using annotations elsewhere on my site, so using a &lt;span class="Apple-style-span" style="border-collapse: separate; color: black; font-family: 'Times New Roman'; font-size: small; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: monospace; font-size: 12px;"&gt;InterceptUrlMap &lt;/span&gt;&lt;/span&gt;was not an option.&lt;br /&gt;
&lt;br /&gt;
So, how to keep using annotations and secure a plugin's urls?&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Solution:&lt;/b&gt;&lt;br /&gt;
The trick is properly using the controllerAnnotations.staticRules (which really isnt that hard if you pay attention to the docs).&lt;br /&gt;
Here is the mapping that works for ANY url mapping you define to CKEditor:&lt;br /&gt;
&lt;br /&gt;
&lt;span class="Apple-style-span" style="border-collapse: separate; color: black; font-family: 'Times New Roman'; font-size: small; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class="Apple-style-span" style="border-collapse: separate; color: black; font-family: 'Times New Roman'; font-size: small; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: courier,'courier new',monospace; font-size: 12px; line-height: 12px; white-space: pre;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;script class="brush: java" type="syntaxhighlighter"&gt;
grails.plugins.springsecurity.controllerAnnotations.staticRules = [
   '/openFileManagerConnector/show': ['IS_AUTHENTICATED_ANONYMOUSLY'],
   '/standardFileManagerConnector/show': ['IS_AUTHENTICATED_ANONYMOUSLY'],
   '/openFileManagerConnector/**': ['ROLE_ADMIN'],
   '/standardFileManagerConnector/**': ['ROLE_ADMIN'],
]
&lt;/script&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-4737666585483595386?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/nHh_kRaoz9E" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/nHh_kRaoz9E/grails-securing-ckeditor-urls.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/04/grails-securing-ckeditor-urls.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-1933003684659774376</guid><pubDate>Fri, 25 Mar 2011 02:51:00 +0000</pubDate><atom:updated>2011-03-24T22:51:20.283-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">solutions</category><category domain="http://www.blogger.com/atom/ns#">grails</category><category domain="http://www.blogger.com/atom/ns#">groovy</category><title>manually set id of grails domain object</title><description>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;b&gt;Problem:&lt;/b&gt;&lt;br /&gt;
if you create a new domain object and set its id in the constructor like this:&lt;br /&gt;
&lt;i&gt;Cat catman = new Cat(id:1000, name: "catman", kind: "domestic short haired")&lt;/i&gt;&lt;br /&gt;
later, if you look at the object the id will be null. what gives?!&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Solution:&lt;/b&gt;&lt;br /&gt;
Its madness, but it works to assign the id after the object is made. Just add&lt;br /&gt;
&lt;i&gt;catman.setId(1000);&lt;/i&gt;&lt;br /&gt;
and you are in business.&lt;br /&gt;
&lt;br /&gt;
Note: if you want to save the object into db after doing this, you must set the id generator to 'assigned'&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-1933003684659774376?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/SKY-01cQT98" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/SKY-01cQT98/manually-set-id-of-grails-domain-object.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>1</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/03/manually-set-id-of-grails-domain-object.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-8201952337843734091</guid><pubDate>Mon, 14 Mar 2011 01:58:00 +0000</pubDate><atom:updated>2011-03-13T21:58:26.360-04:00</atom:updated><title>lg cdma usb modem driver</title><description>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;The lg mobile phone driver is hard to find. i am using it to make bitpim work with my phone.&lt;br /&gt;
&lt;br /&gt;
It will work with all LG VX-something phones and also is sometimes called this:&lt;br /&gt;
&lt;br /&gt;
Prolific USB-to-Serial Comm Port Driver&lt;br /&gt;
LGE CDMA Composite USB Device Driver&lt;br /&gt;
LGE CDMA USB Modem Driver&lt;br /&gt;
LGE CDMA USB Modem Diagnostic Serial Port Driver&lt;br /&gt;
LGE CDMA USB Modem (VCOMM) Driver&lt;br /&gt;
LGE CDMA USB Modem Diagnostic Serial Port (VCOMM) Driver&lt;br /&gt;
LGE CDMA USB Serial Port Driver&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
get it here:&lt;br /&gt;
&lt;a href="http://programmingdrunk.com/random-stuff/LGUSBModemDriver_4.6_WHQL.zip"&gt;http://programmingdrunk.com/random-stuff/LGUSBModemDriver_4.6_WHQL.zip&lt;/a&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-8201952337843734091?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/DvuPFHV_73I" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/DvuPFHV_73I/lg-cdma-usb-modem-driver.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>4</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/03/lg-cdma-usb-modem-driver.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-8507826242680524980</guid><pubDate>Mon, 21 Feb 2011 17:11:00 +0000</pubDate><atom:updated>2011-02-21T12:11:17.852-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">solutions</category><category domain="http://www.blogger.com/atom/ns#">ant</category><title>Class needed by SvnTask cannot be found</title><description>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;b&gt;problem:&lt;/b&gt;&lt;br /&gt;
getting this error when trying to build:&lt;br /&gt;
&lt;br /&gt;
taskdef A class needed by class org.tigris.subversion.svnant.SvnTask cannot be found: org/tigris/subversion/svnclientadapter/SVNClientException&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;solution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
I didnt unzip all libs that came with svnant into my lib folder. Only unzipped svnant.jar. need to put them all in there.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-8507826242680524980?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/0PaSIfkofwU" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/0PaSIfkofwU/class-needed-by-svntask-cannot-be-found.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/02/class-needed-by-svntask-cannot-be-found.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-6823252007773280377</guid><pubDate>Mon, 07 Feb 2011 04:05:00 +0000</pubDate><atom:updated>2011-02-21T11:54:06.693-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">how to</category><category domain="http://www.blogger.com/atom/ns#">tomcat</category><title>Multiple domains with tomcat behind apache</title><description>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;This is how you would host multiple domains/webapps on a single tomcat behind apache via mod-jk.&lt;br /&gt;
&lt;br /&gt;
first &lt;a href="http://notetodogself.blogspot.com/2011/02/linode-how-to-install-modjk-tomcat.html"&gt;setup tomcat behind apache&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
I am setting up a new domain called dogself.com:&lt;br /&gt;
&lt;br /&gt;
in &lt;i&gt;server.xml&lt;/i&gt; add this under last host:&lt;br /&gt;
&lt;br /&gt;
&lt;pre&gt;&amp;lt;Host name="dogself.com"  appBase="webapps-dogself"
  unpackWARs="true" autoDeploy="true"
  xmlValidation="false" xmlNamespaceAware="false"&amp;gt;
&amp;lt;alias&amp;gt;www.dogself.com&amp;lt;alias&amp;gt;
&amp;lt;/Host&amp;gt;&amp;nbsp;&lt;/pre&gt;&lt;pre&gt;&amp;nbsp;&lt;/pre&gt;&lt;pre&gt;and also add another connector port:&lt;/pre&gt;&lt;pre&gt;&lt;pre&gt;&lt;/pre&gt;&lt;pre&gt;&amp;lt;Connector port="8010" protocol="AJP/1.3" redirectPort="8443" /&amp;gt; &lt;/pre&gt;&lt;/pre&gt;&lt;br /&gt;
create a &lt;i&gt;webapps-dogself&lt;/i&gt; directory next to &lt;i&gt;webapps &lt;/i&gt;and give it the same permissions&lt;br /&gt;
&lt;br /&gt;
in your virtualhost apache config:&lt;br /&gt;
&lt;pre&gt;ServerName dogself.com 
JkMount  /* dogself&amp;nbsp;&lt;/pre&gt;&lt;pre&gt;&amp;nbsp;&lt;/pre&gt;in workers.properties add dogself worker to list:&lt;br /&gt;
&lt;pre&gt;worker.list=another,dogself

# Define dogself
worker.dogself.port=8010&lt;/pre&gt;&lt;pre&gt;worker.dogself.host=dogself.com
worker.dogself.type=ajp13&amp;nbsp;&lt;/pre&gt;&lt;br /&gt;
If you want the manager app to work on the domain you need to: &lt;br /&gt;
&lt;pre&gt;mkdir /etc/tomcat6/Catalina/dogself.com &lt;/pre&gt;&lt;br /&gt;
and copy the manager.xml into it from &lt;i&gt;/etc/tomcat6/Catalina/localhost&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
in &lt;i&gt;/var/lib/tomcat6&lt;/i&gt; create a &lt;i&gt;webapps-dogself&lt;/i&gt; dir and give it 0775 perms and chown it to tomcat:tomcat&lt;br /&gt;
&lt;br /&gt;
restart tomcat and apache&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Troubleshooting:&lt;/b&gt;&lt;br /&gt;
if you get error:&lt;br /&gt;
&lt;i&gt;worker dogself can't resolve tomcat address dogself.com&lt;/i&gt;&lt;br /&gt;
Check that your dns a/aaaa records point to your ip. Comment out the worker in workers.properties and see if you can get to the apache vhost. &lt;br /&gt;
&lt;br /&gt;
if any of the domains seems to point to another domain, ie the war that is running on one domain is incorrect. check if you are in the www.domain and if you have aliased the www both in tomcat and in apache. if you dont alias the www correctly tomcat will send you the the defaultDomain as defined in server.xml&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-6823252007773280377?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/77sDTmqLjdk" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/77sDTmqLjdk/multiple-domains-with-tomcat-behind.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/02/multiple-domains-with-tomcat-behind.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-6477436830164866767</guid><pubDate>Fri, 04 Feb 2011 03:35:00 +0000</pubDate><atom:updated>2011-02-03T22:35:01.659-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">how to</category><category domain="http://www.blogger.com/atom/ns#">tomcat</category><title>Linode: how to install mod_jk, tomcat behind apache</title><description>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div&gt;This "tutorial" is for Ubuntu 10.04 LTS (Lucid).&lt;br /&gt;
This is how you would set up Tomcat6 behind Apache2 via mod_jk&lt;br /&gt;
&lt;br /&gt;
I am assuming that you have &lt;a href="http://library.linode.com/lamp-guides/ubuntu-10.04-lucid/"&gt;apache2 installed&lt;/a&gt; and tomcat6 installed. I also assume you have deployed and can find your tomcat app possibly on port 8080 of your linode.&lt;br /&gt;
&lt;br /&gt;
&lt;ol style="text-align: left;"&gt;&lt;li&gt;Install mod_jk: &lt;span class="Apple-style-span" style="border-collapse: separate; color: black; font-family: 'Times New Roman'; font-size: small; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: helvetica,verdana,tahoma,arial,sans-serif; font-size: 15px; line-height: 20px;"&gt;&lt;pre class="literal-block" style="background-color: #122312; border: 1px solid rgb(160, 160, 160); color: white; font-family: Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,serif; font-size: 12.5px; line-height: 15px; overflow: auto; padding: 10px;"&gt;apt-get install libapache2-mod-jk&lt;/pre&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;Create workers.properties in &lt;i&gt;/etc/apache2/&lt;/i&gt; and add the following into it:&lt;pre&gt;# this lives in /etc/apache2/workers.properties
# workers.properties - ajp13
#
# List workers
worker.list=worker1

# Define worker1
worker.worker1.port=8009
worker.worker1.host=localhost
worker.worker1.type=ajp13
&lt;/pre&gt;&lt;/li&gt;
&lt;li&gt;&amp;nbsp;Edit your apache2 config in &lt;i&gt;/etc/apache2/apache2.conf&lt;/i&gt; and add this to the end:&lt;br /&gt;
&lt;pre&gt;# tomcat connector stuff:
JkWorkersFile /etc/apache2/workers.properties
# Where to put jk shared memory
JkShmFile     /var/log/apache2/mod_jk.shm
# Where to put jk logs
JkLogFile     /var/log/apache2/mod_jk.log
# Set the jk log level [debug/error/info]
JkLogLevel    info
# Select the timestamp log format
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] 
&lt;/pre&gt;&lt;/li&gt;
&lt;li&gt;In your &lt;i&gt;/etc/apache2/sites-enabled/&lt;/i&gt; dir find the vhost you want to use tomcat and edit it, at the end of the vhost declaration put:&lt;br /&gt;
&lt;pre&gt;#Everything under root goes to tomcat
JkMount  /* worker1
#html files should be served by apache2
JkUnMount /*.html worker1
&lt;/pre&gt;&lt;/li&gt;
&lt;li&gt;Edit &lt;i&gt;/etc/tomcat6/server.xml&lt;/i&gt; and make sure that the ajp connector is uncommented:&lt;br /&gt;
&lt;pre&gt;&amp;lt;connector port="8009" protocol="AJP/1.3" redirectport="8443" /&amp;gt;
&lt;/pre&gt;&lt;/li&gt;
&lt;li&gt;restart tomcat: &lt;i&gt;/etc/init.d/tomcat6 restart&lt;/i&gt;&lt;/li&gt;
&lt;li&gt;restart apache: &lt;i&gt;/etc/init.d/apache2 restart&lt;/i&gt;&lt;/li&gt;
&lt;li&gt;navigate to yourdomain.com/ and you should be all tomcatted&lt;br /&gt;
&lt;/li&gt;
&lt;/ol&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-6477436830164866767?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/XXzdMAB79MM" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/XXzdMAB79MM/linode-how-to-install-modjk-tomcat.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>4</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/02/linode-how-to-install-modjk-tomcat.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-2331870143146180346</guid><pubDate>Wed, 26 Jan 2011 16:14:00 +0000</pubDate><atom:updated>2011-01-26T11:14:13.459-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">how to</category><title>How to make your bed for engineers</title><description>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Being an engineer I am always looking for more efficient ways to do all manner of household tasks. &lt;br /&gt;
Making the bed has never been my strong point. My wife makes the bed faster than me, and it always looks better. I have long given up trying to figure out her technique, she probably just has many more years of experience than me. She is a principal bed maker while i am just a bed maker intern.&lt;br /&gt;
&lt;br /&gt;
Yesterday a friend of mine shared a bed making technique with me that has improved the tidiness and speed of bed making. I would like to share this technique with you!&lt;br /&gt;
&lt;br /&gt;
The secret to making large beds efficiently is to make the bed while you are in it! Being in the middle of the bed gives you maximum reach to both sides, where you can straighten out the covers. You no longer need to make several passes from one side of the bed to the other. After you get the bed looking nice, carefully roll out. Chances are that you will need just one more pass to fix the wrinkles in the covers.&amp;nbsp; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-2331870143146180346?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/_sAY972KNFo" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/_sAY972KNFo/how-to-make-your-bed-for-engineers.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2011/01/how-to-make-your-bed-for-engineers.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-4726917336245093059</guid><pubDate>Thu, 23 Dec 2010 22:18:00 +0000</pubDate><atom:updated>2010-12-23T17:18:18.438-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">javascript</category><title>after a request, page reloads 2 times and contains very little html</title><description>I just fixed a very strange issue in our application.&lt;br /&gt;
&lt;br /&gt;
It went something like this:&lt;br /&gt;
User would click on a link that opened another page. This page would flash for a second, then another page would open containing just the string "2010".&lt;br /&gt;
&lt;br /&gt;
The bug came from QA as being a regression related to recent development, so i started debugging in the code. There was &lt;b&gt;nothing&lt;/b&gt; in the logs. &lt;br /&gt;
&lt;br /&gt;
Then i opened firebug, went into "net" mode and persisted it. I saw my original request made, along with headers, and then another request made, this one had no headers at all.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Solution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
document.write is evil. There was recently a change to the code which attempted to make the copyright year dynamic by replacing it with&lt;br /&gt;
&lt;i&gt;document.write(new Date().getFullYear());&lt;/i&gt;&lt;br /&gt;
inside of a script tag. This alone wouldn't cause the issue, but document.write only works correctly if its called when the page is being rendered. If the page is rendered, it will overwrite the entire page with whatever its writing out. The issue was the the page the user was going to next, was gotten via ajax, and thus the script was called &lt;b&gt;after &lt;/b&gt;the page was loaded, overwriting the entire page. &lt;br /&gt;
&lt;br /&gt;
Oh the glory of being a programmer.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-4726917336245093059?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/TdpnkiLGFVc" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/TdpnkiLGFVc/after-request-page-reloads-2-times-and.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/12/after-request-page-reloads-2-times-and.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-3801247530116608246</guid><pubDate>Mon, 13 Dec 2010 18:20:00 +0000</pubDate><atom:updated>2010-12-13T13:20:46.430-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">linkage</category><title>batch script to delete cvs files</title><description>for /f "tokens=*" %%i in ('dir /b/a/s CVS*') do @rmdir /q /s "%%i"&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
source: &lt;a href="http://www.danieltome.com/blog/2007/01/13/delete-cvs-files/"&gt;http://www.danieltome.com/blog/2007/01/13/delete-cvs-files/&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-3801247530116608246?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/vd8QN1SgWzE" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/vd8QN1SgWzE/batch-script-to-delete-cvs-files.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/12/batch-script-to-delete-cvs-files.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-8350185307940606626</guid><pubDate>Sun, 05 Dec 2010 03:38:00 +0000</pubDate><atom:updated>2010-12-05T00:08:56.151-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">groovy</category><title>Convert map to object in groovy</title><description>You need to convert a map into an object in groovy. There must be a better way then iterating through the map and setting all the properties in the object via reflection or otherwise. There is:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;script class="brush: java" type="syntaxhighlighter"&gt;

def MyObject mapToObject(def map){
   new MyObject( map.findAll { k, v -&gt; k in MyObject.metaClass.properties*.name})
}

&lt;/script&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-8350185307940606626?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/PtpUIvz4rfk" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/PtpUIvz4rfk/convert-map-to-object-in-groovy.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/12/convert-map-to-object-in-groovy.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-5030544915883898306</guid><pubDate>Sun, 05 Dec 2010 03:34:00 +0000</pubDate><atom:updated>2010-12-04T22:35:13.015-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">how to</category><title>posting with syntaxhighlighter</title><description>I always forget the markup for posting syntax highlighted code. here it is:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;script class="brush: java" type="syntaxhighlighter"&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
thank me later&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-5030544915883898306?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/3LeXtJNll-0" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/3LeXtJNll-0/posting-with-syntaxhighlighter.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/12/posting-with-syntaxhighlighter.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-7452434373576676503</guid><pubDate>Thu, 02 Dec 2010 04:48:00 +0000</pubDate><atom:updated>2010-12-01T23:48:25.097-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">linkage</category><title>Image size shrinking tool</title><description>I always forget what this is called:&lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://www.smushit.com/ysmush.it/"&gt;http://www.smushit.com/ysmush.it/&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-7452434373576676503?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/Vd3lpAMXU1Q" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/Vd3lpAMXU1Q/image-size-shrinking-tool.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/12/image-size-shrinking-tool.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-468573947468134077</guid><pubDate>Tue, 30 Nov 2010 00:27:00 +0000</pubDate><atom:updated>2010-11-29T19:27:24.123-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">solutions</category><title>fixing java.lang.NoClassDefFoundError: javax/el/ELContext error</title><description>I got the error &lt;b&gt;java.lang.NoClassDefFoundError: javax/el/ELContext&amp;nbsp; &lt;/b&gt;when i was trying to run a unit test.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Solution:&lt;/b&gt;&lt;br /&gt;
el-api.jar needs to be in your class path. This is usually found in the tomcat/lib dir. I usually add everything in the tomcat lib to my classpath&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-468573947468134077?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/TXe_b02VrrM" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/TXe_b02VrrM/fixing-javalangnoclassdeffounderror.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/11/fixing-javalangnoclassdeffounderror.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-8596692902140784608</guid><pubDate>Mon, 29 Nov 2010 18:04:00 +0000</pubDate><atom:updated>2010-11-29T13:04:46.219-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">sql</category><title>select from two tables into a single column</title><description>delete from user where id not in (select a.id from person a UNION select b.id from merchant b)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-8596692902140784608?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/u3IzsvglGgc" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/u3IzsvglGgc/select-from-two-tables-into-single.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/11/select-from-two-tables-into-single.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-5758219765318985526</guid><pubDate>Wed, 10 Nov 2010 15:49:00 +0000</pubDate><atom:updated>2010-11-10T10:49:12.586-05:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">sql</category><title>Test mysql connection</title><description>mysql -u user -p -h 10.0.0.0&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-5758219765318985526?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/2VaIsjLFWp4" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/2VaIsjLFWp4/test-mysql-connection.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/11/test-mysql-connection.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-2486129970626540024</guid><pubDate>Tue, 26 Oct 2010 21:59:00 +0000</pubDate><atom:updated>2010-10-26T17:59:33.957-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">hibernate</category><category domain="http://www.blogger.com/atom/ns#">solutions</category><title>No Hibernate Session bound to thread</title><description>&lt;b&gt;Problem:&lt;/b&gt;&lt;br /&gt;
I am converting an application that uses &lt;b&gt;HibernateDaoSupport &lt;/b&gt;in the DAOs to use POJOs instead.&lt;br /&gt;
Each pojo now must autowire a sessionFactory in order to hook into hibernate.&lt;br /&gt;
&lt;br /&gt;
I am getting the following error when i try to getSession() on my sessionFactory:&lt;br /&gt;
&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;No Hibernate Session bound to thread, and configuration does not allow creation of non-transactional one here&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Solution:&lt;/b&gt;&lt;br /&gt;
add a OpenSessionInViewFilter to my web.xml and filter on * with it&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-2486129970626540024?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/5cUbHKbWgTE" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/5cUbHKbWgTE/no-hibernate-session-bound-to-thread.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/10/no-hibernate-session-bound-to-thread.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-1022888895853026446</guid><pubDate>Sat, 16 Oct 2010 14:46:00 +0000</pubDate><atom:updated>2010-10-16T10:46:53.725-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">greasemonkey</category><title>MLSPin google maps grease monkey script</title><description>&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://3.bp.blogspot.com/_YdOQjxUsGtA/TLm6b3IK4-I/AAAAAAAAAEE/qpMa6t4UJEM/s1600/mls.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="212" src="http://3.bp.blogspot.com/_YdOQjxUsGtA/TLm6b3IK4-I/AAAAAAAAAEE/qpMa6t4UJEM/s400/mls.png" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;I am looking at houses.&lt;br /&gt;
I am on the mlspin website which has addresses but no maps. I end up having to go look up these addresses in google maps.&lt;br /&gt;
&lt;br /&gt;
This plugin adds a google map iframe on each listing page in mls pin.&lt;br /&gt;
&lt;br /&gt;
download:&lt;br /&gt;
&lt;a href="http://userscripts.org/scripts/show/88186"&gt;http://userscripts.org/scripts/show/88186&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Runs on: http://vow.mlspin.com/clients/&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-1022888895853026446?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/jT-V6-REAdE" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/jT-V6-REAdE/mlspin-google-maps-grease-monkey-script.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/_YdOQjxUsGtA/TLm6b3IK4-I/AAAAAAAAAEE/qpMa6t4UJEM/s72-c/mls.png" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/10/mlspin-google-maps-grease-monkey-script.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-801652018089456452</guid><pubDate>Thu, 02 Sep 2010 14:32:00 +0000</pubDate><atom:updated>2010-09-03T09:13:23.891-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">cooking</category><title>Babushka's Mushroom Soup</title><description>&lt;ol&gt;&lt;li&gt;make chicken or beef broth in a 2 liter pot&lt;/li&gt;
&lt;li&gt;add some rice (4-5 TBSP)&lt;/li&gt;
&lt;li&gt;let boil so that rice and potatos cook&lt;/li&gt;
&lt;li&gt;cut up some mushrooms and add them. wait until it boils&lt;/li&gt;
&lt;li&gt;combine ghee, 2 grated carrots and 1 chopped onion, salt, pepper, 1/4 tsp sugar. cook in the microwave for 2-3 mins&lt;/li&gt;
&lt;li&gt;when the halved potatos are cooked, take them out and mash them&lt;/li&gt;
&lt;li&gt;add potatos and ghee mixture to the soup&lt;/li&gt;
&lt;li&gt;take out some broth and put it in a cup, add 2 tablespoons of mushroom cheese, and mix&lt;/li&gt;
&lt;li&gt;add mushroom cheese mixture into the soup&lt;/li&gt;
&lt;li&gt;add bay leaf and greens&lt;/li&gt;
&lt;/ol&gt;&lt;br /&gt;
done!&lt;br /&gt;
&lt;br /&gt;
For those who are wondering what mushroom cheese is. &lt;a href="http://www.alibaba.com/product-free/264104361/CHEESE_Sertop_Processed_Cheese_with_Mushrooms.html"&gt;here is a link to an example of it.&lt;/a&gt;&lt;br /&gt;
I found some being sold in a Russian store. You can buy ghee at whole foods&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-801652018089456452?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/zqw67PeEi9U" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/zqw67PeEi9U/babushkas-mushroom-soup.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/09/babushkas-mushroom-soup.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-4236121798876407330</guid><pubDate>Tue, 24 Aug 2010 11:15:00 +0000</pubDate><atom:updated>2010-08-24T07:15:50.924-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">javascript</category><category domain="http://www.blogger.com/atom/ns#">solutions</category><title>Waiting for things in javascript</title><description>&lt;b&gt;Problem:&lt;/b&gt;&lt;br /&gt;
Sometimes i need to wait for something to come into existence in javascript, and then do something with it. This is usually because another frame (&lt;i&gt;shudder&lt;/i&gt;) is still loading and i need something in it. Also it helps with IE bugs where something &lt;b&gt;should&lt;/b&gt; be there, but isn't because IE is taking a stupid long time to load it. &lt;br /&gt;
&lt;b&gt;&lt;br /&gt;
Solution:&lt;/b&gt;&lt;br /&gt;
Use this utility function to create a check/act loop.&lt;br /&gt;
&lt;script type="syntaxhighlighter" class="brush: js"&gt;
/**
 * Helper function to wait for something to load, and then do something. 
 * Usage:
 *
 * @param checkFn - return true when resources required by actionFn are available, false otherwise
 * @param actionFn - the actual thing you need to happen
 * @param tries - how many tries before giving up [optional, default = 15]
 * @param waitMs - how long to wait between tries in ms [optional, default = 100]
 */
var waiter = function(checkFn, actionFn, tries, waitMs){
    tries = tries || 15;
    waitMs = waitMs || 100;
    var doer = function(){
        if(checkFn()){
            actionFn();
        } else if(tries-- &gt; 0) {
            setTimeout(doer, waitMs);
        }
    };
    doer();
}
&lt;/script&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-4236121798876407330?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/_vo-VmF84-Q" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/_vo-VmF84-Q/waiting-for-things-in-javascript.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/08/waiting-for-things-in-javascript.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-2848068950667661882</guid><pubDate>Thu, 29 Jul 2010 02:37:00 +0000</pubDate><atom:updated>2010-07-28T22:37:27.688-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">javascript</category><title>javascript obfuscation</title><description>I might need this crazy javascript obfuscation one day. Either that, or its fun to look at:&lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://discogscounter.getfreehosting.co.uk/js-noalnum.php?txt=alert%28%22hai%22%29"&gt;http://discogscounter.getfreehosting.co.uk/js-noalnum.php?txt=alert%28%22hai%22%29&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-2848068950667661882?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/k_g9DR6bTuA" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/k_g9DR6bTuA/javascript-obfuscation.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/07/javascript-obfuscation.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-20715940.post-5750744821397304206</guid><pubDate>Fri, 23 Jul 2010 15:12:00 +0000</pubDate><atom:updated>2010-07-23T11:12:30.121-04:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">java</category><title>Make a Map from a list, perl style</title><description>Make a Map from a varargs list. Useful for iBatis parameterClass objects.&lt;br /&gt;
&lt;br /&gt;
&lt;script type="syntaxhighlighter" class="brush: java"&gt; 
  public Map getMap(Object... params) {
    Map&lt;Object, Object&gt; ret = new HashMap&lt;Object, Object&gt;();
    if (params != null &amp;&amp; params.length % 2 == 0) {
      for (int i = 0; (i + 1) &lt; params.length; i += 2) {
        ret.put(params[i], params[i + 1]);
      }
    }
    return ret;
  }
&lt;/script&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20715940-5750744821397304206?l=notetodogself.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/notetoself/~4/QH_W4xQjr4M" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/blogspot/notetoself/~3/QH_W4xQjr4M/make-map-from-list-perl-style.html</link><author>noreply@blogger.com (Mikhail Koryak)</author><thr:total>0</thr:total><feedburner:origLink>http://notetodogself.blogspot.com/2010/07/make-map-from-list-perl-style.html</feedburner:origLink></item></channel></rss>

