Src looked for at the wrong place (SOLVED)

Hi servage,

Now this is interesting and usefull.
Using your trick I was able to run successfully my test, as well as to see that the php exec() function is tolerated by exeOutput.

Many thanks !

PS : I had read the documentation.
If you look at the Global Variables page of the ExeOutput for PHP help (the one included in the software download), you will see the following definition (in the table entitled “List of pre-defined global variables”) :
"HEPHPDataPath : The path to the virtual cache folder used for PHP files."
You must admit there was no easy guess that “virtual cache folder” means the exact opposite, since in fact it doesn’t point to a virtual (compiled) folder but the real \Data folder.
Or there is something I didn’t understood about virtual folder meaning in ExeOutput.

You are very lazy man. You spent a lots of time to find trash software, but you dont read manual to this software :wink:

<?php $my_data_folder_beside_my_generated_exe_file=exo_getglobalvariable("HEPHPDataPath", ""); echo ""; ?>

Your file/folder structure should look similar, dependent where are your files.

Z:/myApp/myApp.exe
Z:/myApp/Data/my_beutiful_photo.jpg

and you distribute your folder Z:/myApp

Hi,

Thanks for your support.
Even if I find your choice regretfull, I still appreciate your effort and dedication.

For your information, I googled “ASP to exe” to see how that problem is handled by other “webserver to exe” solution.
To my great surprise, I stumbled upon a PHP compiler, precisly called “PHP compiler”, which can be found her :
http://www.aspdevelope.com/product_detail.php/pid/13681-5/pa/PHPCompiler

If you test it as I did this afternoon, you will find out that their solution properly handle the non-embeded local files, contrary to yours. In fect their very example, found in the downloadable demo, does exactly that : a dynamic image gallery. See by yourself.
I would say that their solution perfectly fit my need, except for two points :

  • their customers support seems inexistant ;
  • their solution gives bigger files than yours (in fact, their solution is not so elegant solution than yours.
    So my preference would go to your solution but only if you solve the non-embeded ressources access problem.

By the way, does your solution tolerate the PHP exec() function to non-embeded local exe files, which is also necessary to my project ? I have not tested it but do I guess correctly if I guess it doesn’t, considering your security choices ? (PHP compiler does).

Oh OK, I see your point and the solution you offer.

However, I question the security scheme altogether !
This is my point :
If I had a full wamp server on my system, I would be able to access local files (notably images) without any trouble.
How can your solution be stricter than the wamp system it pretends to emulate ?
Beside, it should be at least an option at compile time, not a strict enforcement.

I was expecting to use ExeOutput to bypass the need to use InternetExplorer activeX controles currentlyt needed to launch programs from a browser. If I cannot even display an source dynamically (apart using tricks), I doubt I will ever be able to design a real software in PHP using your solution.
I find it regretfull ; your offer has a great potential and rised great expectation ; it could be a real gem to develop windows programms out of PHP language ; something inexistant in the market today.

I hope that you reconsidere your position in the near future so that it’s full potential can be reached, other than making nice pre-compiled ebooks !

A WAMP package leaves source files outside the EXE, while primarily ExeOutput compiles them into the final EXE for easier distribution.
Note that you are PHP scripts can still access local files without any problem. I understand that you want the browser to be able to display image files that reside in the “Data” subfolder.
We’ll study your suggestion.

For security reasons, the internal server cannot access local files directly. Only PHP is allowed to do that.
In your case, you should write a simple PHP script that reads the local image file and returns the data with the correct mime type. We have a PHP sample in the General Demo (that ships with ExeOutput) that you can use: it loads an image file, performs a simple image modification and return the new image’s data to the browser that displays it with a simple call such as

Hi,

I have a problem : an src apparently cannot reach an image in the real “Data” folder, but only from remote ressource or from virtual exeOutput for PHP data.
I have the following structure :

Test.exe
Test.userpref
\main -> index.php ; virtualizedImage.jpg
\Data -> realImage.jpg

index php contains (among others !) a classic tag.

After compiling the “main” directory, which produces the test.exe file, the following are working :

But this one is not working :

Everythingh looks like ExeOutput for PHP is unable to reach for a real image in the real “Data” path.

I must precise that I understand image can be incorporated (virtualized) into the exe file at compile time, and I have good reasons not to pre-compile images in virtual data path : what I intend to do is an image gallery where image sare changing after compilation time. Very roughly, user will add images in the real “Data” folder and browse them using the compiled php script. Since images will change at any tyime it is not possible to include them in the virtual path before compilation.

Many thanks for any help.

Hello servage,
Many thanks too!