Wednesday, 15 November 2017

遠端伺服器傳回未預期的回應 413 Request Entity Too Large

遠端伺服器傳回未預期的回應 413 Request Entity Too Large

主因為WCF無法承接過大的資料量

解決方式在Web跟WCF二端web.config進行相關設定

其一:Web下的Web.config增加一個沒有設置名字的默認配置
<binding name="BasicHttpBinding_IService1" closeTimeout="00:03:00" openTimeout="00:03:00" receiveTimeout="00:03:00" sendTimeout="00:03:00" maxBufferSize="4086000" maxReceivedMessageSize="4086000" />
<binding name="BasicHttpBinding_IService11" closeTimeout="00:03:00" openTimeout="00:03:00" receiveTimeout="00:03:00" sendTimeout="00:03:00" maxBufferSize="4086000" maxReceivedMessageSize="4086000" />
<binding name="BasicHttpBinding_IService12" closeTimeout="00:03:00" openTimeout="00:03:00" receiveTimeout="00:03:00" sendTimeout="00:03:00" maxBufferSize="4086000" maxReceivedMessageSize="4086000" />
<binding   closeTimeout="00:10:00" receiveTimeout="00:20:00" sendTimeout="00:20:00"
maxBufferSize="2147483647" maxReceivedMessageSize="2147483647">

其二:WCF端下的Web.config的<system.serviceModel>中,增加<bindings>設定
<configuration>
<system.serviceModel>
    <bindings>
      <basicHttpBinding>
        <binding maxReceivedMessageSize="2147483647"
                 maxBufferSize="2147483647"
                 maxBufferPoolSize="2147483647">
          <readerQuotas maxDepth="32"
                        maxArrayLength="2147483647"
                        maxStringContentLength="2147483647"/>
        </binding>
      </basicHttpBinding>
    </bindings>
</system.serviceModel>
</configuration>

Monday, 27 February 2017

Uncaught ReferenceError: $ is not defined?

Uncaught ReferenceError: $ is not defined?

沒有引用相關的js,例如:
<script language="JavaScript" type="text/javascript" src="<?php echo get_option('siteurl') ?>/js/sprinkle.js"></script>
<script language="JavaScript" type="text/javascript" src="<?php echo get_option('siteurl') ?>/js/jquery-1.2.6.min.js"></script>
<script language="JavaScript" type="text/javascript" src="<?php echo get_option('siteurl') ?>/js/jquery-ui-personalized-1.5.2.packed.js"></script>

無法從組件 System.ServiceModel 載入類型

無法從組件 System.ServiceModel 載入類型

設定IIS與安裝.NET Framework4.0要依照順序

解決步驟如下:


  1. 開啟命令提示字元視窗
  2. 然後指定作業路徑至C:\Windows\Microsoft.NET\Framework\v4.0.30319
  3. 輸入【aspnet_regiis -i】後按ENTER
  4. 再到IIS重新啟動,即可

Sunday, 26 February 2017

IIS HTTP Error 403.18

 HTTP Error 403.18 - Forbidden The specified request cannot be processed in the application pool that is configured for this resource on the...