Site design testing - cross-browser

What websites and/or tools do people use when they make a website design and want to make sure it will look and function the same on say an ipad and all mobile devices as well as all desktop (pc and Ios) browsers.
So say I make a website design. Of course I can test what it looks like in chrome, IE and Firefox on my desktop but how can I test to make sure it looks the same in say an ipad or a nexus tablet without buying one. Which VM provides specialize in doing what I need?

You can write some Selenium tests and run them under different browsers on different platforms. Passing tests will ensure your site is functioning property.

Learn about media queries and measure metrics ( dpi, vw and so on... ) it is pretty easy when you understand this. Easiest way is with resolutions...

You can open developer panel (Chrome f12) -> Toggle device toolbar -> Responsive
See screenshot

Related

Why do my web apps look different when they're being viewed on a phone?

Link to app
I've written the media queries to make the app responsive and they looked fine when I'm viewing them via Chrome DevTools. First screenshot is from Chrome DevTools, second is from my iPhone X:
Iphone X has a screen size of 325x812, which is the first difference.
Secondly, G Chrome Dev is an emulator, which means it only simulates what a page will look like on a specific device. It does not account for hardware and software (say which browser you're using). They use different rendering engines, so deviations are bound to occur.
I checked the URL, you are using react to make your page responsive which takes care of your application to be visualize properly on all the screen size.
You have design correctly only, you don't want your users to open desktop view in mobile.

Which tool should I use for responsive web development: Chrome web developer tool or simply resize the window?

I have been trying to make a responsive website for mobile devices . I have found two ways to test responsive design:
By resizing the window
Using Google Chrome developer's tools
In both of them I get a different view. Which one gives me the right view, as I use font-size and padding in 'em'.
Resizing browser window is not Responsive. While developing Responsive applications the easiest, but yet not perfect, way is using Chrome's Developer tools. Even that may give you different results, because mobile device screens are using not just width/height but also dpi. So 320 iphone6s screen is not going to be perfect match for 320px resized browser or equivalent android device.
Go for chrome developer tools. It's a great way of checking responsiveness. It comes with dimensions of popular mobile and tablet devices. So you can check for a variety of device at once.
Simply resizing the browser is not a right way of checking responsiveness.
Recently I built a page that works fine with both the ways you mentioned. You can check it here.
Let me know if you need any help.
I would say Chrome Dev Tools is the best bet for a local snapshot.
However, if you have access to one or more mobile devices you may want to launch the site on Heroku or another production environment and view it from the actual device.
An iPhone 6 for example, I find Chrome does not take into account the address bar or bottom nav in safari so things can be slightly off from the Chrome Dev view of iPhone 6.

How to test html file for mobile responsiveness

I need to test an html file for mobile responsiveness, but all the resources I have found to do this need a URL or a localhost, is there any way to test responsiveness with just an html file?
Yes, simply open the .html file with Chrome or Firefox. These browsers have device mode.
You can change the screen size and see how it looks on mobile or tablet sized screens.
If you save your file .html you can open with firefox or chrome, but i suggest you to use firefox developer edition https://www.mozilla.org/it/firefox/developer/
If you use Firefox you can put in the menu -> development -> flexible display (ctrl+shift+m)
In Chrome (ctrl+maiusc+i + emulation)
In this page you can select the device to view.
You have a lot of options to test it, but each option has it's benefits.
You can minimize the browser!
You can use device mode from chrome,mozilla etc
You can find a lot of online responsive site testers for any resolution you want
In my opinion, the best way to test responsiveness is in Chrome. Right click on the page and inspect. Then there will be a button to turn on responsive testing. You can choose the device to see how your page will render on all kinds of devices. This is better than resizing your window because there are slight differences in how pages render on different tablets and phones.
There is nothing like using a real phone. As an example, px sizes differ between various phones and can cause troubles. The height of the URL bar comes into play in vertical flex scrolling when the display occupies 100%.
To do this kind of testing, you can use tunneling - products like https://serveo.net/ or ngrok.
I use http://www.responsinator.com
Very easy and complete, several types of mobile and table devices.

Only show webpage to mobile browsers

I've got a html5 website/webapp. I only want people to view this website/webapp from their mobile phone i.e. iphone, android, blackberry.
If they try to visit the website/webapp from their desktop browser, It should display an error message as the website/webapp is only meant for the mobile phone.
Is this possbile? any tips?
Thanks
There's no way to check for sure wether a site is on mobile or desktop. HTML is made to be device agnostic.
you can do browsersniffing BUT
user_agents are easily changed in several browsers
you need to make sure to keep your user agent->mobile/desktop mapping up to date
you could do mediaqueries and conditionally display a query that way, but with the large array of formfactors available today there's no clear line to draw that way either.
Both methods will be prone to misidentification.
Quite Frankly, I'm kinda puzzled why you would want to prevent people from accessing your site. Why do you care if someone accesses your site from a desktop instead of a mobile device?
A site designed for mobile will work on a desktop just fine (it's the other way around that might be problematic)
Grab the script for the language you prefer from here:
http://detectmobilebrowsers.com/
Works for me.
You could use media queries, on the page and check the device width on which the page is width. Say if the page is viewed on Desktop, You can show a Message that this App is compatible with Mobiles Devices only and Not Desktops. similarly this should apply for tablets as well and this message can be customized.
Are you using any serer side technologies (ASP.NET, PHP) to generate the page? If so, you can perform your logic on the server side and return different content (like your message) on the desktop requests.
This is usually done by reading the user-agent. Are you ok with a desktop user over-riding their user agent to simulate a mobile browser and viewing the mobile content?

mobile browser simulator

I have started coding for mobile browsers (i.e. iPad, Galaxy Tab, etc). For a starter, I don't have budgets to get all the tablets for testing (I wish I do :D). Anyway, I am looking for a decent mobile browser simulators. I have looked into Ripple (only works in Chrome), MobiOne, and PhoneGap simulator. But all of these are not that up to par. Can someone recommended a decent one? and it will be great if it is also open source.
Thanks in advance
A good list of emulators and simulators are here: http://www.mobilexweb.com/emulators
For iPad, the only simulator I know of is built into XCode when you compile or run. You have an option of previewing in iPhone or iPad, and though the screen is hard to read, it's manageable if you click on 2x button.
If you're developing for android, the Android SDK has one.
http://developer.android.com/sdk/index.html
if you just want to quickly view how a webpage would render at various mobile device resolutions then here is a nice little webpage...
http://synthphone.com
you can even link directly to a url via query strings. for example, here is one that should load the Sencha Touch 2 carousel. Use your mouse like a finger to slide around the images etc.
http://www.synthphone.com/?u=http://dev.sencha.com/deploy/touch/examples/production/carousel/index.html
have fun!