custom-binding

WCF with custombinding on both http and https

China☆狼群 提交于 2019-12-08 15:46:53
问题 I have a WCF service with custombinding and it is working fine on either http or https. But I have totally no idea about how can I make it available on both http and https? Also is it possible to do that? Here's my configuration in web.config. <system.serviceModel> <serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true"/> <behaviors> <serviceBehaviors> <behavior name=""> <serviceMetadata httpsGetEnabled="true" /> <serviceDebug

WCF and custom text encoding - messy business

。_饼干妹妹 提交于 2019-12-07 10:23:27
问题 I have a really weird WCF problem here... We're connecting to a crappy third-party web service; it was a nightmare to even get it going, we had to create a custom WCF binding since those guys decided to use "ISO-8859-1" as their text encoding (instead of UTF-8 like everyone else on the web), and the other settings were messy, too - and not documented anywhere, of course... It's been working ok for a while now, but suddenly, some of our data coming back in mangled up. We expect to get back

Creating a custom binding for nl2br in knockout.js

只谈情不闲聊 提交于 2019-12-06 06:21:37
问题 I am trying to write a custom binding to replace " /n " with " <br /> " within a " <p> " element. I understand the concept more or less, but I'm stuggling to get it going. Can anyone suggest where I'm going wrong. I don't really want to use a computed observable, as I want to keep the real value using " /n " rather than " <br /> ". ko.bindingHandlers.nl2br = { init: function(element, valueAccessor, allBindingsAccessor, viewModel, bindingContext) { var field = valueAccessor(); field.replace(/

knockout valueUpdate not working with Pagedown?

隐身守侯 提交于 2019-12-05 22:07:11
I have the following in my view: <textarea data-bind="value: content, valueUpdate: 'afterkeydown'"></textarea> Which when typing, behaves as I'd expect. But I'm using a WMD / Pagedown editor to click a button that adds content to the field, much like StackOverflow's post contents box when you're creating / updating a post. If I just click a button (to add asterisks or brackets etc) and don't type anything, the value never gets updated in the content observable. I do have a save button that I could use to trigger the "sync" before saving the data by specifiying the input elements to update, but

Knockout renderTemplate() rendering modes

荒凉一梦 提交于 2019-12-04 19:42:43
问题 I'm trying to call ko.renderTemplate() in a custom binding. However I can't find any documentation for it's usage, particularly the rendering mode parameter. Knockout.js pro tips – working with templates The site above has a section "You can render templates directly from your custom bindings" that briefly describes the parameters to renderTemplate() . What are the other available options for the rendering mode parameter? Additionally, is there any documentation for renderTemplate() and the

Creating a custom binding for nl2br in knockout.js

我怕爱的太早我们不能终老 提交于 2019-12-04 12:33:29
I am trying to write a custom binding to replace " /n " with " <br /> " within a " <p> " element. I understand the concept more or less, but I'm stuggling to get it going. Can anyone suggest where I'm going wrong. I don't really want to use a computed observable, as I want to keep the real value using " /n " rather than " <br /> ". ko.bindingHandlers.nl2br = { init: function(element, valueAccessor, allBindingsAccessor, viewModel, bindingContext) { var field = valueAccessor(); field.replace(/\n/g, '<br />'); $(element).val(field) }, update: function(element, valueAccessor, allBindingsAccessor,

WCF Service Reference generates an empty reference.cs due to DuplexBinding

穿精又带淫゛_ 提交于 2019-12-04 06:06:05
问题 I have WCF service. Here is configuration <basicHttpBinding> <binding name="EmergencyRegistratorBinding"> <security mode="TransportCredentialOnly"> <transport clientCredentialType="Windows" /> </security> </binding> </basicHttpBinding> And service configuration <service behaviorConfiguration="Default" name="Breeze.AppServer.Emergencies.EmergencyRegistrator"> <endpoint address="" binding="basicHttpBinding" bindingConfiguration="EmergencyRegistratorBinding" contract="Services

Configuring WCF client and service for use with protobuf-net

白昼怎懂夜的黑 提交于 2019-12-03 20:29:56
问题 I decided to open a new question about this matter, maybe expanding this question, not having found a precise answer about the issue anywhere on the Internet. I want to use protobuf-net to serialize/deserialize messages exchanged between my WCF client and service. The service is self-hosted in a Windows Service. Both client and service are configured programmatically, using a custom binding very similar to wsHttpBinding . Service reference code is generated using "Add Service Reference"

Knockout renderTemplate() rendering modes

萝らか妹 提交于 2019-12-03 12:56:00
I'm trying to call ko.renderTemplate() in a custom binding. However I can't find any documentation for it's usage, particularly the rendering mode parameter. Knockout.js pro tips – working with templates The site above has a section "You can render templates directly from your custom bindings" that briefly describes the parameters to renderTemplate() . What are the other available options for the rendering mode parameter? Additionally, is there any documentation for renderTemplate() and the rendering engine options that I may have missed? Just from looking at the source code of 2.2.0. The

WCF Service Reference generates an empty reference.cs due to DuplexBinding

六眼飞鱼酱① 提交于 2019-12-02 11:07:31
I have WCF service. Here is configuration <basicHttpBinding> <binding name="EmergencyRegistratorBinding"> <security mode="TransportCredentialOnly"> <transport clientCredentialType="Windows" /> </security> </binding> </basicHttpBinding> And service configuration <service behaviorConfiguration="Default" name="Breeze.AppServer.Emergencies.EmergencyRegistrator"> <endpoint address="" binding="basicHttpBinding" bindingConfiguration="EmergencyRegistratorBinding" contract="Services.IEmergencyRegistrator" /> </service> Everything worked fine. But I needed to change basicHttpBingind to DuplexBinding. I