Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Jasonlhy/ChineseEncodingAnalyzer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

5 Commits

Repository files navigation

中文編碼解析工具

處理中文編碼問題時的方便小工具,原本寫成 Windows Form,從 2006 年開始發展,已有超過十年歷史。現在改寫成 Web 方式並開源囉~

發展沿革

程式說明

網站使用 ASP.NET Core with Vue SPA 專案範本為基礎修改(參考:Vue筆記4-Vue.js + TypeScript + ASP.NET Core)。 遇到的首要困難是原本 WinForm 版使用 System.Web.HttpUtility 處理 UrlEncode 及 UrlDecode, 在 .NET Core 已不再建議使用,故需尋找替代程式庫, 但評估過 System.Net.WebUtility、System.Web.Encodings.Web.UrlEncoder、System.Uri.EscapeDataString() 所提供方法多已回歸當代標準, 統一使用 UTF8 編碼,不像 HttpUtility.UrlEncode() 可指定 Encoding 參數,亦不支援 %uxxxx 這種 UrlEncodeUnicode() 過時編碼。 為保有過往規格,我選擇了可恥但有用的做法 - 參考 HttpUtility 原始碼,將其中的邏輯搬進專案,復刻成同名元件。

無論如何,算是把原本 WinForm 版的相同邏輯移植成網頁版,並且提供了線上版本:https://www.darkthread.net/cea,歡迎大家利用。

About

中文編碼解析工具

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 66.0%
  • HTML 16.2%
  • JavaScript 9.5%
  • TypeScript 7.3%
  • CSS 1.0%

AltStyle によって変換されたページ (->オリジナル) /