Tuesday, August 16, 2005

Testing MCE applications in 16:9 format

Today I found a great tip on Charlie Owens blog. He has a great blog with a lot of great tips for Media Center development. I have worked with a MCE project for some time now, and it works great on my 4:3 TV. But how can I test how the application looks on a 16:9 TV? Go to a friend and test on his computer...? No! Charlie Owen has the solution. He writes:

Do you want to test your extensibility application for widescreen compatibility without a widescreen monitor?

If yes, then...
Click Start => Run.
Type 'C:\windows\eHome\ehshell.exe /widescreen'.
Click the OK button.
Using the mouse, click the 'Restore Down' button to run Media Center in a window rather than full screen.

Voila, a 16:9 implementation of Media Center.


And to get it back to normal view:

With Media Center in a windowed mode use the mouse to click the Maximize button (which is in the same position as the Restore Down button when Media Center is full screen).

Saturday, August 13, 2005

Hide mailto links for spam bots

I have earlier written code to encode "mailto:" links in my webpages to hide them from spam bots. Recently I found a component on http://www.dotnet2themax.com that does this very easy.

SafeMailLink is a HttpModule for ASP.NET that prevents the action of spam bot software that search and extract e-mail addresses from Internet pages. Once it is set-up with a line in the site's web.config file, it dynamically encodes the "mailto:" links found on your pages at runtime, just before the HTML code generated by the page is sent to the target browser. Links with parameters that pre-fill the mail's subject and body fields (among others) are also supported and encoded correctly. E-mail addresses used as text for the e-mail hyperlink are protected as well. Full C# source code included.

The component is availible here.