I'm building a web application (based on Phonegap) optimized for iPhone. I have to integrate a popup which will open our twitter page and shouldn't fit to entire screen (for a simple navigati开发者_Python百科on problem..how do a user should go back at full screen??).
I've noticed that Safari Mobile opens correctly the new page but ignores my window.load width/height parameters.
This is the incriminated js code :
var twitterLink=$("#twitter a");
var url="http://mobile.twitter.com/test"; twitterLink.click(function(){ window.open(url,'name','(height=200),(width=150)'); return false; });
I've just tried all other browsers on leopard and work! My aim was embedding a Twitter Profile Page in the fastest way in a page of my app (which has a navigation bottom bar). This morning I've tried with IFRAME , but with no luck...are not supported.. Then i've tried with the new Twitter intent but has the same problem as here in safari Mobile (ignoring parameters of popup)
Thanks a lot!!!
I think that's a known bug of Mobile Safari.
By my knowledge window.open accepts parameters without parentheses, so:
window.open(url,'name','height=200,width=150');
this should work.
精彩评论