Site Map - skip to main content

Hacker Public Radio

Your ideas, projects, opinions - podcasted.

New episodes every weekday Monday through Friday.
This page was generated by The HPR Robot at


hpr2904 :: DIY URL shortening

Quick tip on how to shorten an URL without a silly SaaS

<< First, < Previous, , Latest >>

Hosted by Klaatu on Thursday, 2019-09-19 is flagged as Clean and is released under a CC-BY-SA license.
html, url shortner. 1.
The show is available on the Internet Archive at: https://archive.org/details/hpr2904

Listen in ogg, spx, or mp3 format. Play now:

Duration: 00:12:18

general.

Make a directory to house your shortened URLs.


$ ssh example.com mkdir public_html/u

On demand, create a subdirectory for the shortened URL you want to create.


$ ssh example.com mkdir public_html/u/hpr

Create an HTTP redirect in an index.html file.


$ ssh example.com echo ""<html><title>Shortened URL</title><head><meta http-equiv='refresh' content='0; URL=http://hackerpublicradio.org/correspondents/0078.html' /></head></html>"" > www/u/hpr/index.html

Your shortened URL is example.com/u/hpr


Comments

Subscribe to the comments RSS feed.

Comment #1 posted on 2019-09-23 11:16:43 by tuturto

clever

Really clever way of doing this. When I saw the headline, my mind started immediately working through all kinds of algorithms one could use shortening urls. Turns out, nothing complicated is needed.

Leave Comment

Note to Verbose Commenters
If you can't fit everything you want to say in the comment below then you really should record a response show instead.

Note to Spammers
All comments are moderated. All links are checked by humans. We strip out all html. Feel free to record a show about yourself, or your industry, or any other topic we may find interesting. We also check shows for spam :).

Provide feedback
Your Name/Handle:
Title:
Comment:
Anti Spam Question: What does the letter P in HPR stand for?
Are you a spammer?
Who is the host of this show?
What does HPR mean to you?