<?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:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0"><channel><title>Andornot Developers' Blog</title><link>http://www.andornot.com/about/developerblog/Default.aspx</link><description></description><language>en</language><managingEditor>noreply@blogger.com (Peter Tyrrell)</managingEditor><lastBuildDate>Wed, 04 Nov 2009 08:46:48 PST</lastBuildDate><generator>Blogger http://www.blogger.com</generator><openSearch:totalResults xmlns:openSearch="http://a9.com/-/spec/opensearchrss/1.0/">233</openSearch:totalResults><openSearch:startIndex xmlns:openSearch="http://a9.com/-/spec/opensearchrss/1.0/">1</openSearch:startIndex><openSearch:itemsPerPage xmlns:openSearch="http://a9.com/-/spec/opensearchrss/1.0/">25</openSearch:itemsPerPage><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/AndornotDevelopersBlog" type="application/rss+xml" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com" /><item><title>Fix IE8 unable to authenticate on a local website using Windows authentication</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/W-nDj6HkmNE/fix-ie8-unable-to-authenticate-on-local.aspx</link><author>noreply@blogger.com (Peter Tyrrell)</author><pubDate>Wed, 21 Oct 2009 15:05:02 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-2410470264160936947</guid><description>&lt;p&gt;&lt;strong&gt;Symptom&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;IE8 refuses to authenticate on a local website (website and browser are on the same machine) even when valid credentials are supplied, when the website is reached using a host header bound to the machine's loopback address. After a few attempts, the website reports an HTTP 401.1 Access Denied error. A different browser may authenticate successfully. Browsing the website with IE8 from an external client computer authenticates as expected.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Cure&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;A Windows security update is responsible for a loopback check security feature that is meant to prevent reflection attacks. Authentication fails if the host header does not match the local computer name. Disable the loopback check in the registry:&lt;/p&gt; &lt;ol&gt; &lt;li&gt;Run regedit.&lt;/li&gt; &lt;li&gt;Find &lt;em&gt;HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa&lt;/em&gt;.&lt;/li&gt; &lt;li&gt;Add a new DWORD value called &lt;strong&gt;DisableLoopbackCheck&lt;/strong&gt;.&lt;/li&gt; &lt;li&gt;Modify the new value data to &lt;strong&gt;1&lt;/strong&gt;.&lt;/li&gt; &lt;li&gt;Reboot.&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;&lt;strong&gt;Related&lt;/strong&gt;&lt;/p&gt; &lt;ul&gt; &lt;li&gt;More info at Microsoft KB article 896861: &lt;a title="http://support.microsoft.com/kb/896861" href="http://support.microsoft.com/kb/896861"&gt;http://support.microsoft.com/kb/896861&lt;/a&gt;.&lt;/li&gt;&lt;/ul&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-2410470264160936947?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/W-nDj6HkmNE" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/10/fix-ie8-unable-to-authenticate-on-local.aspx</feedburner:origLink></item><item><title>How to enable Windows 7 single sign-on for a website using Windows authentication</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/O0uP7FjL030/how-to-enable-windows-7-single-sign-on.aspx</link><category>windows7</category><author>noreply@blogger.com (Peter Tyrrell)</author><pubDate>Wed, 21 Oct 2009 15:35:17 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-2962302517161837121</guid><description>&lt;p&gt;&lt;strong&gt;Symptom&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;You visit an intranet website that uses Windows authentication with an IE browser on Windows 7 and expect to be logged in automatically with your current domain credentials. Instead, you are challenged for credentials. Once you enter credentials everything acts normally, but you expect a single sign-in scenario and it doesn't happen. If you visit the same URL with IE on another Windows OS within the domain, single sign-on works as expected.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Cure&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;A default local security policy in Windows 7 prevents LM and NTLM responses. &lt;/p&gt; &lt;ol&gt; &lt;li&gt;Go to Local Security Policy &amp;gt; Security Settings &amp;gt; Local Policies &amp;gt; Security Options  &lt;li&gt;Select &lt;em&gt;Network security: LAN Manager authentication level&lt;/em&gt;  &lt;li&gt;Change security setting to &lt;em&gt;Send LM &amp;amp; NTLM responses&lt;/em&gt;&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;&lt;a href="http://andornot.com/about/developerblog/uploaded_images/HowtoenableWindows7singlesignonforawebsi_CF0D/win7_secpol.png"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="win7_secpol" border="0" alt="win7_secpol" src="http://andornot.com/about/developerblog/uploaded_images/HowtoenableWindows7singlesignonforawebsi_CF0D/win7_secpol_thumb.png" width="404" height="156"&gt;&lt;/a&gt; &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Related&lt;/strong&gt;&lt;/p&gt; &lt;ul&gt; &lt;li&gt;Another possible local security policy to try is &lt;em&gt;Network security: Configure encryption types allowed for Kerberos&lt;/em&gt;. &lt;a title="http://serverfault.com/questions/51747/windows-7-single-sign-on" href="http://serverfault.com/questions/51747/windows-7-single-sign-on"&gt;http://serverfault.com/questions/51747/windows-7-single-sign-on&lt;/a&gt;.  &lt;li&gt;How to enable NTLM single sign-on behaviour in Firefox: &lt;a title="http://sivel.net/2007/05/firefox-ntlm-sso/" href="http://sivel.net/2007/05/firefox-ntlm-sso/"&gt;http://sivel.net/2007/05/firefox-ntlm-sso/&lt;/a&gt;.&lt;/li&gt;&lt;/ul&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-2962302517161837121?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/O0uP7FjL030" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/10/how-to-enable-windows-7-single-sign-on.aspx</feedburner:origLink></item><item><title>Google Book Covers and Previews</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/rh2uYrGCfvQ/google-book-covers-and-previews.aspx</link><category>web 2.0</category><category>ASK</category><category>inmagic</category><category>Google Books</category><category>WebPublisher Pro</category><author>noreply@blogger.com (Denise Bonin)</author><pubDate>Tue, 20 Oct 2009 22:27:21 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-5232743445641920931</guid><description>&lt;p&gt;&lt;b&gt;Library catalogues are boring.&lt;/b&gt;&amp;nbsp; Face it, their dullness is only mitigated by the thrill received when your catalogue search results have either a link to the full text or a website or to an image or something other than just the basic bibliographic details.&amp;nbsp; Ok, some folks use the library catalogue to find books - on the shelf and in their library - but if you are not familiar with that book, how do you know if it is worth your while seeking out?&amp;nbsp; &lt;p&gt;&lt;b&gt;See the cover and preview the book.&lt;/b&gt;&amp;nbsp; Now there is a way to liven up and to add value to your catalogue, with both a book cover image and a preview of the text, if they are available.&amp;nbsp; Just by having the book's ISBN in the catalogue database, a link can be made to &lt;a href="http://books.google.com/intl/en/googlebooks/about.html"&gt;Google Books&lt;/a&gt;.&amp;nbsp; With this link you can have an image of the book's cover in full and beautiful colour displayed next to the bibliographic information.&amp;nbsp; You can also have a link to the Google Book Preview, if it is available.&amp;nbsp; Andornot has &lt;a href="http://www.andornot.com/about/developerblog/2008/04/adding-google-book-search-information.aspx"&gt;long since advocated&lt;/a&gt; enhancing the library catalogue and added the Google Books covers and previews to its own &lt;a href="http://ask.andornot.com/Results.aspx?BU=http://ask.andornot.com/default.aspx&amp;amp;TN=starter&amp;amp;QY=find%20%28ISBN%20%3D*%29&amp;amp;RF=WebBrief&amp;amp;DF=WebFull&amp;amp;MR=10&amp;amp;NP=255&amp;amp;RL=0&amp;amp;DL=0&amp;amp;XC=&amp;amp;ID=&amp;amp;AC=QBE_QUERY"&gt;Starter Kit&lt;/a&gt;.&amp;nbsp; We then suggested that Inmagic WebPublisher PRO &lt;a href="http://andornot.com/Services/Hosting/HostedClients.aspx"&gt;hosted clients&lt;/a&gt; do the same.&amp;nbsp; &lt;p&gt;&lt;b&gt;Several clients took up the offer&lt;/b&gt; and now there are many examples to show you.&amp;nbsp; Elizabeth Lamont from the Royal Victoria Hospital Library, who oversees the coordination of the McGill University Health Centre Libraries &lt;a href="http://muhclibraries.andornot.com/Books/Default.aspx"&gt;catalogue&lt;/a&gt; (try the &lt;a href="http://muhclibraries.andornot.com/Books/Results.aspx?TN=BooksRVHLIB&amp;amp;QY=find%20%28RSS%20%3Dyes%29&amp;amp;RF=WebDate&amp;amp;DF=WebFull&amp;amp;BU=http%3A%2F%2Fmuhclibraries.andornot.com%2FBooks%2FDefault.aspx&amp;amp;MR=20&amp;amp;NP=255&amp;amp;RL=0&amp;amp;DL=0&amp;amp;MF=DefaultEngWPMSG.ini&amp;amp;AC=QBE_QUERY&amp;amp;XC=http%3A%252"&gt;New Books link&lt;/a&gt;), loved this feature:&amp;nbsp; "&lt;i&gt;Nice visuals for our users. We particularly like the added information on book contents. All without any extra work on our part!"&amp;nbsp; &lt;/i&gt;Both Lance Nordstom and Marci Gibson from WorkSafeBC appreciated the addition to their &lt;a href="http://worksafebc.andornot.com/Advsearch.aspx"&gt;library catalogue&lt;/a&gt; of "&lt;i&gt;a bit of colour to the results pages"&lt;/i&gt;.&amp;nbsp; When it was suggested to Leah Harms, the librarian at the Resource Library for the Environment and the Law, that she add this feature to her &lt;a href="http://rlel.andornot.com/Advsearch.aspx"&gt;library catalogue&lt;/a&gt;, she said of the &lt;a href="http://books.google.com/books?id=wlcgHwHVtNgC&amp;amp;pg=PA138&amp;amp;dq=9781552452080#v=onepage&amp;amp;q=&amp;amp;f=false"&gt;Google Books Preview example&lt;/a&gt; shown to her that she "&lt;i&gt;had no idea how great that book was until I read the preview."&lt;/i&gt;&amp;nbsp; And after we added them Leah commented: "&lt;i&gt;I really am very pleased with the vibrancy of the covers and the usefulness of having the preview links. They function to better pique curiosity much like abstracts do for journal articles&lt;/i&gt;."  &lt;p&gt;&lt;b&gt;You can also see this feature&lt;/b&gt; on a few other catalogue databases:&amp;nbsp; &lt;a href="http://nha.andornot.com/"&gt;Northern Health&lt;/a&gt;, &lt;a href="http://iha.andornot.com/"&gt;Interior Health&lt;/a&gt;, &lt;a href="http://vch.andornot.com/"&gt;Vancouver Coastal Health&lt;/a&gt;, &lt;a href="http://fha.andornot.com/"&gt;Fraser Health&lt;/a&gt;, and the &lt;a href="http://rcvo.andornot.com/Library/LibrarySearch.aspx"&gt;Resource Centre for Voluntary Organizations&lt;/a&gt;.&amp;nbsp; For best results, may we suggest that you search for &lt;strong&gt;books&lt;/strong&gt; published since &lt;strong&gt;2000&lt;/strong&gt;.  &lt;p&gt;&lt;a href="mailto:info@andornot.com?subject=Google%20Book%20Covers"&gt;Contact us&lt;/a&gt; to help you add Google Book covers and previews to your online catalogue.&amp;nbsp; &lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-5232743445641920931?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/rh2uYrGCfvQ" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/10/google-book-covers-and-previews.aspx</feedburner:origLink></item><item><title>How to set up ClamAV as a Windows Service to scan file streams on demand</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/kIBkK1-fVSk/how-to-set-up-clamav-as-windows-service.aspx</link><author>noreply@blogger.com (Peter Tyrrell)</author><pubDate>Fri, 16 Oct 2009 09:48:56 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-7470075157905384709</guid><description>&lt;p&gt;&lt;strong&gt;Overview&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Clam Antivirus, or ClamAV for short, is an open-source antivirus solution for UNIX. It's also the ONLY open-source antivirus solution. Naturally it would nice to have it for Windows, too, and it's absolutely possible; the hard part is finding out how to go about it.&lt;/p&gt; &lt;p&gt;Documentation on installing ClamAV for Windows and running its daemon &lt;em&gt;clamd&lt;/em&gt; as a Windows Service is as scarce as hen's teeth, and the best information I could find was scattered across various unrelated forums and articles and none of it was fully up to date. So here it is, laid out as best as I can tell it, in one place: where to find a current native Win32 port of ClamAV, how to install it, how to set up &lt;em&gt;clamd&lt;/em&gt; to run as a service, and the settings relevant to scanning file streams sent from an external client.&lt;/p&gt; &lt;p&gt;To give some context: I am using ClamAV to scan user-uploaded files for viruses in an ASP.NET web application, before writing them to disk. Each upload is sent as a stream from the webserver to another Windows 2003 server running the &lt;em&gt;clamd&lt;/em&gt; service, which scans them and replies with some basic info on the outcome of the scan.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Get the current version of ClamAV for Windows&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Get ClamAV for Windows 0.95.2 at &lt;a title="http://hideout.ath.cx/clamav/" href="http://hideout.ath.cx/clamav/"&gt;http://hideout.ath.cx/clamav/&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;I am writing on October 15, 2009 and the current version of &lt;a href="http://oss.netfarm.it/clamav/"&gt;Clam AntiVirus&lt;/a&gt; is 0.95.2. The best 0.95.2 native Windows port available, in my opinion - because it has an installer - is at &lt;a title="http://hideout.ath.cx/clamav/" href="http://hideout.ath.cx/clamav/"&gt;http://hideout.ath.cx/clamav/&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;Another 0.95.2 alternative is at &lt;a title="http://oss.netfarm.it/clamav/" href="http://oss.netfarm.it/clamav/"&gt;http://oss.netfarm.it/clamav/&lt;/a&gt;, but does not have an installer and requires you grab an additional assembly from Microsoft. On the other hand, it offers a 64 bit build.&lt;/p&gt; &lt;p&gt;You don't want &lt;a href="http://www.clamwin.com/"&gt;ClamWin&lt;/a&gt;, which is a GUI aimed at the desktop crowd, and doesn't include &lt;em&gt;clamd&lt;/em&gt;. Or it doesn't appear to right now. It might later. Maybe. It's hard to tell. See &lt;em&gt;hen's teeth&lt;/em&gt;, above. Nor do you want the former native Win32 port at &lt;a title="http://w32.clamav.net/" href="http://w32.clamav.net/"&gt;http://w32.clamav.net/&lt;/a&gt; which is dead, dead, dead at version 0.92.1. Nor the Cygwin version, nor the Interix version. No.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Install ClamAV for Windows&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Run the installer, &lt;em&gt;ClamAV-095-2.exe.&lt;/em&gt; It is best to let the installer deploy to the default location, which is &lt;em&gt;c:\clamav\&lt;/em&gt;, or you'll have to manually modify a bunch of clamav settings files afterwards.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Install &lt;em&gt;clamd&lt;/em&gt; as a service&lt;/strong&gt;&lt;/p&gt; &lt;ol&gt; &lt;li&gt;Open a command prompt.  &lt;li&gt;Change directory to c:\clamav\ or wherever you installed clamav.  &lt;li&gt;Run clamd.exe --install  &lt;li&gt;Open services.msc and edit the newly installed "ClamWin Free Antivirus Scanner Service" to start Automatically and/or use credentials other than the local system account, etc.&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;&lt;a href="http://andornot.com/about/developerblog/uploaded_images/HowtosetupClamAVasaWindowsServicetoscanf_F61A/clamav_cmd.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="clamav_cmd" border="0" alt="clamav_cmd" src="http://andornot.com/about/developerblog/uploaded_images/HowtosetupClamAVasaWindowsServicetoscanf_F61A/clamav_cmd_thumb.png" width="506" height="185"&gt;&lt;/a&gt; &lt;/p&gt; &lt;p&gt;Um, yes, that was easy. &lt;/p&gt; &lt;p&gt;The astute will note that the service names itself "ClamWin yada yada." Again, &lt;em&gt;clamd&lt;/em&gt; is NOT included with ClamWin, so your guess is as good as mine as to the connection here, but there clearly *is* some connection, the true nature of which I have been unable to fathom.&lt;/p&gt; &lt;p&gt;You may find, if you Google for "clamd windows service", various helpful threads or articles describing how to forcibly set up &lt;em&gt;clamd&lt;/em&gt; as a service with instsrv.exe and srvany.exe from the Windows 2003 Resource Kit Tools. And that works - but it's not necessary. I can only assume that the ClamAV Windows ports came out with a built-in "install as service" feature at some point fairly recently, but the word just hasn't got around. &lt;/p&gt; &lt;p&gt;I'll get to the settings for &lt;em&gt;clamd&lt;/em&gt; next, but you need an up-to-date antivirus library first.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Schedule freshclam to update frequently&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;&lt;em&gt;Freshclam&lt;/em&gt; fetches antivirus library updates. You need to run it right away to get the initial database up and going - just double-click freshclam.exe. After that, you can install it as a service in the same manner as &lt;em&gt;clamd&lt;/em&gt; above. Or create a batch file that runs freshclam.exe on a schedule with Windows Task Scheduler. It has its own settings file: freshclam.conf.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Settings for on-demand stream scanning&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Settings for &lt;em&gt;clamd&lt;/em&gt; are in clamd.conf, and there are quite a few, but the ones most relevant for on-demand stream scanning are:&lt;/p&gt; &lt;ul&gt; &lt;li&gt;TCPAddr - server IP address  &lt;li&gt;TCPSocket - port clamd will listen on, default 3310  &lt;li&gt;StreamMaxLength - maximum size of stream to be scanned, in megabytes&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;&lt;strong&gt;Create a Windows firewall exception&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;The lazy way out here is to add clamd.exe as an exception to Windows firewall. Read on if you like.&lt;/p&gt; &lt;p&gt;You can exception just the port &lt;em&gt;clamd&lt;/em&gt; listens on (default 3310), but a call to its STREAM method generates a reply on a random port with a range you can set in clamd.conf, which would mean you would have to add exceptions for the entire range. To problematize still further, STREAM has been deprecated in favour of INSTREAM, which sticks to the port you called it on in the first place. For now I'm just going to exception clamd.exe, though I did restrict its scope to the local subnet.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Call &lt;em&gt;clamd&lt;/em&gt; from ASP.NET&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;I've found just one available .NET library that will call a &lt;em&gt;clamd&lt;/em&gt; service, called WRAVLib: &lt;a title="http://www.wolfereiter.com/antivirus.aspx" href="http://www.wolfereiter.com/antivirus.aspx"&gt;http://www.wolfereiter.com/antivirus.aspx&lt;/a&gt;. Unfortunately, it's somewhat out of date and written for .NET 1.1, but happily the source code is freely available, so you can compile for .NET 3.5 if you like. Direct link to source code is here: &lt;a title="http://www.wolfereiter.com/Downloads/wravlib/wravlib-1.1-src.zip" href="http://www.wolfereiter.com/Downloads/wravlib/wravlib-1.1-src.zip"&gt;http://www.wolfereiter.com/Downloads/wravlib/wravlib-1.1-src.zip&lt;/a&gt;. &lt;/p&gt; &lt;p&gt;It does target the deprecated STREAM method instead of INSTREAM, which I touched on above, but it's still the fastest way to get up and running. Here's a bit of pseudocode to give an idea:&lt;/p&gt; &lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt; &lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #008000"&gt;// create scan agent&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;IVirusScanAgent agent = &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; ClamdStreamAgent(&lt;span style="color: #006080"&gt;"127.0.0.1"&lt;/span&gt;, 3310, &lt;span style="color: #0000ff"&gt;false&lt;/span&gt;);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&amp;nbsp;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #008000"&gt;// create unique scan id&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #0000ff"&gt;string&lt;/span&gt; scanId = Guid.NewGuid().ToString();&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&amp;nbsp;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;agent.VirusFound += ((sender, args) =&amp;gt; {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;   &lt;span style="color: #008000"&gt;// do something&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;});&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&amp;nbsp;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;agent.ItemScanCompleted += ((sender, args) =&amp;gt;  {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;   &lt;span style="color: #008000"&gt;// do something&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;});                                  &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;                                    &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #008000"&gt;// scan filestream&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;agent.Scan(scanId, file.InputStream);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&lt;strong&gt;Conclusion&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I wish I had more time to fill in the gaps and provide more detail, but I just don't. Even this amount of information took way too long to gather in the first place! It should provide a good foundation nevertheless.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Acknowledgements&lt;/strong&gt;&amp;nbsp;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;This &lt;a href="http://support.kerio.com/index.php?_m=knowledgebase&amp;amp;_a=viewarticle&amp;amp;kbarticleid=426"&gt;how-to&lt;/a&gt; on setting up ClamAV for Kerio MailServer on Windows convinced me I could run &lt;em&gt;clamd&lt;/em&gt; as a service in the first place.
&lt;li&gt;This &lt;a href="http://www.hmailserver.com/forum/viewtopic.php?f=12&amp;amp;t=12171"&gt;forum thread&lt;/a&gt; on installing ClamAV Win32 with hMailserver was instrumental, guiding me with sample settings files and good pointers.&lt;/li&gt;&lt;/ul&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-7470075157905384709?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/kIBkK1-fVSk" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/10/how-to-set-up-clamav-as-windows-service.aspx</feedburner:origLink></item><item><title>How to install Inmagic Webpublisher 12 on Windows 7</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/uMSdUwQGITY/how-to-install-inmagic-webpublisher-12.aspx</link><category>windows7</category><category>inmagic</category><category>Webpublisher</category><category>IIS 7</category><author>noreply@blogger.com (Peter Tyrrell)</author><pubDate>Thu, 15 Oct 2009 09:40:23 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-2076805308890579498</guid><description>&lt;p&gt;Disclaimer: Not officially supported. Plunging heedlessly on...&lt;/p&gt; &lt;p&gt;&lt;strong&gt;1 - Back up INI files&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;First back up all your .ini files. Be sure you are getting the CORRECT copy of the ini file: the ini files in the Program Files directory are access-protected in Vista and Win7 because the Program Files area is a forbidden zone. You must open the ini file with elevated privileges, like with Notepad "run as administrator", and save it somewhere safe.&lt;/p&gt; &lt;ul&gt; &lt;li&gt;dbtwpub.ini  &lt;li&gt;inmagic.ini  &lt;li&gt;dbtext.ini&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;&lt;strong&gt;2 - Upgrade from previous version&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;If you want to upgrade from previous version of WPP instead installing a fresh copy, uninstall the previous version MANUALLY first, because the WPP 12 installer tries to uninstall without elevated permission, and thus fails. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;3 - Run installer as admin&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Run the WPP 12 installer with administrator privileges. If you have a setup.exe you can right-click to "run as administrator". &lt;/p&gt; &lt;p&gt;My preview version of the installer is an *.msi file only, which doesn't have a right-click "run as admin" option. Instead, I launch the msi with msiexec from an elevated command prompt:&lt;/p&gt; &lt;ol&gt; &lt;li&gt;Search for "cmd.exe" from Windows Start Menu  &lt;li&gt;Right-click cmd.exe and "run as administrator"  &lt;li&gt;Change directory to location of the msi, e.g. &lt;em&gt;cd c:\users\ptyrrell\downloads&lt;/em&gt;  &lt;li&gt;Run the msi with the &lt;a href="http://support.microsoft.com/kb/314881"&gt;msiexec /i option&lt;/a&gt;, e.g. &lt;em&gt;msiexec /i "Inmagic DBText WebPublisher PRO.msi"&lt;/em&gt;&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;&lt;strong&gt;4 - Fulfill prerequisites&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;The installer is cleverer than previous versions when checking for prerequisites, so you'll probably have to go and install or enable various Windows features before continuing. &lt;br&gt;&lt;br&gt;&lt;a href="http://andornot.com/about/developerblog/uploaded_images/HowtoinstallInmagicWebpublisher12onWindo_920D/wpp12_prereqs.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="wpp12_prereqs" border="0" alt="wpp12_prereqs" src="http://andornot.com/about/developerblog/uploaded_images/HowtoinstallInmagicWebpublisher12onWindo_920D/wpp12_prereqs_thumb.png" width="508" height="386"&gt;&lt;/a&gt;&amp;nbsp;&lt;br&gt;&lt;br&gt;IIS 6 Compatibility (IIS7 only) seems to be satisfied by enabling the "IIS Metabase and IIS 6 configuration compatibility" Windows feature.&lt;br&gt;&lt;br&gt;&lt;a href="http://andornot.com/about/developerblog/uploaded_images/HowtoinstallInmagicWebpublisher12onWindo_920D/wpp12_iis6.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="wpp12_iis6" border="0" alt="wpp12_iis6" src="http://andornot.com/about/developerblog/uploaded_images/HowtoinstallInmagicWebpublisher12onWindo_920D/wpp12_iis6_thumb.png" width="471" height="330"&gt;&lt;/a&gt; &lt;br&gt;&lt;br&gt;&lt;font color="#ff0000"&gt;Be warned&lt;/font&gt;: if you don't run the installer with elevated privileges, you will continue to fail the prerequisite check even after installing/enabling the right prerequisites!&lt;/p&gt; &lt;p&gt;&lt;/p&gt; &lt;p&gt;&lt;strong&gt;5 - Test the install&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Restore your backed up ini files. Run a query on the sample cars textbase to ensure WPP is returning results as expected.&lt;/p&gt; &lt;p&gt;If you are installing on a 64 bit machine, you need to enable 32 bit applications on the relevant application pool as covered in this previous post called &lt;a href="http://www.andornot.com/about/developerblog/2008/05/how-to-install-webpublisher-on-64-bit.aspx"&gt;How to Install Webpublisher on 64-bit IIS 7&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;6 - Be the star you know you are&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;You did it! Now cut out a cardboard star with safety scissors, pencil "STAR HACKER" on it, and get your mum to pin it to your chest, glitter optional. Salute yourself in the mirror. Star! Hacker!&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-2076805308890579498?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/uMSdUwQGITY" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/10/how-to-install-inmagic-webpublisher-12.aspx</feedburner:origLink></item><item><title>Handling 404 errors with ASP.NET</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/rAofcM3HtcU/handling-404-errors-with-aspnet.aspx</link><category>asp.net</category><author>noreply@blogger.com (Ted Jardine)</author><pubDate>Tue, 06 Oct 2009 17:18:32 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-636297629501512154</guid><description>&lt;p&gt;As &lt;a href="http://www.andornot.com/about/developerblog/2009/10/errors-sending-right-message.aspx"&gt;mentioned at the end of my previous post on handling errors with ASP.NET&lt;/a&gt;, handling "404 Not Found" errors are particularly problematic (if you haven't read it yet, please do so). And looking around, the vast majority of information out there on it is not complete, misinformed, or flat-out wrong (but I greatly appreciate all efforts!). And I would argue that this is because ASP.NET implementation of 404 error handling is flat-out-wrong. So with my super hero cape on, here I come to wobbly save the day!&lt;/p&gt; &lt;p&gt;The typical ASP.NET way to handle 404 errors is to put something like the following in your Web.config:&lt;/p&gt; &lt;p&gt;&amp;lt;customErrors mode="On" defaultRedirect="~/error.aspx"&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;error statusCode="404" redirect="~/page-not-found.aspx" /&amp;gt;&lt;br&gt;&amp;lt;/customErrors&amp;gt;  &lt;p&gt;Make a page-not-found.aspx page and voila! Ya got 'er dun! If you're a little more on the ball, you'll realise that while this configuration works for end users (gives them a pretty page to look at hopefully clearly explaining that you can't find what they're looking for), it's bad for SEO (search engine optimization) because it sends back a 302 temporary redirect to your 404 page which in turn sends back a "200 OK" message. In other words, "Yeehah! No problems here as you've found what you're looking for! Index away!"  &lt;p&gt;So, bright developer that you are, you add in some applicable status code into your 404 page thinking that should take care of it:  &lt;p&gt;protected override void OnLoad(System.EventArgs e)&lt;br&gt;{&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.TrySkipIisCustomErrors = true; // For IIS 7 Integrated Pipeline - see previous post&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.Status = "404 Not Found";&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.StatusCode = 404;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; base.OnLoad(e);&lt;br&gt;} &lt;/p&gt; &lt;p&gt;Well, fire up &lt;a href="http://www.fiddler2.com/fiddler2/"&gt;Fiddler&lt;/a&gt; and you'll discover that you're still getting a 302 temporary redirect to your 404 page. So you fire up your error handling code and for 404s, you Server.Transfer to your 404 page just like all your other error transfers take place! But no, bafflingly enough, even running through a debug session to ensure you're properly catching your 404, ASP.NET still insists on 302'ing your precious response (although at least now your 404 page is sending back the proper "404 Not Found" error status). So go out there and google everywhere and &lt;a href="http://labs.episerver.com/en/Blogs/Svante-Seleborg/Dates/2008/10/When-a-404-Not-Found-should-be-a-404-Not-Found/"&gt;try&lt;/a&gt; &lt;a href="http://helephant.com/2009/02/improving-the-way-aspnet-handles-404-requests/"&gt;every&lt;/a&gt; &lt;a href="http://stackoverflow.com/questions/347281/asp-net-custom-404-returning-200-ok-instead-of-404-not-found"&gt;suggestion&lt;/a&gt; (just a sampling) and then breathe a prayer of thanksgiving for me and my super-duper super hero cape, because this is how you make your way to the 404 handling bliss (caveat: thoroughly tested only on IIS 7):  &lt;p&gt;First, make something like the following in Application_Error in your global.asax (or better yet, a custom error module):&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;protected void Application_Error(Object sender, EventArgs e)&lt;br&gt;{&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Exception exception = Server.GetLastError();&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (exception is HttpUnhandledException)&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (exception.InnerException == null)&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Server.Transfer(ERROR_PAGE_LOCATION, false);&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exception = exception.InnerException;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }  &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (exception is HttpException)&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (((HttpException)exception).GetHttpCode() == 404)&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Log if wished.&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Server.ClearError();&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Server.Transfer(NOT_FOUND_PAGE_LOCATION, false);&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; } &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (Context != null &amp;amp;&amp;amp; Context.IsCustomErrorEnabled)&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Server.Transfer(ERROR_PAGE_LOCATION, false);&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; else&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Log.Error("Unhandled Exception trapped in Global.asax", exception);&lt;br&gt;}&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;Second, put something like the following in your 404 page (or even better, add it to your above custom error module):&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;protected override void OnLoad(System.EventArgs e)&lt;br&gt;{&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.TrySkipIisCustomErrors = true; // For IIS 7 Integrated Pipeline - see previous post&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.Status = "404 Not Found";&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.StatusCode = 404;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; base.OnLoad(e);&lt;br&gt;}&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;And lastly, put whatever you want in your customErrors section in your Web.config for 404 - remove the 404 references if you want. The only time it would get used is if you keep the confusion level down by reading that section in your error module to find out what your 404 page is.  &lt;p&gt;And now, you don't get any nasty 302 redirects. You get a blissfully pure and pretty 404.  &lt;p&gt;Note: you can have everything in place as above, but if you forget to Server.ClearErrror(), it'll all be for naught as you'll still get 302 redirected (thanks to &lt;a title="http://stackoverflow.com/questions/667053/best-way-to-implement-a-404-in-asp-net" href="http://stackoverflow.com/questions/667053/best-way-to-implement-a-404-in-asp-net"&gt;http://stackoverflow.com/questions/667053/best-way-to-implement-a-404-in-asp-net&lt;/a&gt; for finally helping me get this one nailed).  &lt;p&gt;UPDATE: If for some reason you cannot change your code, a good option to pursue is flipping a switch in your applicationHost.config file that passes your response through without IIS hijacking it. This is the sledgehammer approach, but could be applicable for your situation. For example, in order to allow &lt;a href="http://umbraco.org"&gt;Umbraco's&lt;/a&gt; alternative status code responses to work, this is the only way to get them to avoid being hijacked by IIS (i.e. NotFoundHandlers, booting screens, etc.).&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;&amp;lt;location path="&lt;em&gt;Site Description&lt;/em&gt;"&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;system.webServer&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;httpErrors existingResponse="PassThrough" /&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/system.webServer&amp;gt;&lt;br&gt;&amp;lt;/location&amp;gt;&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;Thanks to &lt;a href="http://www.west-wind.com/weblog/posts/745738.aspx#829305"&gt;Fabian Heussser's comment on Rick Strahl's post that helped with this&lt;/a&gt;.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-636297629501512154?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/rAofcM3HtcU" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">3</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/10/handling-404-errors-with-aspnet.aspx</feedburner:origLink></item><item><title>Errors: Sending the Right Message</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/YTXMupaaHyA/errors-sending-right-message.aspx</link><category>asp.net</category><author>noreply@blogger.com (Ted Jardine)</author><pubDate>Tue, 06 Oct 2009 17:18:53 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-3884710281825829726</guid><description>&lt;p&gt;I've encountered many twists and turns in my journey towards handling application errors with aplomb. You have to make sure: &lt;/p&gt; &lt;ol&gt; &lt;li&gt;Users are happy (by providing informative error pages) - well, as happy as they can be under the circumstances.  &lt;li&gt;Developers who need to fix the problem are happy (extensive logging and notification to help re-enact, locate, and then fix the bug so it doesn't happen again).  &lt;li&gt;Search bots are happy (by sending them the right message).&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;For example, when a user requests a resource that can't be found you want to help the user out with at least a pretty page that explains what has happened. Most users don't have a clue what a "404 error" is and could care less. And almost just as important, when a search bot encounters an error it needs to receive a proper error code back or else it gets all uppity on you and knocks down the page's ranking. In other words, when a page can't be found:&lt;/p&gt; &lt;ol&gt; &lt;li&gt;Redirect to a helpful "Sorry, we can't find the resource you're looking for" page that hopefully looks somewhat decent and gives the user some options on how to proceed (perhaps like our "smart" page not found functionality on our soon-to-be-launched &lt;a href="http://www.andornot.com"&gt;www.andornot.com&lt;/a&gt;).&amp;nbsp;&amp;nbsp; &lt;li&gt;Log the 404 so that it can be dealt with (if applicable).  &lt;li&gt;Set the proper 404 error code for SEO purposes. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;However, sometimes getting the three above objectives dealt with in one fell swoop is problematic. For example, if you just redirect after having an error occur (say a "500 Internal Server Error") to a pretty page, users will be happy, but search bots will receive something like the following:  &lt;blockquote&gt; &lt;p&gt;Cache-Control: private&lt;br&gt;Content-Type: text/html; charset=utf-8&lt;br&gt;Content-Encoding: gzip&lt;br&gt;Vary: Accept-Encoding&lt;br&gt;Server: Microsoft-IIS/7.5&lt;br&gt;X-AspNet-Version: 2.0.50727&lt;br&gt;X-Powered-By: ASP.NET&lt;br&gt;Date: Fri, 02 Oct 2009 18:30:47 GMT&lt;br&gt;Content-Length: 7719  &lt;p&gt;200 OK &lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;200 OK for something that really is not okay. It should be "500 Internal Server Error"! Erk. So how about we code in something like:  &lt;blockquote&gt; &lt;p&gt;Response.StatusCode = 500;&lt;br&gt;Response.StatusDescription = "500 Internal Server Error";&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;But then things start to get interesting. In IIS 6 all appears to look good, but when you're using MasterPages, Internet Explorer 6 (in a rare case of actually being helpful) shows that what's being sent back is wacked as it wraps the custom error page with the default IIS error page. Gee, now two out of three of the above objectives are out the window. Suffice it to say, the result is grotesque, and I can't imagine what search bots think of it!  &lt;p&gt;Moving on to IIS 7 and its Integrated Pipeline (doesn't apply to Classic Pipeline mode), things get even more interesting as it ignores your custom stuff altogether and sends back the applicable default IIS error page. What the? &lt;a href="http://www.west-wind.com/weblog/posts/745738.aspx"&gt;Rick Strahl has an excellent post addressing this issue&lt;/a&gt;. Essentially, the error is still trapped by ASP.NET (so it's logged, redirected, and whatever else you ask it to do), but then it is ultimately handled by IIS which sees the error code and hijacks the entire response and returns its ugly default error page (and who designed those anyway? Even IIS 6's were better).  &lt;p&gt;So where do we go from here? In IIS 6, the problem only occurs when using MasterPages in your error page. Over simplifying, the page's MasterPage renders later on in the page lifecycle and resets the error code to 200 OK. And it just gets messier from there (see &lt;a href="http://stackoverflow.com/questions/347281/asp-net-custom-404-returning-200-ok-instead-of-404-not-found"&gt;http://stackoverflow.com/questions/347281/asp-net-custom-404-returning-200-ok-instead-of-404-not-found&lt;/a&gt; for more info). So reset it back again further along in the page's lifecycle!  &lt;blockquote&gt; &lt;p&gt;protected override void Render(HtmlTextWriter writer)&lt;br&gt;{&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; base.Render(writer);&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.StatusCode = 500;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.StatusDescription = "500 Internal Server Error";&lt;br&gt;} &lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;But what about IIS 7? If you look further along in Rick Strahl's post mentioned above, there's a new flag in ASP.NET 3.5 called &lt;em&gt;Response.TrySkipIisCustomErrors&lt;/em&gt;. As Rick says, "In a nutshell this property when set to true at any point in the request prevents IIS from injecting its custom error pages. This flag is new in ASP.NET 3.5 - so if you're running 2.0 only you're out of luck."  &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.TrySkipIisCustomErrors = true;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.StatusCode = 500;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.StatusDescription = "500 Internal Server Error";  &lt;p&gt;And Shazam!  &lt;blockquote&gt; &lt;p&gt;HTTP/1.1 500 500 Internal Server Error&lt;br&gt;Cache-Control: private&lt;br&gt;Content-Type: text/html; charset=utf-8&lt;br&gt;Server: Microsoft-IIS/7.0&lt;br&gt;X-AspNet-Version: 2.0.50727&lt;br&gt;X-Powered-By: ASP.NET&lt;br&gt;Date: Fri, 02 Oct 2009 20:02:48 GMT&lt;br&gt;Content-Length: 6879 &lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;Error handled and logged, developers notified, user somewhat mollified, and Google/Bing happy. How's that for making the best of a bad situation?  &lt;p&gt;For more information, see some of the following:  &lt;ul&gt; &lt;li&gt;&lt;a href="http://stackoverflow.com/questions/434272/iis7-overrides-customerrors-when-setting-response-statuscode"&gt;http://stackoverflow.com/questions/434272/iis7-overrides-customerrors-when-setting-response-statuscode&lt;/a&gt;  &lt;li&gt;&lt;a href="http://forums.iis.net/t/1146653.aspx"&gt;http://forums.iis.net/t/1146653.aspx&lt;/a&gt;  &lt;li&gt;&lt;a href="http://learn.iis.net/page.aspx/267/how-to-use-http-detailed-errors-in-iis7/"&gt;http://learn.iis.net/page.aspx/267/how-to-use-http-detailed-errors-in-iis7/&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;Of course, there's a ton of caveats in the above. However, one that is definitely worth addressing is how 404 handling is extra-special-different in ASP.NET. Very extra-special-different. And badly very different. But we'll save that for the next post.&lt;/p&gt; &lt;p&gt;UPDATE: If for some reason you cannot change your code, a good option to pursue is flipping a switch in your applicationHost.config file that passes your response through without IIS hijacking it. This is the sledgehammer approach, but could be applicable for your situation. For example, in order to allow &lt;a href="http://umbraco.org"&gt;Umbraco's&lt;/a&gt; alternative status code responses to work, this is the only way to get them to avoid being hijacked by IIS (i.e. NotFoundHandlers, booting screens, etc.).&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;&amp;lt;location path="&lt;em&gt;Site Description&lt;/em&gt;"&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;system.webServer&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;httpErrors existingResponse="PassThrough" /&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/system.webServer&amp;gt;&lt;br&gt;&amp;lt;/location&amp;gt;&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;Thanks to &lt;a href="http://www.west-wind.com/weblog/posts/745738.aspx#829305"&gt;Fabian Heussser's comment on Rick Strahl's post that helped with this&lt;/a&gt;.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-3884710281825829726?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/YTXMupaaHyA" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/10/errors-sending-right-message.aspx</feedburner:origLink></item><item><title>Single Search Boxes and the Submit Button</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/OMuT9B97vBQ/single-search-boxes-and-submit-button.aspx</link><category>ASP.NET AJAX</category><category>asp.net</category><author>noreply@blogger.com (Jonathan Jacobsen)</author><pubDate>Thu, 10 Sep 2009 08:32:07 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-7440978844529243873</guid><description>&lt;p&gt;&lt;/p&gt; &lt;p&gt;On a search form with only one search term box and one submit button, such as the &lt;a href="http://ask.andornot.com/Default.aspx" target="_blank"&gt;Quick Search form&lt;/a&gt; in the Andornot Starter Kit, the usual user behaviour is to type search terms and press the Enter key. However, there is a longstanding issue with ASP .NET that results in seemingly nothing happening in this case, in some browsers. The form does a weird empty postback because it submits the form, but does not call your ASP.NET submit button's click event: i.e., it does a postback, but does not do anything. The user must instead use the mouse to click the Submit button.  &lt;p&gt;A simple workaround for this is to add a second search box to the form, but make it invisible. For example, add:  &lt;p&gt;&amp;lt;input type="text" style="display:none;" /&amp;gt;  &lt;p&gt;Now when the user presses the enter key, the subsequent postback operates as expected (i.e. in the case of the Andornot Starter Kit Quick Search form, it submits the search instead of just doing an "empty" postback that doesn't do anything).  &lt;p&gt;More information on this ASP.NET behaviour is &lt;a href="http://www.west-wind.com/Weblog/posts/1225.aspx" target="_blank"&gt;available here&lt;/a&gt;. Information on similar behaviour in AJAX Update Panels is in &lt;a href="http://www.andornot.com/about/developerblog/2007/09/fix-firefox-defaultbutton-issue-with.aspx" target="_blank"&gt;an earlier Andornot developer blog post&lt;/a&gt;.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-7440978844529243873?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/OMuT9B97vBQ" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/09/single-search-boxes-and-submit-button.aspx</feedburner:origLink></item><item><title>WebPublisher PRO Errors</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/g22RF88Z-3s/webpublisher-pro-errors.aspx</link><category>inmagic</category><category>WebPublisher Pro</category><author>noreply@blogger.com (Denise Bonin)</author><pubDate>Tue, 08 Sep 2009 18:22:36 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-2413613971592013568</guid><description>Recently we have had several clients contact us about various WebPublisher PRO error messages.  The two main ones are as follows (please note the &lt;span style="font-weight: bold;"&gt;bolded&lt;/span&gt; words):

&lt;p&gt;&lt;span style="font-style: italic;"&gt;DB/Text or CS/WebPublisher: Operation failed for unknown reason while processing 'begin finding &lt;span style="font-weight: bold;"&gt;RootURL&lt;/span&gt; ProcessInput', after line ####. Please inform Inmagic, Inc.&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;span style="font-style: italic;"&gt;DB/Text or CS/WebPublisher PRO: Operation failed for unknown reason while processing '&lt;span style="font-weight: bold;"&gt;open textbase&lt;/span&gt; [doOpenTextbase]', after line ####. Please inform Inmagic, Inc.&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;We believe that the cause is a recent Microsoft server update interfering with some WebPublisher PRO functions.  There are some easy fixes to both the errors:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;RootURL&lt;/span&gt;  &lt;/li&gt;

We have determined that the problem is with the BU line in the search code where the BU line is set to a short form, for example in a search page:

&lt;p&gt;&lt;span style="font-weight:bold;"&gt;&amp;lt;input type="hidden" id="BU" name="BU" value="default.aspx" /&amp;gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;Luckily the fix is easy.  Just replace the short form of the BU line with the full URL, for example:&lt;/p&gt;

&lt;p&gt;&lt;span style="font-weight:bold;"&gt;&amp;lt;input type="hidden" id="BU" name="BU" value="http://WebsiteName/default.aspx" /&amp;gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;This is also true in canned queries, for example: BU=&lt;span style="font-weight:bold;"&gt;/default.aspx&lt;/span&gt; should be BU=&lt;span style="font-weight:bold;"&gt;http://WebsiteName/default.aspx&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;What is the BU line for?  From &lt;a href="http://support.inmagic.com/supbase3.htm"&gt;Inmagic Knowledgebase&lt;/a&gt; article # 2104:&lt;/p&gt;

