Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Suggestion: Allow Alternate/Fallback URL with Fallback Toggle accessible via admin UI/API #2248
YOURLS version: 1.7.2
I would like to propose an option that would be incredibly valuable to Yourls administrators/developers.
The ability for Yourls to have a primary/default Long URL and a second optional fallback URL as part of each URL entry. A flag or toggle that can be turned on/off via an API call or via the Admin UI would allow users to toggle between either the default or fallback, allowing functionality that would permit users to redirect short urls/keywords based on a condition. The fallback URL should not adhere or be affected by the YOURLS_UNIQUE_URLS setting, as multiple entries should be allowed to have the same fallback URL regardless if their primary is a unique URL.
I think this would a valuable, dynamic and elegant feature/enhancement that could provide tremendous value to this excellent solution.
Possible Use Cases:
I believe this functionality can be added fairly quickly via a plugin. I hope its adopted and taken on by someone in the near future. Thank you!