Friday, October 21, 2005

Ok this is another one of those things that's probably been around for quite a while, but I had never seen or knew about.
How often have you wanted to created a select list (drop down) with category headers, but you don't want someone to selcect the category header itself? Well you'd have to assign a value of  -1 or 0 or something, and then perform some sort of validation to ensure the user had not chosen the 'invalid' item.

I found this on the Apple site, and although I need to do some more research, it appears to be part of the HTML 4.0 spec, and so far it works in every browser I've tried it in.

Here is the dropdown (it does not do anything):

And here's the script:
   <SELECT NAME="browser">
    <option label="-1" selected>Choose a browser...</option>
    <OPTGROUP LABEL="Netscape Navigator">
     <OPTION LABEL="4.x or higher">
      Netscape Navigator 4.x or higher
     </OPTION>
     <OPTION LABEL="3.x">Netscape Navigator 3.x</OPTION>
     <OPTION LABEL="2.x">Netscape Navigator 2.x</OPTION>
     <OPTION LABEL="1.x">Netscape Navigator 1.x</OPTION>
    </OPTGROUP>
    <OPTGROUP LABEL="Microsoft Internet Explorer">
     <OPTION LABEL="4.x or higher">
      Microsoft Internet Explorer 4.x or higher
     </OPTION>
     <OPTION LABEL="3.x">Microsoft Internet Explorer 3.x</OPTION>
     <OPTION LABEL="2.x">Microsoft Internet Explorer 2.x</OPTION>
     <OPTION LABEL="1.x">Microsoft Internet Explorer 1.x</OPTION>
    </OPTGROUP>
    <OPTGROUP LABEL="Opera">
     <OPTION LABEL="3.x or higher">Opera 3.x or higher</OPTION>
     <OPTION LABEL="2.x">Opera 2.x</OPTION>
     <OPTION>Other</OPTION>
    </OPTGROUP>
   </SELECT>

Friday, October 21, 2005 10:50:17 AM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Thursday, October 20, 2005

So I was looking for a way to 'randomly' display a picture from a given directory. I was going to get all crazy, and do a bunch of file system operations, and then some randomization on that. After I had started, I stopped. I thought this does not need to be so complicated!

I talked to a few friends, who thought my approach seemed fine. But to be quite honest I was in a lazy mood and decided that I didn't feel like comming up with some complicated solution for something that seems so easy. Then it hit me. Isn't there some AdRotator thing in .NET? Yeah there is, and it's slick.

I simply added the following code to my .aspx page.

<asp:AdRotator id="ar1" AdvertisementFile="headers.xml" BorderWidth="0" runat=server />

Well I'm not really using Ads. I have a header graphic similar to a banner ad, but I wanted it to be random each time the page loaded. The cool thing about using this control is that there is no codebehind logic to worry about.

There is then an xml file in this case called headers.xml with the followng structure:

<?xml version="1.0" encoding="utf-8" ?>
<Advertisements>

<Ad>
<ImageUrl>images/header/header1_noglow.jpg</ImageUrl>
<AlternateText>Alt Text</AlternateText>
<Impressions>1</Impressions>
</Ad>

<Ad>
<ImageUrl>images/header/header_sky2.jpg</ImageUrl>
<AlternateText>Alt Text</AlternateText>
<Impressions>1</Impressions>
</Ad>

<Ad>
<ImageUrl>images/header/header_sky.jpg</ImageUrl>
<AlternateText>Alt Text</AlternateText>
<Impressions>1</Impressions>
</Ad>

<Ad>
<ImageUrl>images/header/header_window.jpg</ImageUrl>
<AlternateText>Alt Text</AlternateText>
<Impressions>1</Impressions>
</Ad>

</Advertisements>

Here are the arguments that you can configure in the XML file, and what they do on the front end.

  • ImageUrl - An absolute or relative url to image file
  • NavigateUrl - The location to navigate to when the image is clicked, if you leave this out, clicking the image does nothing
  • AlternateText - The 'alt' text to be displayed on the image
  • Keyword - Specifies a category for the ad that the page can filter on
  • Impressions - A number that indicated the 'weight' of the ad in the schedule of rotation relative to other ads in the file. The larger the number, the more often it will be displayed

So this is really basic stuff, but something I've always ignored in the past. So if you want a way to display a discrete set of images randomly, this might be the ticket.

Thursday, October 20, 2005 7:07:15 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 

So I thought it would be cool, to create a page for my wife's web site, that would let me know how many people are on her site at any given time. This will be useful to know when it's OK to upload new code that would bring the site down. Don't want to upset our users! Since her site is on a shared hosting environment I don't have physical access to the box. So I created an admin page on the site that prints out the number of users on the site using this code:

 

//using System.Diagnostics;

PerformanceCounter PC;
PC = new PerformanceCounter("Web Service", "Current Anonymous Users", true)
PC.InstanceName = "";
Response.Write("Current Anonymous Users: " + PC.NextValue().ToString());


The first argument in creating the new PerformanceCounter is the Category of the Performance Counter (SQL Server, Browser, Server, Memory, Processor, etc.) The next argument is the item for that category (Current connections, Active Sessions, Current FTP Connections, etc.) The two things to know when doing this are to: 1.> Know the instance of the item that you want to monitor. The instance name is the name of the site in IIS, or if you were looking at CPU utilization, the processor, etc. You can find this data by looking in Perfmon, or by asking your service provider. 2.> On your PerfomanceCounter object PC in this case, call the NextValue() method to get the current value of the counter.

This is a pretty simple example of accessing the performance counters intrinsic to the OS.

Thursday, October 20, 2005 6:38:59 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Wednesday, October 19, 2005

Ok so on the reccomendation of a colleague here at work, I installed the MSN IE Tool bar, and the new Microsoft Anti Phishing plugin. I too get a lot of bogus emails phishing from Bank of America, US Bank, Ebay, Paypal, etc. etc. all of which I may have some sort of affiliation. I tend to ignore most of them, but every now and then, I'm almost compelled to believe that one is from a legitimate source. So I figured the plugin and toolbar instal could not hurt.

So I installed it, and wanted to see it work. Simple.... a quick trip to my Gmail spam folder (GMail does an excellent job of notifiying you of what it thinks is a spoofed or bogus email by the way) and there is an email from 'Chase Manhattan' - Oh no I need to reinstate my account... (What account? I closed it a long time ago...) So I figured this would be a perfect test!

I clicked the link, and it was painfully obvious from a technical standpoint. The link was going to some .br address, and was clearly nothing to do with Chase. The acutal page that rendered looked good, and if you were not paying attention to the address bar, it's easy to see how you could be duped.

MSN Toolbar INSTANTLY notified me that this was potentially a fraudulent site, and would not let me enter information. They even put a link in the notification bar to report the site. I thought to myslelf, cool... I'll help them out by agreeing with them and reporting the site. Then this screen came up:

Ok, first a quick explanation of what this is. It's called CAPTCHA, and it's developed to make sure a human is the one entering information into the form, and verifying that it's not a robot or some program doing it. I'm all for that, but this is absurd. Sure, when you really sit and work at it, I guess you can make the numbers and letters out... is that a 1 or an “l” at the start, or is is just noise? Is that a “J” at the end?

The short story? I didn't even bother trying, I've seen so many forms like this, and had trouble 'matching' their letters. I closed the page and said forget it. So here's a capture of a good implementation of CAPTCHA from Scott Hanselman's blog.

 

I'm no Microsoft basher, but you think they would be able to implement an easy, yet effective CAPTCHA implemenation.

 

Wednesday, October 19, 2005 8:55:18 AM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Monday, September 12, 2005

It's sweet.

I picked one up this weekend, oh man, the form factor is so dang cool. From the pictures online, it looks small, but wait till you hold one. Wow. Simply amazing. Some new coolness:
    * Color screen - view photos too! The 1.5” screen sounds small, but it's amazingly bright and clear.
    * Sync Outlook contacts
    * Sync Outlook calendar
    * Album artwork on screen

The 2 GB model is $199, and 4 GB is $249. The boxed version from Apple even comes with an adapter to retrofit your dock from a 'traditional' iPod allowing the Nano to work with your existing one. Apple thinks of everything.

Monday, September 12, 2005 7:53:02 AM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Wednesday, August 24, 2005

Wow is all I can say.  Sure there is Skype, and others... but Google Talk has a nice clean interface, and is simple.  I was up and talking in seconds.

http://www.google.com/talk/

Not sure if it integrates into the sidebar, but you should check it out.

 

Wednesday, August 24, 2005 8:17:29 AM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Tuesday, June 21, 2005

So, after only a few short months (man where does time go when you're so busy???), Live Organized is starting to get busier.  We recently spent a Saturday at the Cedar Hills Farmers Market.  For $30, let me tell you I can't think of a cheaper, more effective marketing tool.  Sure there were a lot of people milling about that were not even remotely interested in who we are or what we did.

But....

We met about 20 people that were interested.  And of those 20 people, we have about 7 hot leads!  Every night this we're doing estimates for people.  We landed a great closet job tonight, with a very charming couple.

We're doing another job this Saturday for a great lady out in Beaverton.

June is garage month.  There's no time like the present to tackle that garage project.  We'll even give you 25% off on your garage.  Free estimates, insured, experienced, and very competitive pricing (about 1/2 of what most competitors charge).  What more can you ask for?

www.liveorganized.com

 

Tuesday, June 21, 2005 8:18:46 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Monday, April 11, 2005

My wife has started a new business doing professional organization for residential homeowners, and small businesses.  Live Organized was recently formed as a Limited Liability Company (LLC).  For those of you that know my wife, you'll see the perfect fit for her in this business.  For those of you that don't, remember Monica from the NBC show “Friends”?  Well, that's her nickname.

I used to go around the house unstraightening the pictures on the wall, making the stack of magazines (decorative stack mind you) on the coffe table crooked, and all sorts of little 'tests'.  Within seconds of her entering a room where I had 'been', she would almost instinctively know that something was wrong.  She would locate the offending problem, and correct it almost minutes after I had done it.  It was quite the comical thing to watch.

But in all seriousness, I have worked hard to create a web site for her, complete with backend tools for content management, an estimate creation tool, customer tracking database, and other business tools.  I'm 100% confident she can make this a successful venture, and I plan to keep things updated here on the blog.

Tell your friends, tell your family.  She's already done several jobs.  It's amazing how revitalizing it is to get organized, and it's suprising how fast most jobs can be accomplished.



Check out the site, www.liveorganized.com (cool domain name, huh?)

Monday, April 11, 2005 8:09:40 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Monday, January 17, 2005

In the job that I do, I log in and out of web sites, applications, and other services requiring me to pass user credentials numerous times per day.  Not all of these web sites, applications, and services have 'remember me' functionality.  So when I heard about this product from Microsoft, I was skeptical, but thought -- if it really works, it would save me a ton of time.

So I ordered the Microsoft Keyboard, with wireless mouse.  I'm happy to say that it works flawlessly.  I will explain the whole process.  Installing the keyboard is as simple as plugging the USB cable into the back of the computer, and installing the mouse receiver unit's USB cable to the back of the computer.  I was a little confused as to why the mouse receiver can't be integrated into the keyboard, but I guess we can't have it all now.

The first step after installing the hardware is to install the DigitalPersona software.  This
is the software that is tied to the fingerprint reader, stores fingerprint profiles, and allows
you to manage your application and website fingerprint profiles.

Once the software is installed, you are required to enter your windows password.  Once you enter your valid NT password that matches the current NT profile, the software prompts you to enter your fingerprint(s).  It is suggested to do at least one finger from each hand, you can do all 10 if you want.

You start by choosing the finger you'll train by choosing it off a 'hand graphic' on the
screen.  Once you've chosen the finger, the software then tries to acquire four valid scans. After receiving 4 valid scans, you can finish the wizard, or train more prints from more fingers.

It took me about 1 minute to scan one finger from each hand.

Now the cool part.  I went to hotmail.com, got to the login screen and started learning how to associate web sites to fingerprint login profiles. 

At the hotmail login screen, you simply 'authenticate' the DigitalPersona software by pressing a registered finger to the reader.  Once it has recognized your fingerprint, DigitalPersona prompts you to name the profile, and even lets you choose the available form fields on the page, and the values you wish to enter, and the button you wish to press on the page, form, or windows application! I clicked OK, and then waited about 2 seconds, a new icon appeared in the upper right of the window, next to the maximize, minimize, and close controls.  Pressing my finger on the reader again, now logged me directly into hotmail.

This worked with network drive mapping, ANY website I've been to, and even win32 apps.  It's  very flexible and allows you to choose what fields to submit, and the action to perform the login.

 

The documentation recommends that you not use it for banking, or data that needs to be very secure.  From what I can tell the DigitalPersona software stores the profiles inte the current user's NT settings, and obfuscates the data.  So if your machine was compromised, there is a strong possibility of losing this data.  That being said, again, I don't think I would use it for severely critical personal data.

However with the touch of my finger, I can now post to my blog.

Pros:
* Huge timesaver
* Convenience Factor
* Not having to remember infrequently used usernames/passwords
* New mouse supports horizontal scrolling feature
* The wow factor

Cons:

* Does not work w/ firefox or other browsers other than IE (there HAS to be a fix coming for this -- WTF Microsoft???!!!)
* Does not work for windows NT login if the computer belongs to a domain (will work for logging into machines that are not part of a domain)
* Clunky interface for managing profiles once they are setup


 


 

 

Monday, January 17, 2005 11:31:38 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Saturday, January 15, 2005

Well we woke up to an interesting situation this AM, 1/4” of ice on our back deck, yard, house.... you get the picture.  Another fun ice storm has hit Portland.  I'm not sure of the outlook yet.  Hopefully it will be gone by Monday!  I'd post a picture, but it's so little ice that you can't even really tell it's there.

Saturday, January 15, 2005 9:35:10 AM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  |