&lt;p&gt;&lt;span style="font-weight:bold;"&gt;"BU" &lt;/span&gt;is the location of the link that submitted the search. It is required for a canned query if you would like to use expand record jump or change the report after the results of the canned query are returned. &lt;/ul&gt;&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Open textbase&lt;/span&gt;  &lt;/li&gt;

This error can be resolved by restarting IIS.&lt;/ul&gt;

Please contact &lt;a href="mailto:support@andornot.com"&gt;Andornot&lt;/a&gt; or &lt;a href="mailto:support@inmagic.com"&gt;Inmagic Support&lt;/a&gt; if you have been experiencing either of these error messages.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-2413613971592013568?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/g22RF88Z-3s" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">1</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/09/webpublisher-pro-errors.aspx</feedburner:origLink></item><item><title>Highlight search terms with jQuery</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/eWUAZ8j8piA/highlight-search-terms-with-jquery.aspx</link><author>noreply@blogger.com (Peter Tyrrell)</author><pubDate>Thu, 03 Sep 2009 12:07:24 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-8374265045220023056</guid><description>&lt;p&gt;&lt;strong&gt;Overview&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Highlight words and phrases within specified elements on the page. Search syntax is trimmed or eradicated, stopwords and words less than 3 characters&amp;nbsp; are ignored.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Ingredients&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;You will need:&lt;/p&gt; &lt;ul&gt; &lt;li&gt;&lt;font color="#3f3f3f"&gt;&lt;a href="http://jquery.com"&gt;jquery 1.3.2&lt;/a&gt;&lt;/font&gt;  &lt;li&gt;&lt;font color="#3f3f3f"&gt;&lt;a href="http://plugins.jquery.com/project/query-object"&gt;jquery Query Object plugin&lt;/a&gt;&lt;/font&gt;  &lt;li&gt;&lt;font color="#3f3f3f"&gt;highlighting methods below&lt;/font&gt;&lt;/li&gt;&lt;/ul&gt; &lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt; &lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum1"&gt;   1:&lt;/span&gt;&amp;nbsp; &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum2"&gt;   2:&lt;/span&gt; &lt;span style="color: #008000"&gt;/*&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum3"&gt;   3:&lt;/span&gt; &lt;span style="color: #008000"&gt;    methods to help highlight search words and terms &lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum4"&gt;   4:&lt;/span&gt; &lt;span style="color: #008000"&gt;    depends on jquery&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum5"&gt;   5:&lt;/span&gt; &lt;span style="color: #008000"&gt;    Peter Tyrrell, August 2009&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum6"&gt;   6:&lt;/span&gt; &lt;span style="color: #008000"&gt;*/&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum7"&gt;   7:&lt;/span&gt;&amp;nbsp; &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum8"&gt;   8:&lt;/span&gt; &lt;span style="color: #008000"&gt;// &lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum9"&gt;   9:&lt;/span&gt; &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; highlightTermsIn = &lt;span style="color: #0000ff"&gt;function&lt;/span&gt;(jQueryElements, terms) {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum10"&gt;  10:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; wrapper = &lt;span style="color: #006080"&gt;"&amp;gt;$1&amp;lt;b style='font-weight:normal;color:#000;background-color:rgb(255,255,102)'&amp;gt;$2&amp;lt;/b&amp;gt;$3&amp;lt;"&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum11"&gt;  11:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;for&lt;/span&gt; (&lt;span style="color: #0000ff"&gt;var&lt;/span&gt; i = 0; i &amp;lt; terms.length; i++) {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum12"&gt;  12:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; regex = &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; RegExp(&lt;span style="color: #006080"&gt;"&amp;gt;([^&amp;lt;]*)?("&lt;/span&gt;+terms[i]+&lt;span style="color: #006080"&gt;")([^&amp;gt;]*)?&amp;lt;"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"ig"&lt;/span&gt;);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum13"&gt;  13:&lt;/span&gt;         jQueryElements.each(&lt;span style="color: #0000ff"&gt;function&lt;/span&gt;(i) {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum14"&gt;  14:&lt;/span&gt;             $(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;).html($(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;).html().replace(regex, wrapper));&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum15"&gt;  15:&lt;/span&gt;         }); &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum16"&gt;  16:&lt;/span&gt;     };&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum17"&gt;  17:&lt;/span&gt; }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum18"&gt;  18:&lt;/span&gt;&amp;nbsp; &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum19"&gt;  19:&lt;/span&gt; &lt;span style="color: #008000"&gt;// returns array of unique search terms (words, phrases) found in value        &lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum20"&gt;  20:&lt;/span&gt; &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; parseSearchTerms = &lt;span style="color: #0000ff"&gt;function&lt;/span&gt;(value) {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum21"&gt;  21:&lt;/span&gt;     &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum22"&gt;  22:&lt;/span&gt;     &lt;span style="color: #008000"&gt;// split string on spaces and respect double quoted phrases&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum23"&gt;  23:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; splitRegex = /(\u0022[^\u0022]*\u0022)|([^\u0022\s]+(\s|$))/g;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum24"&gt;  24:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; rawTerms = value.match(splitRegex);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum25"&gt;  25:&lt;/span&gt;     &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum26"&gt;  26:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; terms = [];            &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum27"&gt;  27:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;for&lt;/span&gt; (&lt;span style="color: #0000ff"&gt;var&lt;/span&gt; i = 0; i &amp;lt; rawTerms.length; i++) {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum28"&gt;  28:&lt;/span&gt;         &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum29"&gt;  29:&lt;/span&gt;         &lt;span style="color: #008000"&gt;// trim whitespace, quotes, apostrophes and query syntax special chars&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum30"&gt;  30:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; term = rawTerms[i].replace(/^[\s\u0022\u0027+-][\s\u0022\u0027+-]*/, &lt;span style="color: #006080"&gt;''&lt;/span&gt;).replace(/[\s*~\u0022\u0027][\s*~\u0022\u0027]*$/, &lt;span style="color: #006080"&gt;''&lt;/span&gt;).toLowerCase();&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum31"&gt;  31:&lt;/span&gt;         &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum32"&gt;  32:&lt;/span&gt;         &lt;span style="color: #008000"&gt;// ignore if &amp;lt;= 2 chars&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum33"&gt;  33:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;if&lt;/span&gt; (term.length &amp;lt;= 2) {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum34"&gt;  34:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;continue&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum35"&gt;  35:&lt;/span&gt;         }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum36"&gt;  36:&lt;/span&gt;         &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum37"&gt;  37:&lt;/span&gt;         &lt;span style="color: #008000"&gt;// ignore stopwords&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum38"&gt;  38:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; stopwords = [&lt;span style="color: #006080"&gt;"about"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"are"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"from"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"how"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"that"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"the"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"this"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"was"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"what"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"when"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"where"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"who"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"will"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"with"&lt;/span&gt;,&lt;span style="color: #006080"&gt;"the"&lt;/span&gt;];&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum39"&gt;  39:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; isStopword = &lt;span style="color: #0000ff"&gt;false&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum40"&gt;  40:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;for&lt;/span&gt; (&lt;span style="color: #0000ff"&gt;var&lt;/span&gt; j = 0; j &amp;lt; stopwords.length; j++) {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum41"&gt;  41:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;if&lt;/span&gt; (term == stopwords[j]) {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum42"&gt;  42:&lt;/span&gt;                 isStopword = &lt;span style="color: #0000ff"&gt;true&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum43"&gt;  43:&lt;/span&gt;                 &lt;span style="color: #0000ff"&gt;break&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum44"&gt;  44:&lt;/span&gt;             }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum45"&gt;  45:&lt;/span&gt;         }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum46"&gt;  46:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;if&lt;/span&gt; (isStopword === &lt;span style="color: #0000ff"&gt;true&lt;/span&gt;) {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum47"&gt;  47:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;continue&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum48"&gt;  48:&lt;/span&gt;         }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum49"&gt;  49:&lt;/span&gt;         &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum50"&gt;  50:&lt;/span&gt;         &lt;span style="color: #008000"&gt;// add term to term list&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum51"&gt;  51:&lt;/span&gt;         terms[terms.length] = term;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum52"&gt;  52:&lt;/span&gt;     }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum53"&gt;  53:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;return&lt;/span&gt; terms;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum54"&gt;  54:&lt;/span&gt; }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&lt;strong&gt;Example 1&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Pass an array of terms to be highlighted in jquery-selected elements:&lt;/p&gt;
&lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt;
&lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum1"&gt;   1:&lt;/span&gt; &amp;lt;script type=&lt;span style="color: #006080"&gt;"text/javascript"&lt;/span&gt;&amp;gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum2"&gt;   2:&lt;/span&gt;     $(document).ready(&lt;span style="color: #0000ff"&gt;function&lt;/span&gt;() {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum3"&gt;   3:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; searchTerms = [&lt;span style="color: #006080"&gt;"banana"&lt;/span&gt;, &lt;span style="color: #006080"&gt;"monkey"&lt;/span&gt;];&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum4"&gt;   4:&lt;/span&gt;         &lt;span style="color: #008000"&gt;// highlight valid terms in search results          &lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum5"&gt;   5:&lt;/span&gt;         highlightTermsIn($(&lt;span style="color: #006080"&gt;"#HighlightWrapper"&lt;/span&gt;), searchTerms);        &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum6"&gt;   6:&lt;/span&gt;     });&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum7"&gt;   7:&lt;/span&gt; &amp;lt;/script&amp;gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&lt;strong&gt;Example 2&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Parse raw search input to strip out stopwords, query syntax characters, and wee short words less than 3 characters that do nobody any good. Quoted phrases are treated as a single term.&lt;/p&gt;
&lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt;
&lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum1"&gt;   1:&lt;/span&gt; &amp;lt;script type=&lt;span style="color: #006080"&gt;"text/javascript"&lt;/span&gt;&amp;gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum2"&gt;   2:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; rawSearch = &lt;span style="color: #006080"&gt;"give the banana* to a monkey"&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum3"&gt;   3:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; termsToHighlight = parseSearchTerms(rawSearch);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum4"&gt;   4:&lt;/span&gt;     &lt;span style="color: #008000"&gt;// termsToHighlight now = ["give", "banana", "monkey"]&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum5"&gt;   5:&lt;/span&gt; &amp;lt;/script&amp;gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&lt;strong&gt;Example 3&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Put it all together to retrieve raw search input from the query string, parse out terms to highlight, and highlight within specified containers.&lt;/p&gt;
&lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt;
&lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum1"&gt;   1:&lt;/span&gt; &amp;lt;script type=&lt;span style="color: #006080"&gt;"text/javascript"&lt;/span&gt;&amp;gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum2"&gt;   2:&lt;/span&gt;     $(document).ready(&lt;span style="color: #0000ff"&gt;function&lt;/span&gt;() {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum3"&gt;   3:&lt;/span&gt;         &lt;span style="color: #008000"&gt;// get quick search value from query string&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum4"&gt;   4:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;var&lt;/span&gt; quickSearch = $.query.get(&lt;span style="color: #006080"&gt;"q"&lt;/span&gt;);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum5"&gt;   5:&lt;/span&gt;         &lt;span style="color: #008000"&gt;// highlight valid terms in divs marked class="HighlightWrapper"        &lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum6"&gt;   6:&lt;/span&gt;         highlightTermsIn($(&lt;span style="color: #006080"&gt;"div.HighlightWrapper"&lt;/span&gt;), parseSearchTerms(quickSearch));&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum7"&gt;   7:&lt;/span&gt;     });     &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum8"&gt;   8:&lt;/span&gt; &amp;lt;/script&amp;gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&lt;strong&gt;Acknowledgements&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Original concept: &lt;a title="http://eriwen.com/javascript/highlight-search-results-with-js/" href="http://eriwen.com/javascript/highlight-search-results-with-js/"&gt;http://eriwen.com/javascript/highlight-search-results-with-js/&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Use of &amp;lt;b&amp;gt; tags with inline style as highlight wrappers: Google cache pages.&lt;/li&gt;
&lt;li&gt;List of English stopwords: &lt;a title="http://www.ranks.nl/resources/stopwords.html" href="http://www.ranks.nl/resources/stopwords.html"&gt;http://www.ranks.nl/resources/stopwords.html&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;First use: ARC-BC (Accessible Resource Centre British Columbia), &lt;a href="http://www.arc-bc.org"&gt;http://www.arc-bc.org&lt;/a&gt;.&lt;/li&gt;&lt;/ul&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-8374265045220023056?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/eWUAZ8j8piA" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">1</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/09/highlight-search-terms-with-jquery.aspx</feedburner:origLink></item><item><title>Syncing Active Directory with Borrowers and GenieKey</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/SLD2m2Qoimo/syncing-active-directory-with-borrowers.aspx</link><category>Inmagic Genie</category><author>noreply@blogger.com (Jonathan Jacobsen)</author><pubDate>Fri, 28 Aug 2009 12:14:15 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-8297078759174640787</guid><description>&lt;p&gt;In a project we worked on over the summer, we needed a way to sync staff information in an Active Directory database with the Inmagic Genie borrower and user login records. Single sign on had been enabled so that staff can access their MyGenie interface to see an up to date list of their loans, orders and reserves without having to manually login. Since borrower and user information is stored in 2 separate textbases (Borrowers and GenieKey), we knew there would be several steps involved in moving and synchronizing this information. The organization has ~1,200 employees, who move departments, change names, and come and go, so it was clear that an automated sync process would save time and effort, compared to library staff manually updating Genie.  &lt;p&gt;We concluded that the Inmagic PowerPack Importer was ideal for automatically importing data into the Borrowers and GenieKey textbases, but that an additional tool would need to be developed for automatically extracting data from Borrowers and Active Directory. The client developed the AD export, and from Andornot came... &lt;b&gt;Extract-o-matic&lt;/b&gt;!  &lt;p&gt;Extract-o-matic is a small, command-line application, written in C#, that uses an ODBC connection to a textbase and writes output to a text file. It accepts as input the textbase name and ODBC DSN connection, the names of fields to be extracted, a query string to select records, and information about the desired output format. Output is a single line per record extracted, so a comma-separated or tab-separated format works well (but XML could be generated as well).  &lt;p&gt;The complete data migration process in this project is:  &lt;ul&gt; &lt;li&gt;An Active Directory CSV export file is generated and placed in a folder watched by the Importer.  &lt;li&gt;The AD data is imported into the Genie Borrowers textbase by the Importer, updating existing records and creating new ones.  &lt;li&gt;A scheduled task runs a batch file to direct Extract-o-matic to select all Borrower records except those of library staff and system administrators and writes these records to a text file in a different folder also watched by the Importer.  &lt;li&gt;The Borrower export is imported into the GenieKey textbase by the Importer to update all regular staff user records (library staff and admins with higher Genie privileges are not updated).  &lt;li&gt;Exception logs are monitored and any issues handled.  &lt;li&gt;A separate, manual process is followed to handle staff who leave the organization.&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;This automated synchronization of an Active Directory staff database to Genie Borrowers and users works well, freeing employees and library staff for other work. We expect to find other uses for Extract-o-matic in the future. Let us know if you think of any and we'll get you set up!  &lt;p&gt;Please &lt;a href="mailto:info@andornot.com"&gt;contact us&lt;/a&gt; for more information on this process or on the Inmagic Library Suite.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-8297078759174640787?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/SLD2m2Qoimo" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/08/syncing-active-directory-with-borrowers.aspx</feedburner:origLink></item><item><title>Windows 7: blissfully tabbing to complete path in Explorer</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/PEVqqlcnCm4/windows-7-blissfully-tabbing-to.aspx</link><category>windows7</category><category>tips</category><author>noreply@blogger.com (Ted Jardine)</author><pubDate>Tue, 25 Aug 2009 12:06:06 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-2936530575404387449</guid><description>&lt;p&gt;This'll be a short post, but there are many things I love about Windows 7, and many things I really like, but I've just discovered something that you might not have heard about yet: in Windows Explorer, you can now tab to complete the path in the address bar. For example, in the path below, I can type "Of" and then hit tab and it will automatically complete "Office" followed by the next backward slash, ready for me to continue on down the path.&lt;/p&gt; &lt;p&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.andornot.com/about/developerblog/uploaded_images/tabbing-775978.png"&gt;&lt;img style="margin: 0px 0px 10px; width: 320px; display: inline; height: 65px; cursor: pointer" alt="" src="http://www.andornot.com/about/developerblog/uploaded_images/tabbing-775975.png"&gt;&lt;/a&gt; &lt;/p&gt; &lt;p&gt;This might not seem like a big deal, but see how much time it saves navigating to "C:\Windows\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files". And yes, that's if you haven't already set up &lt;a href="http://www.executor.dk/"&gt;Executor&lt;/a&gt;/&lt;a href="http://www.launchy.net/"&gt;Launchy&lt;/a&gt;/&lt;a href="http://humanized.com/"&gt;Enso&lt;/a&gt; (note: does not work on x64)/Etc. to have a shortcut already to that particular location. However, it's even better than those launchy applications in that it's a) in Explorer already, b) it allows you to sometimes tab, sometimes type, sometimes arrow down to a selection, and c) hitting enter opens the current directory, but then you can go right back up with alt-d to the address bar and continue on again. If you use any of the above launchy-type applications, you'll know what I'm talking about. If you're not yet using one of them, hello?!? (and yes, while the new-in-Vista start button is an improvement, it's still not near as feature complete).&lt;/p&gt; &lt;p&gt;Another handy thing that I needed a third party app for before is the now-native "Copy as path" option for files (although you need to shift-f10 to open menu, or shift-left click to get it to show):&lt;/p&gt; &lt;p&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.andornot.com/about/developerblog/uploaded_images/Copy-as-path-731961.png"&gt;&lt;img style="width: 320px; display: inline; height: 311px; margin-left: 0px; cursor: pointer; margin-right: 0px" alt="" align="left" src="http://www.andornot.com/about/developerblog/uploaded_images/Copy-as-path-731958.png"&gt;&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-2936530575404387449?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/PEVqqlcnCm4" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">1</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/08/windows-7-blissfully-tabbing-to.aspx</feedburner:origLink></item><item><title>Genie Overdue Notices and Serials Routing Notices</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/QMEX-0eGYSc/genie-overdue-notices-and-serials.aspx</link><category>Inmagic Genie</category><author>noreply@blogger.com (Jonathan Jacobsen)</author><pubDate>Tue, 18 Aug 2009 08:02:09 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-6404124264094221010</guid><description>&lt;p&gt;&lt;a href="http://www.andornot.com/Products/Inmagic/Genie/Default.aspx"&gt;Genie&lt;/a&gt; (part of the Inmagic Library Suite) includes several different notices regarding loan overdues and serials routing.&amp;nbsp; If you need to make a change to the content of these notices, the following guide will help you see where to make those changes, as well as when different notices are used. All of the notices listed below reflect Genie version 3.3).  &lt;h3&gt;Overdue Notices - Email&lt;/h3&gt; &lt;p&gt;There are 3 overdue notice emails:&lt;/p&gt; &lt;ol&gt; &lt;li&gt;In MyReports.config as EmailLoanOverdue. Used to send multiple emails at once, from the "E-mail overdue notices" link at the bottom of the Loans search results, when the "E-mail/Print Overdue Notices" report is selected in the drop-down list of reports.  &lt;li&gt;An HTML page in \Program Files\Inmagic\Genie called OverdueEmailTemplate.htm. Sent from the "Send overdue e-mail notice" link at the bottom of the Loans edit screen.  &lt;li&gt;An HTML page in \Program Files\Inmagic\Genie called StatsOverdueEmail_0.htm. Sent from the Email link on the Statistics page. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;There is also an HTML page in \Program Files\Inmagic\Genie called OverdueEmailBatch.htm, but this is no longer used; it has been replaced by EmailLoanOverdue in MyReports.config.&lt;br&gt;&lt;/p&gt; &lt;h3&gt;Overdue Notices - Print&lt;/h3&gt; &lt;p&gt;There is 1 printable overdue loan notice:&lt;/p&gt; &lt;ol&gt; &lt;li&gt;In MyReports.config is LoanOverdueNotice, used when batch printing multiple notices. Used by Print link at the top and bottom of the Loans search results when the "E-mail/Print Overdue Notices" report is selected in the drop-down list of reports, and by the Print links on the Statistics page. By default, this report is commented out from the list of reports at the bottom of MyReports.config and so does not appear in the drop-down list of reports in the Loans search results.&amp;nbsp; &lt;/li&gt;&lt;/ol&gt; &lt;h3&gt;Serials Routing Notices - Email&lt;/h3&gt; &lt;p&gt;There are 3 serials routing emails:&lt;/p&gt; &lt;ol&gt; &lt;li&gt;In MyReports.config as EmailSerialsRoute. Used when you send multiple email routing notices at once, from the Serials "Email Routing Notices" report.  &lt;li&gt;An HTML page in \Program Files\Inmagic\Genie called "RouteEmailTemplate.htm". Used when you email the notice for just 1 serial, from the serial edit screen.  &lt;li&gt;An HTML page in \Program Files\Inmagic\Genie called "StatsRouteEmail_0.htm". Used by the&amp;nbsp; Email link on&amp;nbsp; the Statistics page. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;Additional Notes on Routing Emails:&lt;/p&gt; &lt;ul&gt; &lt;li&gt;When an issue has just been checked in, and a PDF of the Table of Contents uploaded, if a user then clicks the Send Email Routing notice link on the serials edit screen, the pop-up window that appears contains 2 additional checkboxes for linking to and attaching the PDF in the email.&amp;nbsp;&amp;nbsp; These checkboxes do not appear if there is no PDF associated with the serial issue open in the serials edit screen.  &lt;li&gt;By default, in RouteEmailTemplate.htm, the parameter TOCImageLink appears, but it appears outside of a pair of &amp;lt; p &amp;gt; tags and should be moved. TOCImageLink is used to include a link to the latest Table of Contents uploaded for this serial.  &lt;li&gt;EmailSerialsRoute in MyReports.config shows the issue checked in from the SerDateToRoute field, whereas the other 2 reports do not; they show only the title. A user would have to type the issue date/vol into the Comments field in the pop-up window, as the comments are included in the RouteEmailTemplate.htm file (but not the StatsRouteEmail_0.htm file).&lt;br&gt;&lt;/li&gt;&lt;/ul&gt; &lt;h2&gt;&lt;/h2&gt; &lt;h3&gt;Serials Routing Notices - Print&lt;/h3&gt; &lt;p&gt;There are 3 printable serial routing notices:&lt;/p&gt; &lt;ol&gt; &lt;li&gt;In \Program Files\Inmagic\Genie is the file route_print.aspx which is called when clicking the Print Routing Notice link on the serials edit screen. It pulls content from the node called BodyText_EmailRouting in the GlobalResource.resx file in \Program Files\Inmagic\Genie\App_GlobalResources.  &lt;li&gt;In MyReports.config is Route1on8.5x11, used when batch printing multiple routing notices, 1 per page, and by the Print link on the Statistics page.  &lt;li&gt;In MyLabels.config is LabelRoute3on8.5x11, used for printing routing notices on labels. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;Note: the two reports in MyReports.config must be listed in the list of Serials reports at the bottom of MyReports.config to appear in the drop down list of serials reports in Genie.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-6404124264094221010?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/QMEX-0eGYSc" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/08/genie-overdue-notices-and-serials.aspx</feedburner:origLink></item><item><title>Using XML and XSL to transform and import records</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/uyPBXnU-iAM/using-xml-and-xsl-to-transform-and.aspx</link><category>MARC</category><category>Inmagic Genie</category><category>xsl</category><category>xslt</category><author>noreply@blogger.com (Jonathan Jacobsen)</author><pubDate>Wed, 29 Jul 2009 18:53:59 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-5901058532948499457</guid><description>&lt;p&gt;Why enter records into your database when you can have someone else do it for you? Or at least, why not borrow records from other sources and import them into your database? It’s quite easy to do, saving time and improving accuracy. One approach to this is: &lt;/p&gt; &lt;ol&gt; &lt;li&gt;Use a service such as &lt;a href="http://www.webclarity.info/products/bookwhere/index.html"&gt;Bookwhere&lt;/a&gt;, &lt;a href="http://biblios.net"&gt;Biblios.net&lt;/a&gt; or &lt;a href="http://www.ncbi.nlm.nih.gov/pubmed/"&gt;PubMed&lt;/a&gt; to search for records in numerous online databases, for materials such as books, journals, articles, videos, maps &amp;shy;- anything that might have been catalogued by someone somewhere may be found (see our &lt;a href="http://www.andornot.com/about/developerblog/2009/02/importing-bibliosnet-records-into.aspx"&gt;blog post on Biblios.net&lt;/a&gt;).  &lt;li&gt;Save records in MARC XML format (though any XML format can be used).  &lt;li&gt;In Genie (part of the Inmagic Library Suite), use the included Bookwhere XSLT to convert selected MARC tags to Genie fields and import records. (&lt;a href="http://en.wikipedia.org/wiki/Xslt"&gt;XSLT&lt;/a&gt; is short for Extensible Stylesheet Language Transformation, and is a language used to transform XML data into other formats).  &lt;li&gt;In Inmagic DB/Text, customize an XSLT to map MARC XML or any other XML data source to your data structure and import records.  &lt;li&gt;After importing records, you would of course further customize them to suit your database. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;If you use Genie, it includes an XSLT (Bookwhere.xsl in the Genie ImporterFiles folder) that maps MARC XML fields into Genie fields. You can customize this XSLT further for your cataloging needs. For example, some MARC tag to Genie field mappings we have added include:  &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;table border="1" cellspacing="0" cellpadding="2" width="400"&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td valign="top" width="196"&gt;&lt;strong&gt;MARC Tags&lt;/strong&gt;&lt;/td&gt; &lt;td valign="top" width="202"&gt;&lt;strong&gt;Genie Field&lt;/strong&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="195"&gt;090 or 050&lt;/td&gt; &lt;td valign="top" width="203"&gt;CatCallNumber&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="194"&gt;520&lt;/td&gt; &lt;td valign="top" width="204"&gt;CatAbstract&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="194"&gt; &lt;p&gt;856 subfield u&lt;/p&gt;&lt;/td&gt; &lt;td valign="top" width="204"&gt;CatURL&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="194"&gt; &lt;p&gt;856 subfield y&lt;/p&gt;&lt;/td&gt; &lt;td valign="top" width="204"&gt;CarURLNotes&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="194"&gt; &lt;p&gt;246, 247, 730, 740, 770, 772, 776, 780, 785, 787&lt;/p&gt;&lt;/td&gt; &lt;td valign="top" width="204"&gt;CatAlternateTitle&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="194"&gt; &lt;p&gt;Leader position 6 or 7&lt;/p&gt;&lt;/td&gt; &lt;td valign="top" width="205"&gt;CatRecordType&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;p&gt;Here's an example of the above Leader mapping added to the Genie Bookwhere.xsl transformation:  &lt;blockquote&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;&amp;lt;xsl:template name="RecordType2" match="marc:leader"&amp;gt; &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;&amp;lt;xsl:choose&amp;gt; &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;&amp;lt;xsl:when test="substring(marc:leader, 8, 1 )='s'"&amp;gt; &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;'CatRecordType' Periodical &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;&amp;lt;/xsl:when&amp;gt; &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;&amp;lt;xsl:when test="substring(marc:leader, 7, 1 )='a'"&amp;gt; &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;'CatRecordType' Book &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;&amp;lt;/xsl:when&amp;gt; &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;&amp;lt;xsl:when test="substring(marc:leader, 7, 1 )='g'"&amp;gt; &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;'CatRecordType' Videorecording &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;&amp;lt;/xsl:when&amp;gt; &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;&amp;lt;/xsl:choose&amp;gt; &lt;/font&gt; &lt;p&gt;&lt;font size="2" face="cou"&gt;&amp;lt;/xsl:template&amp;gt; &lt;/font&gt;&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;Virtually any XML file can be imported into a textbase using an XSL. The beauty of XSLT is that data cleanup can be done as part of the process. For example, ALL CAPS can be converted to Title case, fields can be separated or joined, dates can be transformed to other formats, and much more.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-5901058532948499457?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/uyPBXnU-iAM" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/07/using-xml-and-xsl-to-transform-and.aspx</feedburner:origLink></item><item><title>Andornot Starter Kit revamp with Google Book Covers</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/D3emnnHcXFY/andornot-starter-kit-revamp-with-google.aspx</link><category>ASK</category><category>TextWorks</category><category>Google Books</category><category>WebPublisher Pro</category><author>noreply@blogger.com (Denise Bonin)</author><pubDate>Tue, 07 Jul 2009 23:39:51 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-5385696734075516490</guid><description>We've been doing renovations - raising the roof, adding re-bar to the foundations and while we are at it, we added a sundeck.  What has this got to do with databases you ask?  Well - at least in a metaphorical way - we think it does.  One of Andornot's strengths is our ability to integrate a database into a website.  To continue to do that - which by the way, we think is essential - we had to change a few areas of our base add-on product called ASK.
&lt;p&gt;&lt;span style="font-weight: bold;"&gt;A bit of history
&lt;/span&gt;&lt;/p&gt;ASK - short for Andornot Starter Kit - started off as a desktop add-on for Inmagic DB/TextWorks, with a nice looking search page, a few well designed search results reports, a full display form and a fully functional data entry form for a typical catalogue database.  This was mostly to help us quickly get a client's database up and running quickly and beautifully.  I mean why keep re-inventing the wheel?   We added a menu screen and navigational script buttons to each query screen and form to ease repetitive tasks.  We eventually added a web search screen and a few web forms to work with Inmagic WebPublisher Pro.  In due course we thought that we should have all of this on our website so we could showcase many of the bells and whistles that we have developed over the years.  We set-up &lt;a href="http://ask.andornot.com/"&gt;http://ask.andornot.com&lt;/a&gt; using the "include" file method that was added as of Inmagic WebPublisher version 8 with lots to show off.
&lt;p&gt;&lt;span style="font-weight: bold;"&gt;And so it grows
&lt;/span&gt;&lt;/p&gt;We used the site as a vehicle for our search and results scripts (including several versions over time - adding revise search,  URL Tamer, and AutoBoolean), our Email, Save and Print add-on, our Ordering cart add-on and canned searches.  We used this product as a basis for many a fine looking site.  But then we became restless - we wanted to add more, we wanted to change the undercarriage.  We wanted to make it even better!
&lt;p&gt;&lt;span style="font-weight: bold;"&gt;The renovations
&lt;/span&gt;&lt;/p&gt;The "include" files were frustrating our staff.  While they were a good and simple solution, we wanted to have something more robust; something easier to maintain.  As it turned out we had that in another format.  We converted the includes to &lt;a href="http://msdn.microsoft.com/en-us/library/wtxbf3hh.aspx"&gt;ASP.NET Master Pages&lt;/a&gt; and used our webpub results control, which our late great developer Nathan Mayr was instrumental in creating and which we previously only implemented for our high-end clients.  It was time to share it with everyone.
&lt;p&gt;&lt;span style="font-weight: bold;"&gt;The extras
&lt;/span&gt;&lt;/p&gt;So once we got the groundwork redone, we added the extras.  Based on user requests, we had wanted to add book covers for a while, but what with copyright issues always at the door, we hesitated, but then &lt;a href="http://books.google.com/books"&gt;Google Books with cover images&lt;/a&gt; rose to the fore.  Imagine every book in your catalogue having a nice book cover image in the record and a link to preview the book all through a bit of code around the ISBN number. Note that if there is no matching ISBN at Google Books, nothing shows. The amount of information available at Google Books varies widely - see the title &lt;a href="http://books.google.com/books?id=qLDGf02QkFgC&amp;amp;source=gbs_navlinks_s"&gt;Knowledge and Strategy&lt;/a&gt; for a book that has a detailed Preview with table of contents and selected pages. A great way of letting your users evaluate a title better!  Check out the canned search &lt;a href="http://ask.andornot.com/Results.aspx?BU=http://ask.andornot.com/default.aspx&amp;amp;TN=starter&amp;amp;QY=find%20%28ISBN%20%3D*%29&amp;amp;RF=WebBrief&amp;amp;DF=WebFull&amp;amp;MR=10&amp;amp;NP=255&amp;amp;RL=0&amp;amp;DL=0&amp;amp;XC=&amp;amp;ID=&amp;amp;AC=QBE_QUERY"&gt;Example of Book Covers from Google&lt;/a&gt;... we have added the sundeck to the site.
&lt;p&gt;&lt;span style="font-weight: bold;"&gt;The future
&lt;/span&gt;&lt;/p&gt;Who knows what more we can add to this already pretty groovy set of features and functions.  Tell us what you would like.  You are our lifeblood: we listen to our clients.   Go to &lt;a href="http://ask.andornot.com/"&gt;http://ask.andornot.com&lt;/a&gt; and be part of the next reno - we are thinking about a turret or a wine cellar or a bay-window.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-5385696734075516490?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/D3emnnHcXFY" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">2</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/07/andornot-starter-kit-revamp-with-google.aspx</feedburner:origLink></item><item><title>What I have learned the hard way (as usual) with VMWare</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/RoYng9GkpD4/what-i-have-learned-hard-way-as-usual.aspx</link><author>noreply@blogger.com (Peter Tyrrell)</author><pubDate>Wed, 27 May 2009 12:19:21 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-4367096141484321217</guid><description>&lt;span style="font-weight:bold;"&gt;Always take snapshots when the guest is powered-down.&lt;/span&gt;&lt;div&gt;Although in VMWare Workstation you can take a snapshot at any time, you cannot clone a snapshot taken of a powered-on guest. &lt;/div&gt;&lt;div&gt;
&lt;/div&gt;&lt;div&gt;So for example, I patched a new Windows Server 2003 guest OS with dozens of Windows Updates, installed SQL Server, installed and configured SQL Server Reporting Services, etc. It took hours. I made snapshots at each phase, and indeed was able to revert back to one after screwing up royally. However, when I later went to clone the "all patches" snapshot to re-use the guest somewhere else, I was unable to do so because the guest had been on when I took the snapshot. I pulled out all my teeth in frustration and smashed them with a hammer, then began uninstalling everything after the patches.&lt;/div&gt;&lt;div&gt;
&lt;/div&gt;&lt;div&gt;&lt;b&gt;Check the guest firewall settings if you have host-to-guest network problems&lt;/b&gt;&lt;/div&gt;&lt;div&gt;If you have double-checked that the virtual network settings are not to blame for an inability of the host to communicate with the guest, then ensure the guest firewall settings are not blocking incoming requests.&lt;/div&gt;&lt;div&gt;
&lt;/div&gt;&lt;div&gt;In my case the guest was using bridged networking and could ping the host and connect to the internet via the LAN gateway. The host could not ping the guest, the reason being that the guest firewall disallowed incoming echo requests by default. Further, since I wanted to use the guest as an http server, I needed to allow http requests at the firewall level. The agony preceding this discovery was akin to a hot knife stabbing repeatedly into my liver. &lt;/div&gt;&lt;div&gt;
&lt;/div&gt;&lt;div&gt;&lt;b&gt;32 bit guests created on a 64 bit host can only be deployed on a 32 bit host if the deployed host hardware supports 64 bit processing&lt;/b&gt;&lt;/div&gt;&lt;div&gt;This one is counterintuitive. Just because it's a 32 bit guest doesn't mean it's going to run on a 32 bit host. &lt;/div&gt;&lt;div&gt;
&lt;/div&gt;&lt;div&gt;Newer machines tend to support 64 bit processing. Older ones don't. It's entirely possible that a host will be running a 32 bit OS but be 64 bit capable. How do you know? Download &lt;a href="http://www.cpuid.com/cpuz.php"&gt;CPU-Z&lt;/a&gt; and it will examine the hardware and tell you. The VMWare &lt;a href="http://vmware.com/download/shared_utilities.html"&gt;CPU Identification Utility&lt;/a&gt; might also help, but I'm unclear as to whether it just checks for a 64 bit OS, or hardware 64 bit capability.&lt;/div&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/15297768-4367096141484321217?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/RoYng9GkpD4" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/05/what-i-have-learned-hard-way-as-usual.aspx</feedburner:origLink></item><item><title>TypeMock unit testing</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/FAvtz7UMM-Q/typemock-unit-testing.aspx</link><author>noreply@blogger.com (Ted Jardine)</author><pubDate>Wed, 20 May 2009 09:25:41 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-5353584270007510127</guid><description>I like free!

As &lt;a href="http://vaultofthoughts.net/FreeASPNETBundle.aspx"&gt;Michal Talaga in turn quotes TypeMock's promotion page&lt;/a&gt;&lt;span style="text-decoration: underline;"&gt;:&lt;/span&gt;
&lt;a href="http://vaultofthoughts.net/ct.ashx?id=cdec5758-51b7-4c18-acfc-e46b18fea544&amp;amp;url=http%3a%2f%2fwww.typemock.com%2f"&gt;&lt;/a&gt;&lt;a href="http://vaultofthoughts.net/ct.ashx?id=cdec5758-51b7-4c18-acfc-e46b18fea544&amp;amp;url=http%3a%2f%2fwww.typemock.com%2f"&gt;&lt;/a&gt;&lt;blockquote&gt;&lt;a href="http://www.typemock.com/"&gt;Unit Testing&lt;/a&gt; ASP.NET? &lt;a href="http://www.typemock.com/ASP.NET_unit_testing_page.php"&gt;ASP.NET unit testing&lt;/a&gt; has never been this easy.

Typemock is launching a new product for ASP.NET developers – the &lt;strong&gt;ASP.NET Bundle&lt;/strong&gt; - and for the launch will be giving out &lt;span style="color: rgb(0, 102, 0);"&gt;&lt;strong&gt;FREE licenses&lt;/strong&gt;&lt;/span&gt; to bloggers and their readers.

