Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

URL shortener #284

Open
cogat opened this issue Aug 14, 2017 · 1 comment
Open

URL shortener #284

cogat opened this issue Aug 14, 2017 · 1 comment

Comments

@cogat
Copy link
Contributor

cogat commented Aug 14, 2017

Let's put a URL shortener in ICEkit.

We (at ACMI) want to be able to:

a) have many short URLs point to the same long URL, with different UTM codes (or perhaps other GET parameters).

b) specify short URLs, but generate a short one made if none is specified.

c) shared short URLs retain social sharing metadata.

Proposed approach:

  1. create a short_urls app in ICEkit, with a model that maps a unique shortcode to an ICEkitURL (which can be a GFK or an arbitrary URL). Create an admin UI for

  2. create an inlineadmin for ICEkit content that allows a user to specify one or more shortcodes for content, with potentially varying GET strings. If no shortcode is specified, one is generated. If a duplicate shortcode is specified, a validation error is made.

  3. serve requests to shortcodes as redirects to the destination URLs.

  4. serve ICEkit pages with a <link rel="shortlink" href="http://www.mywebsite.com/shortcode"> in the header.

  5. Implement short URLs in such a way that social sharing metadata is conveyed when the short link is shared.

Questions:

a) does this supersede the existing redirects module? should we migrate away from it? I propose it does and we should.
b) should short URLs be tied to one domain or work with any domain? Should the main site domain be one of these? I propose that the solution be domain-agnostic. The short domain to use should be a setting, defaulting to the usual domain.
c) should this URL do any tracking/analytics? I propose not for now - the UTM code can be used for GA.
d) should short URLs allow slashes? I propose yes, because it is necessary for a) above.

cc @andrewserong

@cogat cogat self-assigned this Aug 14, 2017
@aweakley
Copy link
Member

@cogat That sounds like a great Idea. Please can you fork the repo and make a pull request when you're ready?

cogat pushed a commit to ACMILabs/django-icekit that referenced this issue Aug 16, 2017
@cogat cogat removed their assignment Jan 5, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants