When working with web server and 4DAction methods, make sure to explicitly declare the $1 parameter using C_TEXT($1) in order for the method to work properly when running in compiled mode as 4D requires this parameter internally. Otherwise, the 4DAction method may cause a "500 - Internal Server Error" when accessing the method via web server. Note the C_TEXT($1) declaration is only required in compiled mode and not interpreted.
Take the 4DAction method below when running web server in interpreted vs compiled:
|WEB SEND TEXT("Hello world")|
Interpreted (works properly):
Compiled (does not work without $1 declaration):
As mentioned before, this issue is fixed by simply adding the C_TEXT($1) declaration.
WEB SEND TEXT("Hello world")