phplist3 icon indicating copy to clipboard operation
phplist3 copied to clipboard

CLI: config file autodiscovery doesn't work as expected

Open jwindhager opened this issue 4 years ago • 4 comments

https://github.com/phpList/phplist3/blob/master/public_html/lists/admin/index.php#L68

I think lines 68 and 70 should be changed from:

$configfile = '../config/config.php';

to:

$configfile = dirname(__FILE__).'../config/config.php';

jwindhager avatar Nov 29 '20 22:11 jwindhager

Can you explain in what situation that change has made things work better?

michield avatar Nov 30 '20 09:11 michield

When calling the admin's index.php from command-line, with the change, the location of the config file (if not explicitly specified with -c) does not depend on the current working directory anymore.

jwindhager avatar Nov 30 '20 09:11 jwindhager

ok, sure, but that's what the -c parameter is for.

michield avatar Nov 30 '20 10:11 michield

If you want to submit a PR, you're very welcome. Please make sure to sign the CLA before you do.

michield avatar Nov 30 '20 10:11 michield

Resolved with #977

michield avatar Feb 24 '24 11:02 michield