When visiting that page it would actually create an empty config file. To fix the issue, I copied the config file from my http://example.com/ directory to the http://example.com/wordpress/ one, it works fine now.
When visiting that page it would actually create an empty config file. To fix the issue, I copied the config file from my http://example.com/ directory to the http://example.com/wordpress/ one, it works fine now.