Hai all,

I already created a portal with nearly 25 asp pages. How to convert this portal to a mobile viewable page? if I view that portal thro' blackberry, the total portal is scrambled. Any way to directly convert this portal. Any converter tool is available. Pls help

Thanx in advance


Nope there is no direct way as in general there are 3 types of mobile devices

  • without capability of internet access (old phones)
  • internet access, but no internet browser just simple parser (most of current phones)
  • internet access and mobile internet browser ( number of Windows CE based phones, some Symbian, Blackberry, HTC, iPhone etc. )

First group is out of loop as there is no internet
Second group will require simplified version of your web site based on WAP
Last group will be happy browsing normal page

Mine will come under lastgroup. But thro' blackberry, I am unable to view the page correctly. If I view google page, itz very compatible to the screen. But if I view my page, itz not fit in a single screen. What to do now?

Get (WURFL it needs PHP) or create browser/device detection algorithm and based upon this you can re-direct devices to your sub-domain specially designed for mobile devices

Your reply helped me to know how to identify the browser. But I am very new to this.
I found the solution in the following webpage

My question is how do I complete the code...the part: Whether I need to write a separate code for mobiles(???) and separate one for desktop browsers.

if($mobile_browser>0) {
// do something
else {
// do something else


As I mention previously you would do best if you keep mobile content in sub-domain (if your domain is for example seetha.com you should get sub-domain like mobile.seetha.com or wap.seetha.com DO NOT FORGET TO SPEAK WITH YOUR HOSTING PROVIDER SO YOU KNOW THEIR POLICY ON THIS). So once the script recognise incoming request it will directed user to seetha.com/home.asp or mobile.seetha.com/home.wml respectively. From this point onward documents in desktop domain are linked between each other, but there is no cross linking with mobile domain

i had to do a similer project recently... found this bit of code and modified it a bit

Dim user_agent, mobile_browser, Regex, match, mobile_agents, mobile_ua, i, size

user_agent = Request.ServerVariables("HTTP_USER_AGENT")

mobile_browser = 0

Set Regex = New RegExp
With Regex
   .Pattern = "(up.browser|up.link|mmp|symbian|smartphone|midp|wap|phone|windows ce|pda|mobile|mini|palm|mobi)"
   .IgnoreCase = True
   .Global = True
End With

match = Regex.Test(user_agent)

If match Then mobile_browser = mobile_browser+1

If InStr(Request.ServerVariables("HTTP_ACCEPT"), "application/vnd.wap.xhtml+xml") Or Not IsEmpty(Request.ServerVariables("HTTP_X_PROFILE")) Or Not IsEmpty(Request.ServerVariables("HTTP_PROFILE")) Then
   mobile_browser = mobile_browser+1
end If

mobile_agents = Array("w3c ", "acs-", "alav", "alca", "amoi", "audi", "avan", "benq", "bird", "blac", "blaz", "brew", "cell", "cldc", "cmd-", "dang", "doco", "eric", "hipt", "inno", "ipaq", "java", "jigs", "kddi", "keji", "leno", "lg-c", "lg-d", "lg-g", "lge-", "maui", "maxo", "midp", "mits", "mmef", "mobi", "mot-", "moto", "mwbp", "nec-", "newt", "noki", "operamini", "palm", "pana", "pant", "phil", "play", "port", "prox", "qwap", "sage", "sams", "sany", "sch-", "sec-", "send", "seri", "sgh-", "shar", "sie-", "siem", "smal", "smar", "sony", "sph-", "symb", "t-mo", "teli", "tim-", "tosh", "tsm-", "upg1", "upsi", "vk-v", "voda", "wap-", "wapa", "wapi", "wapp", "wapr", "webc", "winw", "winw", "xda", "xda-", "opera mobi")
size = Ubound(mobile_agents)
mobile_ua = LCase(Left(user_agent, 4))

For i=0 To size
   If mobile_agents(i) = mobile_ua Then
      mobile_browser = mobile_browser+1
      Exit For
   End If

If mobile_browser>0 Then
End If


you will need to detect the client device and then redirect to your sub domain and most importantly you need to rewrite all code for the display logic but still you can use your existing code for programming.

You will be required to use Mobile controls for you application interface.

This article has been dead for over six months. Start a new discussion instead.