Improved temp dir creation
Added .htaccess copying