Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

manoj.aggarwal

macrumors newbie
Original poster
Aug 25, 2008
2
0
Hi,

I have made a web mobileapplication using visual studio 2005. My site is working fine on Blackbery and on safari browser but when I open my application using iphone, fonts of text and size of controls are coming very small on iphone. I am not getting where is the problem. :( .

I request everybody to help me out in this.
link to my site is https://rsguru.etelmar.net/rsgmobile/

You will see it works fine on browser when seen on computer but on iphone the fonts of text and size of controls are very small.

A lot of thanks in advance.
 
Same problem

Hi

I have the same problem :confused: and I want to know if you could fix it. Can you please let me know hao you corrected it?

Thanks!!! :)
 
This is by design and is under user control in MobileSafari. When the user rotates the phone the text becomes larger. When the user pinches/squeezes the web page the page zooms in and out. I can make your page so large that only a couple of lines of text appear on screen.

This is the same for all web pages. Why do you think this is a problem?
 
Hi,

I just did two things to solve my problem.

1. I added

window.document.attachEvent("load",fnmove);
var currentWidth = 0;
function fnmove()
{
setTimeout(updateLayout, 10);
}


function updateLayout()
{
if (window.innerWidth != currentWidth)
{
currentWidth = window.innerWidth;
var orient = currentWidth == 320 ? "profile" : "landscape";
document.body.setAttribute("orient", orient);
setTimeout(function()
{
window.scrollTo(0, 1);
}, 100);
}
}


setInterval(updateLayout, 400);


script to my application .

2. added <meta name="viewport" content="maximum-scale=1.0,initial-scale=1.0,minimum-scale=1.0"/> tag in my application .

it is working fine now .

A lot of thanks for your replies.
I hope it will solve your problem.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.