The ASP.NET Bundle is the ultimate ASP.NET unit testing solution, and offers both &lt;a href="http://www.typemock.com/"&gt;Typemock Isolator&lt;/a&gt;, a &lt;a href="http://www.typemock.com/"&gt;unit test&lt;/a&gt; tool and &lt;a href="http://sm-art.biz/Ivonna.aspx"&gt;Ivonna&lt;/a&gt;, the Isolator add-on for &lt;a href="http://sm-art.biz/Ivonna.aspx"&gt;ASP.NET unit testing&lt;/a&gt;, for a bargain price.

Typemock Isolator is a leading &lt;a href="http://www.typemock.com/"&gt;.NET unit testing&lt;/a&gt; tool (C# and VB.NET) for many ‘hard to test’ technologies such as &lt;a href="http://typemock.com/sharepointpage.php"&gt;SharePoint&lt;/a&gt;, &lt;a href="http://www.typemock.com/ASP.NET_unit_testing_page.php"&gt;ASP.NET&lt;/a&gt;, &lt;a href="http://www.typemock.com/ASP.NET_unit_testing_page.php"&gt;MVC&lt;/a&gt;, &lt;a href="http://www.typemock.com/wcfpage.php"&gt;WCF&lt;/a&gt;, WPF, &lt;a href="http://www.typemock.com/Silverlight_unit_testing_page.php"&gt;Silverlight&lt;/a&gt; and more. Note that for &lt;a href="http://www.typemock.com/Silverlight_unit_testing_page.php"&gt;unit testing Silverlight&lt;/a&gt; there is an open source Isolator add-on called &lt;a href="http://www.typemock.com/Silverlight_unit_testing_page.php"&gt;SilverUnit&lt;/a&gt;.

The first 60 bloggers who will blog this text in their blog and &lt;a href="http://blog.typemock.com/2009/05/get-free-typemock-licenses-aspnet.html"&gt;tell us about it&lt;/a&gt;, will get a Free Isolator ASP.NET Bundle license (Typemock Isolator + Ivonna). If you post this in an ASP.NET &lt;strong&gt;dedicated&lt;/strong&gt; blog, you'll get a license automatically (even if more than 60 submit) during the first week of this announcement.

Also 8 bloggers will get an &lt;strong&gt;additional 2 licenses&lt;/strong&gt; (each) to give away to their readers / friends.

Go ahead, click the following link for &lt;a href="http://blog.typemock.com/2009/05/get-free-typemock-licenses-aspnet.html"&gt;more information &lt;/a&gt;on how to get your free license.&lt;/blockquote&gt;Yep, free sounds good. I've not had a chance to try out TypeMock, so this will be a good opportunity.&lt;hints id="hah_hints"&gt;&lt;/hints&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-5353584270007510127?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/FAvtz7UMM-Q" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/05/typemock-unit-testing.aspx</feedburner:origLink></item><item><title>Inmagic Webpublisher works on Windows 7</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/JBDQXMAepHw/inmagic-webpublisher-works-on-windows-7.aspx</link><author>noreply@blogger.com (Peter Tyrrell)</author><pubDate>Wed, 06 May 2009 13:35:18 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-941797723188233488</guid><description>I installed Windows 7 RC a few days ago and so far it looks like Inmagic DB/Textworks 11 and Webpublisher Pro 11 are compatible with it.

Both must be installed in "run as administrator" mode, of course. See &lt;a href="http://www.andornot.com/about/developerblog/2007/06/how-to-install-inmagic-dbtextworks-on.aspx"&gt;the post related to Vista installs&lt;/a&gt; for details and further links.

&lt;a href="http://www.andornot.com/about/developerblog/2008/05/how-to-install-webpublisher-on-64-bit.aspx"&gt;This post for installing Webpublisher on 64 bit IIS 7&lt;/a&gt; is still valid for Windows 7.

Also &lt;a href="http://www.andornot.com/about/developerblog/2008/07/inmagic-dbtextworks-and-vista.aspx"&gt;Denise's warning against putting textbases in the Program Files folder&lt;/a&gt; still applies. (Virtualization spirits the files away out of the Program Files folder.)

One thing unfortunately is insurmountable at this point: &lt;a href="http://support.microsoft.com/kb/917607"&gt;there is no WinHlp32 support for Windows 7 RC&lt;/a&gt; (though there will be when Windows 7 goes RTM) so no DB/Textworks help for me. I've memorized it anyway.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-941797723188233488?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/JBDQXMAepHw" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/05/inmagic-webpublisher-works-on-windows-7.aspx</feedburner:origLink></item><item><title>The importance of beauty</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/rD5NtDnleBI/importance-of-beauty.aspx</link><author>noreply@blogger.com (Peter Tyrrell)</author><pubDate>Tue, 21 Apr 2009 10:55:02 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-1614505312607046783</guid><description>&lt;p&gt;A fine article from the good people at &lt;a href="http://alistapart.com/"&gt;A List Apart&lt;/a&gt; (the website for people who make websites). I always strive for aesthetically pleasing design in my work at Andornot. It just feels better when it looks good.&lt;/p&gt;  &lt;p&gt;&lt;em&gt;In Defense of Eye Candy     &lt;br /&gt;&lt;/em&gt;&amp;quot;Research proves attractive things work better. How we think cannot be separated from how we feel. The next time a boss, client, or co-worker scoffs at the notion that beauty is an important aspect of interface design, point their peepers here.&amp;quot;    &lt;br /&gt;    &lt;br /&gt;&lt;a href="http://www.alistapart.com/articles/indefenseofeyecandy"&gt;http://www.alistapart.com/articles/indefenseofeyecandy&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-1614505312607046783?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/rD5NtDnleBI" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/04/importance-of-beauty.aspx</feedburner:origLink></item><item><title>MS Office Features for Tracking Revisions</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/3CpEnaJ6f_k/ms-office-features-for-tracking.aspx</link><category>Microsoft Word</category><category>MS Office 2007</category><author>noreply@blogger.com (Jonathan Jacobsen)</author><pubDate>Thu, 16 Apr 2009 09:26:11 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-6370452324159566484</guid><description>&lt;p&gt;Have you ever sent a Word document or Excel spreadsheet out for review and asked the recipient to please, please, please either turn on Track Changes or insert Comments, so you can see their revisions, only to have the document come back with neither? If so, here are two features available in Word and Excel that will help.  &lt;p&gt;First, before sending a document out for review, you can turn on Track Changes in such a way that the recipient cannot turn it off without knowing a password. To do so in Word 2007:  &lt;ol&gt; &lt;li&gt;Select the Review tab on the Ribbon Bar, click the Protect Document button, and choose the Restrict Formatting and Editing option.  &lt;li&gt;In the panel that appears, ignore option 1, but tick option 2 and change the drop down selector to Tracked Changes (or Comments if you prefer to only allow comments to be made).  &lt;li&gt;Click the Yes, Start Enforcing Protection button and enter a password when prompted, to allow you to turn off Tracked Changes or Comments later. &lt;li&gt;Save the document and send it out for review.&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;The procedure is similar in Excel.  &lt;p&gt;In both applications, you can also be more fine-grained in what editing you allow, such as restricting editing to speciic cells in a spreadsheet or styles in a document (e.g. the user may edit body text but not headings).  &lt;p&gt;The document may be opened by the recipient as usual, but Track Changes or Comments will be enabled and may only be disabled by following the same steps as above, but disabling protection with the password.  &lt;p&gt;&lt;b&gt;&lt;i&gt;&lt;/i&gt;&lt;/b&gt; &lt;p&gt;If you had forgotten to add Track Changes (with a password) to the document that you sent, you can use the Compare option. Open your original document and the one that was edited without changes being tracked. You can then compare the two and produce a version with changes tracked, which you can then proceed to accept or reject as appropriate.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-6370452324159566484?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/3CpEnaJ6f_k" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/04/ms-office-features-for-tracking.aspx</feedburner:origLink></item><item><title>Errors when attempting to run Database Publishing Wizard on a 64-bit Vista machine</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/GPiaeeyUdx8/errors-when-attempting-to-run-database.aspx</link><category>tools</category><category>SQL Server</category><author>noreply@blogger.com (Ted Jardine)</author><pubDate>Wed, 15 Apr 2009 10:44:23 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-2671251715187224642</guid><description>If you're attempting to use Microsoft's &lt;a href="http://www.microsoft.com/downloads/details.aspx?familyid=56E5B1C5-BF17-42E0-A410-371A838E570A&amp;amp;displaylang=en"&gt;Database Publishing Wizard&lt;/a&gt; you might run into an error like the following (if you're running SQL Server Express 2005 - don't know if you will run into it with SQL Server 2005 Standard etc.):

&lt;blockquote&gt;This wizard will close because it encountered the following error:

Could not load file or assembly 'Microsoft.SqlServer.BatchParser, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. The system cannot find the file specified. (Microsoft.SqlServer.ConnectionInfo)&lt;/blockquote&gt;If you do, just download the x64 version of Microsoft SQL Server 2005 Management Objects Collection located &lt;a href="http://www.microsoft.com/downloads/details.aspx?familyid=d09c1d60-a13c-4479-9b91-9e8b9d835cdc&amp;amp;displaylang=en"&gt;here&lt;/a&gt;. &lt;a href="http://forums.asp.net/t/1348920.aspx"&gt;This post pointed me in the right direction&lt;/a&gt; as the possible solution suggested does in fact resolve the issue.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-2671251715187224642?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/GPiaeeyUdx8" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/04/errors-when-attempting-to-run-database.aspx</feedburner:origLink></item><item><title>Genie Label Formatting Tricks</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/Wu14GOS3LhM/genie-label-formatting-tricks.aspx</link><category>Inmagic Genie</category><category>inmagic</category><category>label</category><author>noreply@blogger.com (Jonathan Jacobsen)</author><pubDate>Tue, 17 Mar 2009 15:21:02 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-1597882397019249032</guid><description>&lt;h3&gt;Item Fields Appear After Catalog Fields&lt;/h3&gt; &lt;p&gt;When defining a catalog label in MyLabels.config, you can pull data from both the Catalog and Items textbases. Data from Items is wrapped in &amp;lt;ItemInfo&amp;gt; tags  &lt;p&gt;e.g. &lt;br&gt;&amp;lt;ItemInfo&amp;gt;&lt;br&gt;&amp;nbsp; &amp;lt;Field Name="ItemVolume" Header="v." /&amp;gt;&lt;br&gt;&amp;nbsp; &amp;lt;Field Name="ItemCopyInfo" Header="c." /&amp;gt;&lt;br&gt;&amp;lt;/ItemInfo&amp;gt;  &lt;p&gt;While you can place the ItemInfo section anywhere in the label definition, when the label is rendered on screen or printed, the ItemInfo section will always appear last. It's best to place it last in the config file section as well, so it's clear where it will appear on the label.&lt;/p&gt; &lt;p&gt;If you have a strong need to place some Item fields before or in between Catalog fields, it is possible to subdivide one of the boxes on the labels into smaller boxes, one with the Catalog fields and the other with the Item fields. It takes some dedicated work with a ruler and finessing of the label measurements, some trial and error with the printer, and a dose of patience, but it can be done.&lt;/p&gt; &lt;h3&gt;Limit Number of Words&lt;/h3&gt; &lt;p&gt;If you have a field on the label, such as Title or Subtitle, that tends to have quite a bit of data in it, it may not fit in the available space on the label, and will push other fields down and off the label. One remedy is to limit the amount of data from the field that appears. You can do this by adding this line&lt;/p&gt; &lt;p&gt;UseFunction="NumberOfWords(x)"&lt;/p&gt; &lt;p&gt;to the field (where x is a number).  &lt;p&gt;e.g. &lt;br&gt;&amp;lt;Field Name="CatTitle" Style="font-weight:bold" UseFunction="NumberOfWords(5)" /&amp;gt;  &lt;p&gt;This function is documented in the Inmagic Genie Technical Notes document in relation to the MyReports.config file. However, it works equally well in MyLabels.config. &lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-1597882397019249032?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/Wu14GOS3LhM" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/03/genie-label-formatting-tricks.aspx</feedburner:origLink></item><item><title>My Software Tools List: What I Put On My Machine</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/qPhwNJkrrPk/my-software-tools-list-what-i-put-on-my.aspx</link><category>tools</category><category>add-ons</category><category>software</category><category>Vista</category><category>utilities</category><category>Firefox</category><author>noreply@blogger.com (Ted Jardine)</author><pubDate>Tue, 10 Mar 2009 15:32:23 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-8893850381010110698</guid><description>&lt;p&gt;&lt;a href="http://www.shopping.hp.com/webapp/shopping/computer_can_series.do?storeName=computer_store&amp;amp;category=notebooks&amp;amp;a1=Brand&amp;amp;v1=HP+HDX&amp;amp;series_name=HDX18t_series" target="_blank"&gt;My new laptop&lt;/a&gt; should arrive any day now (yay! It just came!), so in preparation for setting it all up again, here's my list of everything I'll put on it (in the spirit of &lt;a href="http://www.hanselman.com/tools" target="_blank"&gt;Scott Hanselman's excellent "Ultimate Developer and Power Users Tool List for Windows"&lt;/a&gt;):&lt;/p&gt; &lt;h2&gt;Standard Fare and Utilities&lt;/h2&gt; &lt;ul&gt; &lt;li&gt;&lt;font color="#3f3f3f"&gt;Windows Vista Ultimate (and soon Windows 7)&lt;br&gt;&lt;em&gt;I'd put the Beta on now, but that means a repave would come too soon.&lt;/em&gt;&lt;/font&gt;  &lt;li&gt;&lt;font color="#3f3f3f"&gt;&lt;a href="http://www.executor.dk/" target="_blank"&gt;Executor&lt;/a&gt;&lt;br&gt;&lt;em&gt;I bind it to Win-A and instantly have the best application launcher out there for Windows. Almost as pretty as &lt;/em&gt;&lt;a href="http://www.launchy.net/" target="_blank"&gt;&lt;em&gt;Launchy&lt;/em&gt;&lt;/a&gt;&lt;em&gt; and &lt;a href="http://www.humanized.com/" target="_blank"&gt;Enso&lt;/a&gt; (well, not quite, but we can't be too picky) and even more functional than &lt;/em&gt;&lt;a href="http://www.bayden.com/SlickRun/" target="_blank"&gt;&lt;em&gt;SlickRun&lt;/em&gt;&lt;/a&gt;&lt;em&gt;. After first trying it, it promptly became my launcher of choice; it's ridiculous how much you can do with it.&lt;/em&gt;&lt;/font&gt;  &lt;li&gt;&lt;font color="#3f3f3f"&gt;&lt;a href="http://www.realtimesoft.com/ultramon/" target="_blank"&gt;Ultramon&lt;/a&gt;&lt;br&gt;&lt;em&gt;Absolutely necessary when running multi-monitors (latest beta works without issues). &lt;/em&gt;&lt;a href="http://www.binaryfortress.com/displayfusion/" target="_blank"&gt;&lt;em&gt;DisplayFusion&lt;/em&gt;&lt;/a&gt;&lt;em&gt; looks good as well so I'm actually going to try it out as it's the first legitimate competitor I've seen for Ultramon in all the years I've used it.&lt;/em&gt;&lt;/font&gt;  &lt;li&gt;&lt;font color="#3f3f3f"&gt;&lt;a href="http://www.roboform.com/" target="_blank"&gt;Roboform&lt;/a&gt;&lt;br&gt;Phenomenal way to securely store and use login credentials and software codes, and autofill registration and checkout forms (including credit card information). Expensive but worth it. I've also been trying out &lt;a href="https://lastpass.com/" target="_blank"&gt;LastPass&lt;/a&gt; on my netbook. RoboForm's usability is a tiny bit better (for i.e. keyboard shortcuts are better, especially for initial login) and it is more secure because data is only stored locally (which I use Windows Live Sync - see below - to synchronize between multiple machines), but LastPass has the huge convenience of having a central repository so that data is instantly synced between all machines (including the ability to get access from other machines, including public ones where you can &lt;a href="https://lastpass.com/help.php?topic=otp&amp;amp;fromwebsite=1" target="_blank"&gt;utilize one time login credentials&lt;/a&gt; for greater security). Oh, and LastPass if free. Regardless, use something and create strong passwords.&lt;/font&gt;  &lt;li&gt;&lt;font color="#3f3f3f"&gt;&lt;a href="http://www.bluemars.org/clipx/" target="_blank"&gt;ClipX&lt;/a&gt;&lt;br&gt;&lt;em&gt;Tiny clipboard history manager. I've been using the beta x86 version with very few glitches for a long time now. Will be using the x64 beta on the new machine.&lt;/em&gt;&lt;/font&gt;  &lt;li&gt;&lt;a href="https://www.foldershare.com/" target="_blank"&gt;Windows Live Sync&lt;/a&gt; (aka FolderShare)&lt;br&gt;&lt;em&gt;Great way to securely sync files between your different machines, and if wanted, between different users. I use it to sync RoboForm data, YNAB data, and more.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.techsmith.com/screen-capture.asp" target="_blank"&gt;SnagIt&lt;/a&gt;&lt;br&gt;&lt;em&gt;Screen capturing software. When Peter first told me how much he loved it, I guffawed and told him it was screen capturing software! How could it be worth $50 USD?!? (even more in beaver bucks). But I tried out the trial and...well, me of so little faith: Peter was right. Phenomenal piece of software that I promptly purchased (do a google for a coupon codes for a price reduction).&lt;/em&gt;  &lt;li&gt;&lt;a href="http://notepad-plus.sourceforge.net/uk/site.htm" target="_blank"&gt;Notepad++&lt;/a&gt;  &lt;li&gt;Microsoft Office 2007  &lt;li&gt;QuickBooks&lt;br&gt;&lt;em&gt;Someday there will be a replacement for this software that seems stuck back in the 90's, but until there is, couldn't live without it even though it regularly contributes to a receding hair line (I am so thankful I am not a bookkeeper and I raise my glass to the wonderful bookkeepers in my life: Pat and &lt;/em&gt;&lt;a href="http://www.hilltopbookkeeping.com/" target="_blank"&gt;&lt;em&gt;Maxine&lt;/em&gt;&lt;/a&gt;&lt;em&gt;).&lt;/em&gt;  &lt;li&gt;&lt;a href="http://mozy.com/" target="_blank"&gt;Mozy&lt;/a&gt;&lt;br&gt;&lt;em&gt;Please backup, backup often, and backup off-site. Mozy makes the process easier, although I think I'll be trying out &lt;/em&gt;&lt;a href="http://www.idrive.com/" target="_blank"&gt;&lt;em&gt;IDrive&lt;/em&gt;&lt;/a&gt;&lt;em&gt; this time around because of many additional features including its ability to synchronize multiple machines to local media (external USB drive) which then syncs up online. I've got ~90GB of data so I'm hoping the synchronization process is a little faster with IDrive (Mozy churns away "replicating splines" when determining what of my local 90GB of data has changed/been added - apparently that's some sci-fi reference). Regardless, both are dirt cheap for personal home use (unlimited for $4.95/month with yearly discounts available). Eventually I'll get a &lt;/em&gt;&lt;a href="http://www.microsoft.com/windows/products/winfamily/windowshomeserver/default.mspx" target="_blank"&gt;&lt;em&gt;Windows Home Server&lt;/em&gt;&lt;/a&gt;&lt;em&gt; configured too, which will be even better!&lt;/em&gt;  &lt;li&gt;&lt;a href="http://download.live.com/?sku=messenger" target="_blank"&gt;Windows Live Messenger (aka MSN Messenger)&lt;/a&gt;&lt;br&gt;&lt;em&gt;Someday I'll find an alternative that works well (have tried &lt;/em&gt;&lt;a href="http://www.andornot.com/about/developerblog/2008/03/pidgin-and-toasters.aspx" target="_blank"&gt;&lt;em&gt;Trillian and Pidgin&lt;/em&gt;&lt;/a&gt;&lt;em&gt;, but both have bigger shortcomings either in usability or stability). At least there's a registry hack you can do to remove the ads in Windows Live Messenger (no, I am still not interested in "Singles in Surrey").&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.7-zip.org/" target="_blank"&gt;7-zip&lt;/a&gt;&lt;br&gt;&lt;em&gt;Great file compression (that can also read and write to RAR and ZIP).&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.randyrants.com/sharpkeys/" target="_blank"&gt;SharpKeys&lt;/a&gt;&lt;br&gt;&lt;em&gt;A registry hack that is used to make certain keys on a keyboard act like other keys. I use this to map unused keys on my Apple keyboard to something more useful:&lt;/em&gt;  &lt;ul&gt; &lt;li&gt;&lt;em&gt;f13: Print Screen (used all the time with SnagIt)&lt;/em&gt;  &lt;li&gt;&lt;em&gt;f14: Insert&lt;/em&gt;  &lt;li&gt;&lt;em&gt;f16: Mute&lt;/em&gt;  &lt;li&gt;&lt;em&gt;f17: Volume Down&lt;/em&gt;  &lt;li&gt;&lt;em&gt;f18: Volume Up&lt;/em&gt;  &lt;li&gt;&lt;em&gt;f19: Calculator&lt;/em&gt;  &lt;li&gt;&lt;em&gt;Right-Ctrl: Application Menu&lt;/em&gt;&lt;/li&gt;&lt;/ul&gt; &lt;li&gt;&lt;a href="http://insentient.net/" target="_blank"&gt;Switcher&lt;/a&gt;&lt;br&gt;&lt;em&gt;What Vista should have done for its Alt-Tab implementation.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.youneedabudget.com/features/" target="_blank"&gt;YNAB Pro&lt;/a&gt;&lt;br&gt;&lt;em&gt;Budgeting software that just works.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.skype.com" target="_blank"&gt;Skype&lt;/a&gt;  &lt;li&gt;&lt;a href="http://www.pantone.com/Pages/products/product.aspx?pid=562" target="_blank"&gt;Pantone Huey PRO&lt;/a&gt;  &lt;li&gt;&lt;a href="http://www.utorrent.com/" target="_blank"&gt;µTorrent&lt;/a&gt;&lt;br&gt;BitTorrent client.  &lt;li&gt;&lt;a href="http://www.ted.nu/" target="_blank"&gt;ted&lt;/a&gt;&lt;br&gt;Torrent Episode Downloader with a great name ;-)  &lt;li&gt;&lt;a href="http://www.andornot.com/about/developerblog/2009/03/startup-delayer-get-working-faster.aspx" target="_blank"&gt;Startup Delayer&lt;/a&gt;  &lt;li&gt;&lt;a href="http://windowslivewriter.spaces.live.com/" target="_blank"&gt;Windows Live Writer&lt;/a&gt;  &lt;li&gt;&lt;a href="http://www.free-codecs.com/download/K_Lite_Codec_Pack.htm" target="_blank"&gt;ffdshow and K-Lite Codec Pack&lt;/a&gt;&lt;br&gt;&lt;em&gt;Just use this codec pack to cover pretty much any codec you need to view or listen to digital media.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.plaxo.com/" target="_blank"&gt;Plaxo&lt;/a&gt;&lt;br&gt;&lt;em&gt;Used to sync contacts and calendar with all other machines for accounts other than Exchange.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.acronis.com/" target="_blank"&gt;Acronis TrueImage&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt; &lt;h2&gt;Development&lt;/h2&gt; &lt;ul&gt; &lt;li&gt;Microsoft Visual Studio 2008 Professional  &lt;li&gt;&lt;a href="http://www.jetbrains.com/resharper/" target="_blank"&gt;Resharper&lt;/a&gt;&lt;br&gt;&lt;em&gt;Friends don't let friends develop without it.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://subversion.tigris.org/" target="_blank"&gt;Subversion&lt;/a&gt;, &lt;a href="http://tortoisesvn.tigris.org/" target="_blank"&gt;TortoiseSVN&lt;/a&gt;, and &lt;a href="http://www.visualsvn.com/visualsvn/" target="_blank"&gt;VisualSVN&lt;/a&gt;&lt;br&gt;&lt;em&gt;I'd like to say something about this combo, but words fail me.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.roland-weigelt.de/ghostdoc/" target="_blank"&gt;GhostDoc&lt;/a&gt;&lt;br&gt;&lt;em&gt;Free add-in for visual Studio that automatically generates XML documentation comments for C#.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://vmware.com/products/player/" target="_blank"&gt;VMWare Player&lt;/a&gt;/&lt;a href="http://vmware.com/products/ws/" target="_blank"&gt;VMWare Workstation&lt;/a&gt;&lt;br&gt;&lt;em&gt;The former is free, and the latter is expensive. The latter also makes like easier, but you can hack things (legally of course) to get the player to do what you need it to. There wouldn't be a dilemma except for the fact that the player is prettier and has Unity (where the guest application windows look just like host application windows, but with color-coded borders - much easier to tab through applications while developing)! Unity is in Beta for Windows right now, so once it's out of beta, I guess I'll go for less pretty with more functionality (and the relatively hefty price tag).&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.gallio.org/" target="_blank"&gt;Gallio&lt;/a&gt;  &lt;li&gt;&lt;a href="http://www.testdriven.net/" target="_blank"&gt;TestDriven.NET&lt;/a&gt;  &lt;li&gt;&lt;a href="http://www.red-gate.com/Products/ants_profiler/index.htm" target="_blank"&gt;ANTS Profiler&lt;/a&gt;  &lt;li&gt;&lt;a href="http://www.microsoft.com/windows/downloads/virtualpc/default.mspx" target="_blank"&gt;Microsoft Virtual PC&lt;/a&gt;  &lt;li&gt;&lt;a href="http://www.red-gate.com/products/reflector/" target="_blank"&gt;.NET Reflector&lt;/a&gt;  &lt;li&gt;&lt;a href="http://www.adobe.com/products/creativesuite/design/" target="_blank"&gt;Adobe Creative Suite Design Premium&lt;/a&gt;  &lt;li&gt;&lt;a href="http://www.autohotkey.com/" target="_blank"&gt;AutoHotKey&lt;/a&gt;  &lt;li&gt;&lt;a href="http://www.nhprof.com/" target="_blank"&gt;NH Prof&lt;/a&gt;&lt;br&gt;&lt;em&gt;If you do anything at all with NHibernate, just buy this (beta promotional pricing still in affect).&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.scootersoftware.com/" target="_blank"&gt;Beyond Compare 3&lt;/a&gt;&lt;br&gt;&lt;em&gt;Another "just buy it" bit of software. I got a discount coupon through &lt;a href="http://www.donationcoder.com/" target="_blank"&gt;DonationCoder.com&lt;/a&gt; that is no longer there, but hopefully will return.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.regexbuddy.com/" target="_blank"&gt;RegexBuddy&lt;/a&gt;&lt;br&gt;&lt;em&gt;If you do anything with Regex, have mercy on yourself and buy this. Worth every penny.&lt;/em&gt;  &lt;li&gt;SQL Server  &lt;li&gt;&lt;a href="http://www.oracle.com/technology/tech/windows/odpnet/index.html" target="_blank"&gt;Oracle .NET Client&lt;/a&gt;  &lt;li&gt;And more of the usual...&lt;/li&gt;&lt;/ul&gt; &lt;h2&gt;Firefox and Add-Ons&lt;/h2&gt; &lt;p&gt;Deserves a section all to itself.&lt;/p&gt; &lt;ul&gt; &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/1843" target="_blank"&gt;Firebug&lt;/a&gt;&lt;br&gt;&lt;em&gt;As they say, "Web Development Evolved"&lt;/em&gt;  &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/5369" target="_blank"&gt;YSlow&lt;/a&gt;&lt;br&gt;&lt;em&gt;Not only does it analyze web pages and help point out why they're slow, it also provides an easy way to view file references &lt;/em&gt; &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/60" target="_blank"&gt;Web Developer&lt;/a&gt;  &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/3615" target="_blank"&gt;Delicious Bookmarks&lt;/a&gt;&lt;br&gt;&lt;em&gt;I'm kind of lost without this add-on. You can get it working with Google Chrome if you want too (and IE is supported).&lt;/em&gt;  &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/748" target="_blank"&gt;Greasemonkey&lt;/a&gt;&lt;br&gt;&lt;em&gt;Manages user scripts for firefox so that you can make a site, for i.e. Google Reader, look the way you want it to. For my Asus EEE PC, I use the &lt;a href="http://userstyles.org/styles/12691" target="_blank"&gt;"Google Reader Absolutely Compact" script&lt;/a&gt; to make the best use of the netbook's smaller screen.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://www.andornot.com/about/developerblog/2008/12/hit-hint-replacement-lol-fork-of-hah.aspx" target="_blank"&gt;LoL&lt;/a&gt;&lt;br&gt;Mouseless browsing.  &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/4762" target="_blank"&gt;Hide MenuBar&lt;/a&gt;&lt;br&gt;Hides the menu bar which is a complete waste of screen space (and still easily available by pressing the Alt key)  &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/4014" target="_blank"&gt;Locationbar²&lt;/a&gt;&lt;br&gt;Formats and linkifies addresses in your address bar.  &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/684" target="_blank"&gt;FireFTP&lt;/a&gt;&lt;br&gt;&lt;em&gt;FTP client integrated with the browser.&lt;/em&gt;  &lt;li&gt;&lt;a href="http://downloadstatusbar.mozdev.org/index.html" target="_blank"&gt;Download Statusbar&lt;/a&gt;  &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/9403" target="_blank"&gt;SenSEO&lt;/a&gt;  &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/8160" target="_blank"&gt;jQuery Menu&lt;/a&gt;  &lt;li&gt;&lt;a href="https://addons.mozilla.org/en-US/firefox/addon/3653" target="_blank"&gt;Canadian English Dictionary&lt;/a&gt;&lt;br&gt;Hosehead is a word, eh!&lt;/li&gt;&lt;/ul&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-8893850381010110698?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/qPhwNJkrrPk" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">3</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/03/my-software-tools-list-what-i-put-on-my.aspx</feedburner:origLink></item><item><title>really truly private variables in javascript</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/z34iB4oUrkU/really-truly-private-variables-in.aspx</link><author>noreply@blogger.com (Peter Tyrrell)</author><pubDate>Mon, 09 Mar 2009 09:09:17 PDT</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-6818423450108603024</guid><description>&lt;p&gt;I just read, and then for good measure re-read, &amp;quot;&lt;a href="http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockford/dp/0596517742"&gt;JavaScript: The Good Parts&lt;/a&gt;&amp;quot; by &lt;a href="http://www.crockford.com/"&gt;Douglas Crockford&lt;/a&gt;, who is probably the foremost javascript authority on planet Earth. The book blew my mind. I thought I knew javascript; I thought I had a pretty good grasp of it; before I picked up this book I would have referred to myself as a javascript &lt;em&gt;expert&lt;/em&gt; when introducing myself at parties. It turns out I had a lot more to think about. I find this delightful.&lt;/p&gt;  &lt;p&gt;One of the valuable lessons I learned is a javascript module pattern, discussed with examples at the YUI (Yahoo! User Interface) blog: &lt;a href="http://yuiblog.com/blog/2007/06/12/module-pattern/"&gt;http://yuiblog.com/blog/2007/06/12/module-pattern/&lt;/a&gt;. The take home message is that you can create objects that support private members. I didn't even know that was possible, but it turns out that it is, due to &lt;a href="http://www.robertnyman.com/2008/10/09/explaining-javascript-scope-and-closures/"&gt;function scope and the concept of closure&lt;/a&gt;. It took me a few reads with furrowed brow to grok closure, so I can hardly explain it quickly, but essentially:&lt;/p&gt;  &lt;ol&gt;   &lt;li&gt;A function can return a function and then wink out of existence.&lt;/li&gt;    &lt;li&gt;The returned inner function retains access to other members and data defined in its original parent function.&lt;/li&gt;    &lt;li&gt;Those other members and data are not directly accessible anymore, so they are private.&lt;/li&gt; &lt;/ol&gt;  &lt;p&gt;Fantastic.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-6818423450108603024?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/z34iB4oUrkU" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/03/really-truly-private-variables-in.aspx</feedburner:origLink></item><item><title>Visual Studio 2008 SP1 acting very intoxicated when attempting to step through a debug session</title><link>http://feedproxy.google.com/~r/AndornotDevelopersBlog/~3/rCn4PkCEcw8/visual-studio-2008-sp1-acting-very.aspx</link><category>Visual Studio 2008 SP1</category><category>Visual Studio 2008</category><category>bug</category><author>noreply@blogger.com (Ted Jardine)</author><pubDate>Wed, 04 Mar 2009 16:50:44 PST</pubDate><guid isPermaLink="false">tag:blogger.com,1999:blog-15297768.post-5630284716710972734</guid><description>&lt;p&gt;I...really...thought...I...was...going...crazy. For some reason Visual Studio started to behave &lt;em&gt;very&lt;/em&gt; abnormally when attempting to debug and step through some code. When I asked it to step through, it stepped out. When I asked it to step out, it stepped in. Half the time it would ignore breakpoints, the other half of the time, it would make some up. To keep me on my toes, it just worked enough to make me think that the problem lay with me. An hour later, after (in completely random order):&lt;/p&gt; &lt;ul&gt; &lt;li&gt;Rebooting&lt;/li&gt; &lt;li&gt;Rebuilding&lt;/li&gt; &lt;li&gt;Rebuilding after cleaning a build&lt;/li&gt; &lt;li&gt;Googling "Visual Studio acting crazy while debugging" and other sundry queries&lt;/li&gt; &lt;li&gt;Cleaning out the keyboard (and thinking "oh no, &lt;a href="http://www.apple.com/keyboard/" target="_blank"&gt;my favourite keyboard&lt;/a&gt; is biting the dust &lt;a href="http://www.engadget.com/2009/03/03/apple-axes-the-numeric-keypad-on-imacs-standard-wired-keyboard/" target="_blank"&gt;just as Steve Jobs decides to chop off the numberpad&lt;/a&gt;" - yes, I know you can still get the old one, but...)&lt;/li&gt; &lt;li&gt;Clearing out ReSharper caches &lt;/li&gt; &lt;li&gt;Clearing out ASP.NET caches&lt;/li&gt; &lt;li&gt;Using the mouse to debug (how anybody does that is beyond me)&lt;/li&gt; &lt;li&gt;Rewriting code &lt;/li&gt; &lt;li&gt;Staring at the screen literally thinking I was going crazy&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;...I stumbled across this "&lt;a href="http://www.rp2c.com/blogofbob/VisualStudio2008SP1FunkyDebugSteppingAndMissedBreakpoints.aspx" target="_blank"&gt;Visual Studio 2008 SP1 Funky Debug Stepping and Missed Breakpoints&lt;/a&gt;" post from a &lt;a href="http://www.rp2c.com/blogofbob/" target="_blank"&gt;BlogOfBob&lt;/a&gt;. Yes, Visual Studio was drunk and &lt;a href="http://code.msdn.microsoft.com/KB957912/Release/ProjectReleases.aspx?ReleaseId=1796" target="_blank"&gt;MS has the fix&lt;/a&gt;. Now to undo the carnage: thank goodness for &lt;a href="http://subversion.tigris.org/" target="_blank"&gt;subversion&lt;/a&gt;; and whoever you are Bob, God bless you.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/15297768-5630284716710972734?l=www.andornot.com%2Fabout%2Fdeveloperblog%2FDefault.aspx'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/AndornotDevelopersBlog/~4/rCn4PkCEcw8" height="1" width="1"/&gt;</description><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://www.andornot.com/about/developerblog/2009/03/visual-studio-2008-sp1-acting-very.aspx</feedburner:origLink></item></channel></rss>
