Httpclient post not working in angular device but its working in browser

Hi,
finally i fixed the problem by installing CORS from below link
https://www.iis.net/downloads/microsoft/iis-cors-module

and add the below tag in web.config file within the <system.webserver> tab

       <cors enabled="true" failUnlistedOrigins="true">
	     <add origin="*" maxAge="600"> 
		 <!-- allowCredentials="true" -->
		 
		<allowHeaders allowAllRequestedHeaders="true">
			<add header="header1" />
			<add header="header2" />
		</allowHeaders>
		<allowMethods>
			 <add method="POST" />
			 <add method="OPTIONS" />
		</allowMethods>
		<exposeHeaders>
			<add header="header1" />
			<add header="header2" />
		</exposeHeaders>
	</add>
</cors>

Please provide documentation link of Solution.

I have the same issue then I resolve it by downgrade Ionic-4 CLI version and I have created a git repository for this.

You can use it

1 Like

Thanks,
I will try for the next project :smiley: