I was able to setup WebSocket on Azure.WebSockets enabled on Azure
But my issue is : how to start the PHP ws server?
I have used this sample implementation https://github.com/ghedipunk/PHP-Websockets successfuy on my computer but I am not able to start the server in MS Azure.
All Azure Web Apps run in a secure environment called a sandbox. In the sandbox, each app is processed by Microsoft IIS. An app runs through PHP's Command Line Interface (CLI) is not allowed. For more details, please refer to Azure Web App sandbox.
In order to be able to run PHP-WebSockets in Azure, you need to host in something like a Virtual Machines, Cloud Services, or Containers, rather than Web Apps.
Related
I have a Windows Azure VM running IIS/PHP. I have mapped an Azure file share to the VM. PHP always returns false when running is_dir('//server/share'). How can I map the Azure file share so that PHP can see it?
I was able to get PHP to see the mapped drive by adding the Azure storage account as an admin user on the server and using that account to connect as under basic settings for the web site under IIS.
See: Access mapped drive by IIS running asp.net mvc web application
Can I use the Azure web app service for PHP and NodeJs both in the same application?
Following are my PHP Web app requirements. So can I used the Azure Web app service or need to deploy it on LAMP stack VMs only?
You can use Virtual Applications to achieve the functions you want.
Prompt:
You web app should use windows platform.
The main application cannot be a nodejs application.
Ensure that each application can be deployed successfully (to ensure that the application can run normally), learn to use the web.config configuration file.
I am new in Azure. I want to develop a web application on Azure. i am a bit confused about one issue. Should i develop the application locally and then deploy it to Azure ? or should I develop the app directly on Azure ? Could anyone please guide me on this issue ?
As #David Makogon said, you can either develop applications on local then deploy it to Azure, or you can directly develop your applications on Azure. They are all workable on Azure, that depends on you.
Generally, you need to create services on Azure, i.e. Web Apps to host PHP applications and ClearDB (MySQL services on Azure) to store your MySQL data. To create the PHP + MySQL sites services on Azure, you can see steps on How to create server on azure and host php,mysql site on that on stack overflow.
If you have an application on local, you can deploy to Azure via GIT or FTP. You can refer to Create a PHP-MySQL web app in Azure App Service and deploy using Git and Create a PHP-MySQL web app in Azure App Service and deploy using FTP on official site for deploying your local application on Azure Web Apps.
Also you can leverage WebMatrix directly remoting to applications on Web Apps and develop your applications.
I am new to android development. I have a module where I need to connect to a webservice via an android application. I have the web services in my localhost.
My question is: How to access them from my android application?
Tutorials on web says how to access the live web services.
First, both your computer and android device need to be in the same network,
If you use windows, go to cmd and type ipconfig /all
Find your computer's ip address
Then you will be able to access your server's from its ip address.
You can also check your firewall configuration if steps above don't work
i have did this before ,first of all , if you need to connect your android application with php service at localhost.following thing need following thing
Android Emulator on which application install
For SERVER -- WAMP or XAMP Server install on Local machine on which you are testing .
now host your php service in the www folder (in case of WAMP) or in the htdocs folder( in case of XAMP).
Now how to communicate between web service and android : as describe below
Now you have Envoirnment set now all you have to do is to follow this tutorial it will definatly resolve your issue .
http://www.androidhive.info/2012/01/android-login-and-registration-with-php-mysql-and-sqlite/
Is it possible to create an environment on local machine( i.e. localhost) where we can create and consume web service using PHP?
Is there any flow to create a web service like environment on localhost?
I would like to create an environment on localhost for web services where local machines, on intranet, get connected to main server (here again it's local machine) and can consume web services.
Like on internet we have Web Servers from where we can create and consume web services, Can we do the same on localhost?
Edit:
I am using WAMP with
PHP 5.3 Apache 2.* MySQL 5Windows 8
It is easy to create a local web service. You will need a local web server (like IIS or xampp) to execute PHP locally.
Access you PHP application in your browser using http://localhost/<yourApp>.php and provide any webservice at a local URL as well, e.g. http://localhost/<yourService>.php. Your application can then access the webservice using the local URL.
This works both for REST or SOAP-style services.
EDIT: Your edit shows that you already set up a local environment to develop and test webservices. You should really be more specific in your question, maybe you are looking for a tutorial to create web services with PHP in genereal. If so, Google will be your best friend: https://www.google.de/#q=create+web+service+using+php+tutorial