4D 2004 now allows you to set preferences programmatically with the command SET DATABASE PARAMETER. Documentation for this command can be found here:
The selector for web logging is 29. You can either pass a 0 or 1 for the value. 0 turns off the logging and 1 turns on the logging. Along with executing the command with a selector and value, a restart of the webserver will be needed in order for this preference to take effect.
For instance, if the webserver is currently running with logging on, to turn it off you would do the following:
-Set database parameter to disable logging.
-Stop the webserver
-Start the webserver
The logging should now be off. If you view the logweb.txt file, there should not be anymore new entries added.
Other related Tech Tips:
https://kb.4d.com/assetid=44224 -Enabling Web Requests (GUI)
https://kb.4d.com/assetid=38115 -Web log location on 4D Client