Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fatal error: Cannot redeclare foo() (previously declared in....) #20

Open
ArunPatal opened this issue Jul 26, 2020 · 4 comments
Open

Fatal error: Cannot redeclare foo() (previously declared in....) #20

ArunPatal opened this issue Jul 26, 2020 · 4 comments
Labels
enhancement New feature or request invalid This doesn't seem right

Comments

@ArunPatal
Copy link

ArunPatal commented Jul 26, 2020

Hello,
I found a bug.
Executing a script first time with a function call foo run fines but executing same file again gives cannot redeclare foo() error until i restart c# app based server.
Am executing a code via php file URL.

i noticed that it is not only with user defined functions but also user defined constants & class

@resistancelion
Copy link
Collaborator

resistancelion commented Oct 31, 2020

Hello,
I found a bug.
Executing a script first time with a function call foo run fines but executing same file again gives cannot redeclare foo() error until i restart c# app based server.
Am executing a code via php file URL.

i noticed that it is not only with user defined functions but also user defined constants & class

There's a tickmark (or must be) for disabling PHP Caching, which normally will cache everything, that can be stored between PHP sessions.
The better advice is not to use this project at all, if you have a real task for it, then you can just write your own server in C++ and CGI i/o.

@resistancelion resistancelion added enhancement New feature or request invalid This doesn't seem right labels Oct 31, 2020
@ArunPatal
Copy link
Author

ArunPatal commented Oct 31, 2020

Hi, I am using it in c# windows app. Just for me :)

There's a tickmark (or must be) for disabling PHP Caching ???
I can not compile php4App.dll as i do not have delphi.

Am using php4App.dll file in C# project.
Can i disable cache via php.ini ?

I tried below code but it did not help.

[OPcache]
opcache.memory_consumption=128
opcache.interned_strings_buffer=8
opcache.max_accelerated_files=4000
opcache.revalidate_freq=60
opcache.fast_shutdown=1
opcache.enable_cli=1
enable=0

Can you please advise me how to resolve this issue..

@resistancelion
Copy link
Collaborator

Hi, I am using it in c# windows app. Just for me :)

There's a tickmark (or must be) for disabling PHP Caching ??? I can not compile php4App.dll as i do not have delphi.

Am using php4App.dll file in C# project. Can i disable cache via php.ini ?

I tried below code but it did not help.

[OPcache]
opcache.memory_consumption=128
opcache.interned_strings_buffer=8
opcache.max_accelerated_files=4000
opcache.revalidate_freq=60
opcache.fast_shutdown=1
opcache.enable_cli=1
enable=0

Can you please advise me how to resolve this issue..

Am using php4App.dll file in C# project. Can i disable cache via php.ini ?
Sorry, but - no, it can only be disabled within library source code.
Will look further in this project in undefined time, and for better - make some .json skeleton instead of those hard-linking style, so such an implementation like this can be easily ported to C# and other languages.

Sorry again for the late reply, our team decided to move this project to the team maintenance, but now i'm seiing that it is actually forgotten.

@ArunPatal
Copy link
Author

Hi, I am using it in c# windows app. Just for me :)
There's a tickmark (or must be) for disabling PHP Caching ??? I can not compile php4App.dll as i do not have delphi.
Am using php4App.dll file in C# project. Can i disable cache via php.ini ?
I tried below code but it did not help.

[OPcache]
opcache.memory_consumption=128
opcache.interned_strings_buffer=8
opcache.max_accelerated_files=4000
opcache.revalidate_freq=60
opcache.fast_shutdown=1
opcache.enable_cli=1
enable=0

Can you please advise me how to resolve this issue..

Am using php4App.dll file in C# project. Can i disable cache via php.ini ? Sorry, but - no, it can only be disabled within library source code. Will look further in this project in undefined time, and for better - make some .json skeleton instead of those hard-linking style, so such an implementation like this can be easily ported to C# and other languages.

Sorry again for the late reply, our team decided to move this project to the team maintenance, but now i'm seiing that it is actually forgotten.

I will be waiting, Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request invalid This doesn't seem right
Projects
None yet
Development

No branches or pull requests

2 participants