Page 1 of 1

compile php to Windows

Posted: Mon Dec 07, 2009 6:11 pm
by itp
I would like to take an existing web site that uses HTML, css, javascript (including ActiveWidget javascript library) and PHP5 and create an executable file for Windows, or at least generate an application that can be installed easily by users, and that does not require installing a Web Server to run PHP.

I have seen posts for Roadsend.com, bcompiler and others products/utilities that claim to compile PHP code, but I am not sure how they would handle HTML, Css and javascript. Would I have to re-write HTML and javascript logic in a Windows compatible language and then interface to compiled php?

What other options do I have?

thNKS!

Re: compile php to Windows

Posted: Mon Dec 07, 2009 7:13 pm
by Weiry
A quick google lead me to two. Google Search

PHP Compiler
WinBinder

However, one thing i have noticed, is none of them seem to be up to date with the latest version of php. And im not even sure they carry a database application like MySQL which the majority of PHP developers would use when creating a dynamic application. WinBinder does say that you dont require a database server if your using SQLite though.

Re: compile php to Windows

Posted: Mon Dec 07, 2009 9:47 pm
by Cirdan
Learn C# and .net. PHP, HTML, CSS, and Javascript were not designed to develop native Windows applications.

Re: compile php to Windows

Posted: Mon Dec 07, 2009 10:03 pm
by daedalus__
why do you want to do this? :|

dont stick with php if your reason is "becuz its all i kno"

c#/forms is the way to go if you want to develop a desktop application. you'll have to adjust to strong types and bounds checking, etc. but it is a valuable skill to have.

Re: compile php to Windows

Posted: Tue Dec 08, 2009 12:22 pm
by itp
I ask the question because I support an web-based medical information and diagnostic site.
Someone asked how hard it world be to convert to Windows desktop application.

I think options are a complete re-write to a Windows .net solution like VB,C# -or- install
Apache server and run locally on PC/MAC as web application. Initial tests of loading
Apache/PHP on MAC and PC desktops have proved very time consuming and complicated for
non-technical users. A re-write is probably out because it is likely a several month project.

Re: compile php to Windows

Posted: Tue Dec 08, 2009 12:41 pm
by califdon
itp wrote:I ask the question because I support an web-based medical information and diagnostic site.
Someone asked how hard it world be to convert to Windows desktop application.

I think options are a complete re-write to a Windows .net solution like VB,C# -or- install
Apache server and run locally on PC/MAC as web application. Initial tests of loading
Apache/PHP on MAC and PC desktops have proved very time consuming and complicated for
non-technical users. A re-write is probably out because it is likely a several month project.
The answer to your first question is: hard, very hard. As has been stated by others, the whole concept of HTML, CSS, Javascript, and PHP is to create platform independent web applications. To achieve the same, or even similar behavior as a standalone Windows application requires totally rewriting the application in another language.

I don't know why you had trouble installing Apache/PHP/MySQL on Max/PC/Linux platforms. It is very common and usually goes very smoothly. Often you can be up and running in an hour or so. Sometimes you might have a problem, usually due to misinterpreting installation instructions. I would definitely recommend this approach. If you have trouble installing the web server and PHP and database, if required, check back in here. We can help you through it. But ordinarily it doesn't even require outside help.

Re: compile php to Windows

Posted: Tue Dec 08, 2009 7:34 pm
by itp
I talked user through installation on a MAC. Apache and PHP were actually pre-installed on MAC, but first PHP had to be enabled in config file, which was difficult because config file was hidden, then we had to bring up servers and then user had to figure out where root directory was and how to point to to root directory using localhost URL. Not quite as easy as an auto-install Windows wizard.

I don't think that this is a reasonable deploy for non-technical users.

Re: compile php to Windows

Posted: Tue Dec 08, 2009 7:56 pm
by daedalus__
i don't think telling non technical people to install web server on their system is a good idea :oops:

what about a chm?

Re: compile php to Windows

Posted: Wed Dec 09, 2009 10:39 am
by JNettles
What I don't understand is why the client would be wanting to move to a desktop environment.... Typically companies want to move into the cloud, not out of it.

Re: compile php to Windows

Posted: Wed Dec 09, 2009 9:32 pm
by itp
what about a chm?
I don't thinks Microsoft Compiled HTML Help (CHM) would be enough. We have have some math functions in the javascript and php. It would probably require a re-write, which is something we would like to avoid.
Typically companies want to move into the cloud, not out of it.
Windows desktop applications still make a compelling case when you are not always connected to the WWW.

Re: compile php to Windows

Posted: Thu Dec 17, 2009 11:13 am
by JNettles
If you're programming for a desktop environment then I strongly suggest you use .NET.

Re: compile php to Windows

Posted: Thu Dec 17, 2009 12:05 pm
by Weirdan
There are several commercial tools available aimed to make offline web applications creation easier.