Skip to content

Instantly share code, notes, and snippets.

@levigroker levigroker/URLEncode.sh
Last active Feb 8, 2018

Embed
What would you like to do?
A BBEdit Text Filter script to take textual input and produce URL encoded text of the same.
#!/bin/bash
#
# URL Encode
# https://gist.github.com/levigroker/36525010ba0bce15450c89fe6a5f36b1
#
# A BBEdit Text Filter script to take textual input and produce URL encoded text of the same.
# See http://bbeditextras.org/wiki/index.php?title=Text_Filters
# Levi Brown
# @levigroker
# levigroker@gmail.com
# January 12, 2018
##
IN=$(tee)
CMD="echo urlencode('${IN}');"
OUT=$(php -r "$CMD")
echo -n "${OUT}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.