Simple PHP Application

Discussion about the open-source Phalanger [?] project.

Simple PHP Application

Postby lllSpylll » August 20th, 2012, 9:43 pm

I'm trying to compile a PHP library in .NET so it can be used in one of my .NET projects.

The code is very simple, but when debugging it in Visual Studio, the output of the function "explode" doesn't return the correct result.

Here's the PHP library I'm trying to compile:

Address Standardization Solution -- PHP 5 Edition
http://www.analysisandsolutions.com/sof ... -0.tar.bz2

1) I extracted the library, created a Class Library Phalanger project and set it to pure mode.

2) I created a file in my project called Library.php with the following contents:

<?php

[Export]
class Library
{
function __construct()
{
}
}

?>

3) I wrote a unit test that does the following:

object foo = new AddressStandardizationSolution().AddressLineStandardization("123 Main Street");


4) In the source code (AddressStandardizationSolution.php), there's a call to $parts = explode(' ', $address); I'm expecting it to return an array with 3 elements ["123", "Main", "Street"], but it returns array with 0 elements. I'm assuming there's something wrong here with my setup, but I can't tell what I'm doing wrong.

If anybody can help me, I'd appreciate it a lot. It should work, but doesn't.

Thanks for any help you can provide.
lllSpylll
 
Posts: 1
Joined: August 20th, 2012, 9:30 pm

Return to Phalanger project

Who is online

Users browsing this forum: No registered users and 15 guests

cron

User Control Panel

Login

Who is online

In total there are 15 users online :: 0 registered, 0 hidden and 15 guests (based on users active over the past 5 minutes)
Most users ever online was 256 on March 28th, 2024, 9:42 am

Users browsing this forum: No registered users and 15 guests