Skip to content
This repository has been archived by the owner on Aug 4, 2020. It is now read-only.

Latest commit

 

History

History

ZeroWidthChar

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

Zero Width Encode and Decode

Encode Content to Zero Width Characters or Decode Zero Width Characters to the Raw Content. Use Go(Golang).

Use

Download ZeroWidth.go, then use the go command:

$ go run ./Zerowidth.go -d [encoded content] -e [raw content] -b [content before] -a [content after]

Or, you can use it online: I'm the link!

Explanation:

  -d [encoded content](string)
        what you want to decode
  -e [raw content](string)
        what you want to encode
  -b [content before](string)
        what you want to put before encoded content (default "encoded content ->")
  -a [content after](string)
        what you want to put before encoded content (default "<- encoded content")

Example

Encode

$ go run ./ZeroWidth.go -e "Hello, World. 你好。"
Encoded:
encoded content ->‌​‍‍​‍‍‍‌​​‍‍​‍​‌​​‍​​‍‍‌​​‍​​‍‍‌​​‍​​​​‌​‍​​‍‍‌​‍‍‍‍‍‌​‍​‍​​​‌​​‍​​​​‌​​​‍‍​‍‌​​‍​​‍‍‌​​‍‍​‍‍‌​‍​​​‍‌​‍‍‍‍‍‌​‍‍​​​​‍​​‍‍‍‍‍‌​‍​​‍‍​‍​​​​​‍​‌​​‍‍‍‍‍‍‍‍‍‍​‍‌<- encoded content

$ go run ./ZeroWidth.go -e "Hello, World. 你好。" -b "hel" -a "lo"
Encoded:
hel‌​‍‍​‍‍‍‌​​‍‍​‍​‌​​‍​​‍‍‌​​‍​​‍‍‌​​‍​​​​‌​‍​​‍‍‌​‍‍‍‍‍‌​‍​‍​​​‌​​‍​​​​‌​​​‍‍​‍‌​​‍​​‍‍‌​​‍‍​‍‍‌​‍​​​‍‌​‍‍‍‍‍‌​‍‍​​​​‍​​‍‍‍‍‍‌​‍​​‍‍​‍​​​​​‍​‌​​‍‍‍‍‍‍‍‍‍‍​‍‌lo

Decode

$ go run ./ZeroWidth.go -d "‌​‍‍​‍‍‍‌​​‍‍​‍​‌​​‍​​‍‍‌​​‍​​‍‍‌​​‍​​​​‌​‍​​‍‍‌​‍‍‍‍‍‌​‍​‍​​​‌​​‍​​​​‌​​​‍‍​‍‌​​‍​​‍‍‌​​‍‍​‍‍‌​‍​​​‍‌​‍‍‍‍‍‌​‍‍​​​​‍​​‍‍‍‍‍‌​‍​​‍‍​‍​​​​​‍​‌​​‍‍‍‍‍‍‍‍‍‍​‍‌"
Decoded:
Hello, World. 你好。

$ go run ./ZeroWidth.go -d "encoded content ->‌​‍‍​‍‍‍‌​​‍‍​‍​‌​​‍​​‍‍‌​​‍​​‍‍‌​​‍​​​​‌​‍​​‍‍‌​‍‍‍‍‍‌​‍​‍​​​‌​​‍​​​​‌​​​‍‍​‍‌​​‍​​‍‍‌​​‍‍​‍‍‌​‍​​​‍‌​‍‍‍‍‍‌​‍‍​​​​‍​​‍‍‍‍‍‌​‍​​‍‍​‍​​​​​‍​‌​​‍‍‍‍‍‍‍‍‍‍​‍‌<- encoded content"
Decoded:
Hello, World. 你好。

$ go run ./ZeroWidth.go -d "hel‌​‍‍​‍‍‍‌​​‍‍​‍​‌​​‍​​‍‍‌​​‍​​‍‍‌​​‍​​​​‌​‍​​‍‍‌​‍‍‍‍‍‌​‍​‍​​​‌​​‍​​​​‌​​​‍‍​‍‌​​‍​​‍‍‌​​‍‍​‍‍‌​‍​​​‍‌​‍‍‍‍‍‌​‍‍​​​​‍​​‍‍‍‍‍‌​‍​​‍‍​‍​​​​​‍​‌​​‍‍‍‍‍‍‍‍‍‍​‍‌lo"
Decoded:
Hello, World. 你好。

Notice

UTF-8 Support! Maybe :)

License

MIT License