I want to develop a .Net Core web app that will run on mobile phones. This app needs to detect the mobile geo location for tracking the user location.
Both server and client sides of this app should run on the mobile phone; i.e. the server side is just a logic layer in the app, not a separate app. Since this should be a tiny app, I want to remove the need of maintaining a separate server and use the client resources for that, so all what the user needs is a mobile app without connecting to a server.
I understood that there is no currently GPS API support in .Net Core, so I thought to consume some web service for doing that.
I googled a lot but couldn't find such web service that I can use (without adding uncommon dependency that will have to be installed on the mobile as well).
Is this way a good practice? or there is a better solution? If it is- what web service can I use?
The .NET Core Web Application runs on the server side - the mobile phone is the client of your webapplication and will likley display the HTML result in the browsers. So to detect the GeoLocation you will use e.g. JavaScript and the HTML5 GeoLocation API.
<script>
function getLocation() {
if (navigator.geolocation) {
navigator.geolocation.getCurrentPosition(showPos);
} else {
alert("Geolocation is not supported by browser");
}
}
function showPos(position) {
alert("Lat: " + position.coords.latitude + " Long: " + position.coords.longitude);
}
</script>
Related
i am developing mobile application for one of my web app. After long search on google i found cordova to be the best for cross platform mobile app development. I am developing cordova based front end with ionic framework. I want to know which web service is the best one to communicate between mobile app & server. I am familier with REST for webapp but have no idea for mobile.
Note: My database is on server & i am communicating through web services only so no local database resides on mobile.
Thanks in advance for quick response.
Well angularJS with PHP & JSON object combination would be the best combination for the web services to develop for cordova application. Angular js used for cordova is the best to put at web service level too with PHP.
I found my answer after long search....:-)
I am setting up server for a group chat mobile application. It is a purely group chatting application i.e. each message will go to multiple recipients. Hence I am choosing HTTP over XMPP.
Also given my back ground in Python, I have started developing the server as -"Apache + Django + MySQL".
Please suggest if there are better alternatives. If the current set up is good enough then also let me know, so that i keep on developing peacefully.
How important is the server vs the app for you? Could you consider hosting the app on a cloud service? Since we are the developers of https://apptimate.io, the most secure point-2-multi point communication service, includung strong encrypion and other goodies, we would like to invite you to take a look att what we can do for you as an alternative.
If you use our backend service you focus on the iOS, Android or HTML5/JS part of the application.
I just started learning web services. In bottom up approach, I have found some examples without being deployed in any application server. I mean a standalone web service application.
Here is an example of such type.
I have also given a try and done a walk-through of deployable simple web service examples.
So far to my learning of web services, I got to know that firstly, bottom-up- approach is not recommended. Now, in bottom-up approach, this standalone web service. When is it applicable to follow standalone web service procedure?
Endpoint.publish();
I guess, this approach is provided just for beginners and not to follow as a real-time practice. Is my interpretation correct?
I would make my application as a standalone web service if it will have multiple clients like:
Web Client via a web browser
Mobile App Client
Desktop Client
Then I could build every one of them alone using whatever the technology I prefer, and make it consumes my standalone web service.
For example, You could imagine the guys behind Twitter started developing it by building their core system as web service, then they build an independent web interface application for it, then they built the Twitter Android and iPhone APP, and another one came and introduced a Twitter Desktop client like Tweetbot and TweetDeck ... etc
I'm using xamarin to develop an android APP and need to consume a webservice provided by others.I can consume the web service successfully in a ASP.NET application but in a mono for android app I always got a exception showed "NameResolutionFailure"...
I'm a beginer in mono for android, the following is the steps I try to consume a web service in a android app
Step 1: Add web reference:
Step 2: Consume the web service(http://www.citysupermarket.com.cn/MobileAppService.asmx)
AppService.MobileAppService service=new ServiceTest.AppService.MobileAppService();
service.CreateUser("test#gmail.com","123","victor");
I got a exception like this
Can anyone provide some suggetion about this or show me some guides about how to comsue a SOAP web service in a mono for android APP?
I really get stucked!
NameResolution Failure means that
http://www.citysupermarket.com.cn/MobileAppService.asmx \
can't be reached, Can you access the url at All ?
Regarding:
How to consume a web service using mono for android
I'll say this DOC is quite clear
docs.xamarin.com/guides/cross-platform/application_fundamentals/introduction_to_web_services
My friend has developed a recommend system in C++, now we want to make a web information system based on his work. As we both do not have no Web technology knowledge, I have some questions:
If we want to develop a web site which based on this recommend system, we should implement the recommend system in the application server and make a web server that could return the pages, right?
Then what web server we should use or use what technique to develop a web server to call the function in the recommend system? How the web server communicates with the application server?
Some web frameworks, such as Django, does it act as web server or application server or it is both?
As we have so much basic questions, do you have some books or website to recommend?
You can think of your C++ app as a service that your Django app can execute to return values to your users. You could easily execute any application on the same server as Django and capture the response or you could create a thin HTTP API and put your C++ app on its own server and call it by HTTP from your Django app to make requests for your users.
https://www.djangoproject.com/ is a great place to start.