Click here to Skip to main content
15,893,814 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
The content type text/html of the response message does not match the content type of the binding (text/xml; charset=utf-8). If using a custom encoder, be sure that the IsContentTypeSupported method is implemented properly. The first 1024 bytes of the response were: '<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
  <meta name="description" content="">
  <meta name="author" content="">
  <link rel="shortcut icon" href="images/favicon.png" type="image/png">

  <title>حملة الراجحي الخيرية</title>

  <link href="template/portal/css/style.default.css" rel="stylesheet">

  <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
  <!--[if lt IE 9]>
  <script src="js/html5shiv.js"></script>
  <script src="js/respond.min.js"></script>
  <![endif]-->
</head>

at time of consuming the from WCF

What I have tried:

<transport mode="Basic" its also not workin in web config
Posted
Comments
F-ES Sitecore 24-May-18 10:30am    
Your response is returning html rather than xml. Google "The content type text/html of the response message does not match the content type of the binding (text/xml; charset=utf-8)" for lots of things to look at or ideas why this is happening. Could be your service is returning an error, could be something else. Also try a scanning app like Fiddler to inspect the calls and what the return is, as if your method is returning an error you'll see that in Fiddler.
Richard Deeming 24-May-18 10:32am    
It looks like your server code is throwing an error, and returning an HTML error page.

Debug your code, or check the Windows event logs on the server to see if you can find the details of the error.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900