Question

I was just given the task of PUTTING messages onto a Azure message queue with PHP. Given that I'm new to PHP (brand new) - does anyone know of any resources I can use to get rolling with this?

I also have to add data to blob storage within Azure using PHP. I'm assuming I can do this with standard connection strings and IO, right?

If anyone has any pointers I would really appreciate it. Thanks for your time,

Was it helpful?

Solution

Your easy track here is to use the Windows Azure SDK for PHP. THis project is co-funded by Microsoft butis comunity led by one of my fellow MVPs.

http://phpazure.codeplex.com/

It provides not only the tooling to run PHP on Azure but also the client library wrappers you'll want to connect to Azure storage. The Storage APIs are pretty accesible if you want to roll your own REST service calls, but, this makes things simple for you.

It should be as simple as calling the putBlob method. The SDK will wrap up all the complexity of block based upload for large blobs.

$image = $blob->putBlob(<container>, <blob name>, <local file path>);

OTHER TIPS

In June 2012, a new Windows Azure SDK for PHP was introduced, and is available on github. You can also visit the Windows Azure Developer Portal for PHP and download the installer, rather than source. The readme has examples for queues, blobs, and tables.

For getting started with the new PHP SDK, I'd suggest taking a look at the Windows Azure Training Kit. Af of the June 2012 edition, there are now PHP examples. None with storage yet, but they show how to set up your project, publish it, etc.

Going forward, this is the officially-supported SDK for PHP from Microsoft.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top