UIWebView Does Not Correctly Resize It’s Contents After Rotation

If you use UIWebView to display something on iPad® with landscape and portrait orientation enabled on your application, you should have been noticed that UIWebView does not resize its contents size correctly on some situation.

Indeed it is exactly when you try to first display your content on landscape mode and then turn your device to portrait orientation. Other alternative, displaying content in portrait orientation and then turning into landscape orientation works alright.

What causes this will be out of the scope of this post ı guess so I cut to the case and give you the solution. The solution is adding this line:

<meta name=”viewport” content=”width=device-width” />

to you HTML file and it will hopefully will be resolved. For you who is not using UIWebView in device wide frame, you should really consider following the links for more information.

I have found original informative article here and following the link in that I got better information here.

iPad is a trademark of Apple Inc., registered in the U.S. and other countries.

An Engineer’s Response to Anti-Piracy Regulations

(Originally posted this on Google+ but I would like to share it with you here, too.)


I have personal license for all the music in my music library. I don’t use pirated content and in my opinion no one should ever use pirated music for their personal enjoyment. I’m against the piracy of multimedia content in anyway. If you would like to listen a song I think most of you are able to buy that.

But what about the availability? I live in Turkey and I can assure you until last 2 years there was no legal way to download music from internet. I have a MacBook Pro 7.1 (Mid 2010), iPhone 4, iPod touch 4th gen. and iPad 2. Quite an impressive hardware huh? Beyond costing me a massive amount of money to get all these stuff, just ask me how did I found these in my country and the story will continue until morning. But my point is simple, I cannot download songs from iTunes®.(!?) Why? Because somebody said so. Music store is not available in my country due to high copyright infringement trough the whole country. But how can I get legal music in my taste then? You can suggest that I should look at local music stores and the second you say that I will know that you never came to my country. If you are able to find rare records on your taste in my country you’re one lucky son of a bitch. How about getting a single song not the whole album. Luckily, some DRM-free legal music download services came online I had a solution.

Another topic is price. I don’t mind using DRM protected content as long as provider solves the issues of backup and synchronization to multiple devices. But this is simply against the nature of DRM. I never give up my high quality (quality as in technical term, like 320Kbps) choices when ever I buy music but I’m really sorry but throwing my money to the street is against my nature, too. I think at this point you can make the connection why most of us hate DRM protected content. That’s also exactly why DRM-free content providers are on rise this era like Beatport. And why the hell is very well-known popular song which is the one everyone would like to get has the highest price all time. I think if you are really earning quite a large profit, you can make your albums cheaper, and quite fewer people will be likely to pirate your work. This was really what happened in my country. VCDs were like $1 for each if you buy pirated copy and they were about $15-$20 as their original copies in 2002. One year later, VCD prices dropped like hell, original one were like $5-10 and renting an original was like $2-3. How about pirated copies then? Well, there were so few that I don’t remember. It was a non-profitable condition for pirates and most of them abandoned their business. But guess what, now there are some Blue-ray videos on stores and they are expensive. I don’t think some one needs to be genius to figure this out.

Legal regulations on the internet enables internet censorship. Which is beyond the scope of music industry, piracy on the internet or any companies net profit. I’ve never accepted a boundary for me to learn something. I bought all the books I would like to read as much as I can. But for those who can’t, there is internet. And professionals like me share their knowledge on their blog, website or on a social network so your 15 yrs. old child can decide what he would like to do rest of his life, what his job would be and what he/she should do to get it. Information on the internet informs and inspires people. First reason for internet to be exist is that two colleges wanted to share information faster. HTML was here because of a group of scientist wanted to share their information which they gathered from their experiments.

And I’m saying, just saying to industries want to control internet. You did NOT created the internet, we (generally speaking of engineers, scientist and tech junkies) DID! You did NOT paid my internet connection bill, I DID! And when it comes to P2P systems and services, I’m pretty sure that you are aware of that, you did NOT engineered those networks, we DID (Although the intention was not pirating content in any way). I’m not accusing any one or trying to make a crime look more sympathetic but I think music industry should accept that their super hunger to money has a bad affect on piracy. If you try to censor our internet you can be damn sure about that we are going to build better systems again and again and in the end neither your industry nor the governments can have any affect on our networks. We did not build internet for piracy, but it is being used for. I’m sorry but giving a person standard swedish cutting knife to help him after seeing him trying to eat a watermelon with his bare hands neither does make guilty of his unlikely murders committed with that knife afterwards nor makes him a murderer anyway. As a computer engineer I’m willing to supply work force for a neutral network and freedom of internet. I’ll try to make a distributed, secure and general purpose network if these censorship action become a law. But, as I said earlier, I will be the one who supplied the technology (if I ever can) to help people like an engineer as I am.

No one should stay silence on the internet censorship subject. Also, no one should afraid of future with sentences starts with “What if…”. We; scientists, engineers, technicians, programmers, tech junkies are here for to help you. We will unite if needed and we will have more power than Voltron.

CTO, iOS Developer

%d bloggers like this: