recognize whether a page is for pc or mobile device? - html

I have a list of URLs and I am going to recognize if the URL is for pc or mobile.
the HTML page of the URLs have the certain mark for pc or mobile ?

There is no distinct way to recognize by certain URL whether website this URL pointing to is built for a mobile devices. There is no way even to recognize whether URL points to a website, it can be some resource, service, etc.
Some websites do not aware from type of the client, another have their own rules, for example, they can use subdomain like http://m.domain.com/. A large part of websites use Responsive web design, having thus common content for any client type.
But there is no common rule or standard.

Related

social network share links not working on desktop (fb://... whatsapp://...)

When I use this kind of links
fb://sharer.php?u=...
whatsapp://send/?text=...
They work perfect on mobile devices, because the related application is opening (facebook or whatsapp) and ready to share the URL.
But when the links are clicked from a desktop computer, as the applications don't exist there, they are failing and returning an error page.
I would like to solve it using an elegant solution, for example, changing the links:
fb://sharer.php?u=...
Into:
https://www.facebook.com/sharer.php...
Which should work in desktop computers...
But to do that I would need a good way to determine which kind of device is visiting my website.
Is there a popular/working way to determine the visitor device? How would you fix it?

Is there a way of showing an specific html file for my webpage depending on the users location?

I´m developing a webpage and it has some entries in which it would be interesting to force my web server to show an html file not only autotranslated (mainly between english and spanish) but also to load the specific social media links which are created in those languages (as there is an English Instagram version and another Spanish one, an English Twitter account and another for Spanish, and so on), depending on the physical location of the webpage users.
Thanks in advance.
In principle you could detect the location. But I am guessing that what you really want is to detect the language of the user. For this there are multiple ways, see e.g.: JavaScript for detecting browser language preference

Need a mobile friendly website working exactly the same functionally as the one which is online

I work for telecom company in India. My work involves checking the connectivity of the network through IPs and the ping through it. Our company has a website http://117.239.43.170/ping_select.aspx for it. The problem is the website isn't mobile friendly and I need to zoom in and out every time I go to that site. I am familiar with the basics of front end. I have created the mobile friendly version of that website and stored it in my mobile, but it is redirecting me to the same website. So my question is, is there any way I can use a mobile friendly version of that website and still get the same results
I recommend you making an android application and control (send and receive) the website in the background. This website uses a HTML form and very few inputs so it wont be that hard to go with the java staff.
Alternatively you can make a browser plugin for your phone browser to control the website in background and at the front end you get your desired UI.
I guess you dont have the access to upload your website to that server so you cannot request to your BSNL server from a local website (or whatever else). The BSNL server wont allow cross server requests. The best bet you can make is layering below that website over any other programs.

Responsive, Adaptive. A method of serving up 2 or 3 websites

I'm new to dealing with responsive website design but from what I have dabbled with its showing some great results.
I was wandering if some responsive experts can give some advice on serving alternative websites based on a mediaqueries for certain devices
Scenario A : If person a is using a desktop computer, serve this website to that device (HTML page 1)
B) If person is using a tablet, then serve mobile website. (HTML 2)
But I will go further to say, Can you use this sort of method to deal out completely different html pages? eg mobilehtmlpage.html desktop.html if that makes sense?
Thanks for your help!
You'll need to check to see what the "Web User Agent" is set to. This is basically the name of the browser.
You can do this in PHP like this: http://php.net/manual/en/function.get-browser.php
Here's a list of User Agents: http://www.useragentstring.com/pages/useragentstring.php
Once you check the User Agent, you'll be able to redirect the user based on this information (for example - subdomains: mobile.mysite.com and www.mysite.com). A lot of websites do this.
OR You could make a website that looks good regardless of the width of the browser, meaning you wouldn't need to redirect the user or know the user agent. This is my preferred method!

Displaying the website's content (html) through the specific browser - is it possible to realize?

I'm interested is there a possibility that could allow to display website's content or to say exactly an HTML through a specific browser installed on the web server?
I mean something like a module for a web server may be, that can display the website's content through the built-in browser, ignoring the clients browser?
If this possibility really exists, so I don't need to adopt my HTML to different browsers.
No, there isn't any web server module that takes control over the client's computer.
Depending on your situation I suppose you could replace the HTML page with Flash, Silverlight or a Java applet if that would make things easier.
Well, you could make some pdfs or images if you really want a specific rendering, but it's really not a website anymore at that point. You could also beg your users to use a particular browser, but they'll probably ignore you. The world spends (wastes) gazillions of dollars on good, standards-compliant HTML and CSS for a reason.
How about a browser in a Java applet?