Ehsan Tavakoli

Writing About .NET Programming and other stuff

Archive for the ‘tips’ Category

Browser-Specific Master Pages

with 5 comments

When you are trying to create a master page for your website, you may just wonder how can you make them that every user with any browser can call your pages up. No matter they are using IE or Firefox or even Opera on their tiny PocketPC.

You can easily design different pages for different container. How? By adding an attribute into master page property.

<%@ Page language="C#" MasterPageFile="~/Test.master"
      Opera:MasterPageFile="~/TestOpera.master" %>

You can find a list of available browsers on the production server where the application will be hosted at C:\Windows\Microsoft.NET\Framework\v2.0.50727\CONFIG\Browsers\

  • avantgo
  • cassio
  • Default
  • docomo
  • ericsson
  • EZWap
  • gateway
  • generic
  • goAmerica
  • ie
  • Jataayu
  • jphone
  • legend
  • MME
  • mozilla
  • netscape
  • nokia
  • openwave
  • opera
  • palm
  • panasonic
  • pie
  • webtv
  • winwap
  • xiino

Written by Ehsan Tavakoli

February 20, 2010 at 12:36 pm

How to set FireFox as a default browser in Visual Studio 2008

leave a comment »

I just found such an easy way to set Firefox as a default browser in VS 2008. I felt silly when I had to open Firefox by myself each time I was trying to debug a web site.
The solution? It’s piece of cake!

Right Click on your project name in Solution Explorer:

Click on “Browse with…” and then select Firefox as a default.

Here we go! 🙂

Written by Ehsan Tavakoli

February 18, 2010 at 1:05 pm