pure mode, iis7 ?

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

pure mode, iis7 ?

Postby tleslie » August 6th, 2012, 3:59 pm

i have set up a phalanger project via the
http://wiki.php-compiler.net/Web_Server ... IS_7.5/3.0
and it works.
But I want to be in "Pure Mode", so i can get full integration,
and intellisense in vs2010. (with respect to my php compiles)
I don't see any way of setting this "Pure Mode", i have look in properties
in IIS7.5 control panel, the VS2010 properties windows.
I it pure by default in this setup? or is it somehow specified in the
web.config.

-tl
tleslie
 
Posts: 32
Joined: August 3rd, 2012, 4:42 am

Re: pure mode, iis7 ?

Postby Jakub Misek » August 6th, 2012, 4:26 pm

Pure mode is mainly targeted for executable applications written in PHP.

The other purpose of Pure mode is writing nice .NET DLLs in PHP, so you can reference them in C# in normal way, as any other C# library.

IntelliSense works for any kind of projects, even standard website mode. Pure mode just adds more restrictions.

Why do you want Pure Mode? I think you cannot enable it for websites, because in pure mode there is no entry script, and all script files are treated as single library, so you can only reference it from another .NET project.
Jakub Misek │ DEVSENSE s.r.o. | @misekjakubjakub@devsense.com
User avatar
Jakub Misek
 
Posts: 2092
Joined: January 4th, 2012, 2:42 pm
Location: Prague

Re: pure mode, iis7 ?

Postby tleslie » August 6th, 2012, 4:31 pm

I guess pure/standard mode really doesn't apply to php in a web solution, because you are not going to source a dll from this php. So I guess my question is not relevant? but it was asked because of the itellisense issue, ...
i guess the phalanger "add on" of itellisense will work in vs2010 editing a
php file in a web page solution, if one is referencing a c# class?

I am trying to set up a environment for a project where
we would use the mvc3 setup in VS2010, have phalanger as the view engine,
and use the recommendation you gave in my previous post of a c# container class to get a strongly typed class in php, that can have intellisense.
This would deliver the efficient environment i need (i hope?).

I guess I am just trying to set up a phalanger/php/c#/vs2010 environment that
works like razor does integrated into vs2010.

-tl
tleslie
 
Posts: 32
Joined: August 3rd, 2012, 4:42 am

Re: pure mode, iis7 ?

Postby Jakub Misek » August 6th, 2012, 10:09 pm

PHP WebSite works best in standard mode, Pure mode is not much useful here (you only have to use pure when writing code behind of .aspx page in PHP)

IntelliSense plugin probes current project for PHP files, and referenced DLLs/projects for additional symbols. So if you add a reference to DLL in your web.config into
Code: Select all
<phpNet><classLibrary><add assembly="MyReference" />
IntelliSense will load assembly 'MyReference' and will be able to use its symbols.

example

web.config:
Code: Select all
<phpNet>
    <classLibrary>
        <add assembly="mscorlib" />
    </classLibrary>
</phpNet>

index.php:
Code: Select all
$x = new System\Collections\ArrayList(123);
$x->...

You can reference any .NET DLL, IntelliSense will take it into account. You can declare strongly typed objects in your C# projects, then add a reference to them, and work with them in PHP taking advantage of IntelliSense.
Jakub Misek │ DEVSENSE s.r.o. | @misekjakubjakub@devsense.com
User avatar
Jakub Misek
 
Posts: 2092
Joined: January 4th, 2012, 2:42 pm
Location: Prague


Return to Phalanger project

Who is online

Users browsing this forum: No registered users and 22 guests

cron

User Control Panel

Login

Who is online

In total there are 22 users online :: 0 registered, 0 hidden and 22 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 22 guests