That way, WP just inherits the environment required by Moodle without any issues.
Working for me!
And you used SSL in your Moodle site?
Both sites has there own domain or just Wordpress?
Both use SSL, absolutely!
I can't imagine that your web hosting provider doesn't supply a FREE SSL certificate in today's market. I would check with them, if that's the issue you are concerned about.