I’ve been running a series of polls as research for a new conference talk that I’m currently putting together. The first two polls have had over 1,200 votes between them so far, which is a fantastic response! Now I just need your help with one final poll 🙂

Please vote on twtpoll to let me know where will you get your PHP 5.3 from? Many thanks in advance!

Be the first to leave a comment »

A huge thank you to everyone who voted in my last poll about when you’ll adopt PHP 5.3, and everyone who has provided feedback on the problems caused by the way individual distros package PHP. I’ve had much more feedback than I could have hoped for! This is all useful research for a new conference talk that I’m preparing.

My next question for the PHP community is about where you’ll use PHP 5.3. I’m wondering: which server platforms you’ll choose to put PHP 5.3 on when the time comes? This new poll is multi-choice, allowing you to vote for all of the operating systems that you choose.

Many thanks in advance for your answers 🙂

Be the first to leave a comment »

As part of the research I’m doing for a new conference talk, I’m running a poll to find out when people are planning to switch to PHP 5.3. After the very slow uptake of PHP 5.0, I’m very curious to see how quickly PHP 5.3 will be adopted.

Many thanks!

Be the first to leave a comment »

I’m putting together a new conference talk, and I’d like your help and input.

Most Linux distributions ship with packages for PHP, but not everyone is happy with these packages. If you’re not happy with the PHP packages for a specific Linux distro (no matter how obscure), I’d love to hear what you think the problems are and (if possible) what the correct solution should be.

If you have something to say on this, please leave a comment below.

Be the first to leave a comment »

Came across a second Microsoft-sponsored competition aimed at showcasing PHP on Windows. This one is for Canadian residents, and is headlined ‘The Ultimate Coder Battle‘. The premise is quite interesting: one student and one professional developer will be the chosen finalists, and they will battle head to head at the “Make Web Not War” conference. The winner walks away with substantial cash prizes – $5000 with another $5000 in bonus awards available. Entries close 3rd June.

After many many years of pushing ASP and ASP.net, I’m finding it fascinating to watch Microsoft push Windows as a viable platform for publishing PHP applications. Although PHP apps on Windows have been viable for many years (provided you ditched the fundamentally-flawed ISAPI approach and stuck with the slower-but-stable CGI route), I think it’s great to see the improvements that are being made both to PHP and IIS. From personal experience, I know it can be very difficult to sell PHP-based apps into organisations that choose Windows; being able to point at Microsoft’s support for PHP is a good thing for the ISV community.

Be the first to leave a comment »

This is one of a series of blog posts about my experience competing in the European WinPHP Challenge 2009. Sponsored by iBuildings, Microsoft and Leaseweb, competitors are asked to build a PHP app for Windows Server 2008 and IIS 7 to showcase the FAST in FastCGI. The winner gets travel and tickets to Microsoft MIX 2010 in Las Vagas in March. My entry is Give It A REST , a SOAP <-> REST gateway.

My first problem to solve in R&D is simple: given a (possibly remote) WSDL, how do I create a piece of compiled .NET code to call the described web service? The last time I did any regular Windows development was back in the Win16 days; this is going to be quite a steep learning curve for me.

Finding The Relevant Microsoft Tools

MSDN – Microsoft’s Developer Network – is (AFAIK) the place to go to find Microsoft’s documentation for software development. Clearly, there is a lot of information on MSDN. But how do I quickly find what I need to know … when I don’t really know exactly what I’m looking for? This is a substantial weakness of the MSDN site.

In the end, I had best success using Google to search MSDN. It’s also worth looking at information provided by your SOAP service vendors; Netsuite (for example) publishes a very clear walkthrough of how to do exactly what I need to achieve too.

Introducing wsdl.exe

The .NET framework ships with a command-line tool called wsdl.exe. In my Windows Server 2008 install, it can be found in C:Program FilesMicrosoft SDKsWindowsV6.0ABin. It can do all sorts of useful things, but at the most basic level, it can create a C# source file from a (possibly) remote WSDL file:

Using wsdl.exe

If there are problems validating with the WSDL file, they appear in the output to the screen:

Example Errors Displayed By wsdl.exe

This is something I’ll need to make sure I support in the final app, where wsdl.exe will be called automatically from PHP.

As expected, it takes a few seconds for wsdl.exe to complete. The length of time depends on the time it takes to download the WSDL file and the complexity of the web service described. Rather than do this from front-end PHP code, I’ll need to trigger this from some sort of backend queue to ensure the best quality user experience. This is something I’ve anticipated, and it’s already on my R&D todo list 🙂

Examining the .cs File

I’m very pleased to say that wsdl.exe generates a single C# file containing all of the classes required for the SOAP client. That really makes my life a lot easier 🙂 It also illustrates why having auto-generated SOAP clients is so important: the C# file for the Netsuite 2009 SOAP service weighs in at a “mere” 186796 lines of code!

Autogenerated C# SOAP Client Source Code

Can you imagine having to create that by hand?

Compiling The SOAP Client

To compile the .cs file from the command-line, I need the .NET framework compiler, csc.exe. On this fresh install of Windows Server 2008, there are multiple copies of csc.exe to be found; one copy per installed .NET framework. The latest version (and hopefully the best version to use for this project) is in C:WindowsMicrosoft.NETFrameworkv3.5.

Creating a basic DLL (dynamic link library; roughly similar (but not quite) to a Linux .so dynamically-loaded library) from the auto-generated C# source code is very easy:

Compiling A SOAP Client By Hand

The result is one Windows DLL file. My next step is to figure out how to call this from PHP.

Be the first to leave a comment »

This Month

May 2009
« Apr   Aug »