Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/HeroCC/yourls-conditional-urlads
A Yourls plugin that allows you to conditionally send shortlinks through various link monetizing services
https://github.com/HeroCC/yourls-conditional-urlads
Last synced: 10 days ago
JSON representation
A Yourls plugin that allows you to conditionally send shortlinks through various link monetizing services
- Host: GitHub
- URL: https://github.com/HeroCC/yourls-conditional-urlads
- Owner: HeroCC
- License: gpl-3.0
- Created: 2016-11-04T19:32:20.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2023-12-02T09:06:05.000Z (12 months ago)
- Last Synced: 2024-08-02T06:14:49.390Z (3 months ago)
- Language: PHP
- Size: 18.6 KB
- Stars: 6
- Watchers: 4
- Forks: 4
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome - Conditional Advertisements - A plugin to conditionally send links through various link monetizing services: `http://your.site/short` is normal, `http://your.site/a/short` redirects through AdFly. (Plugins / C)
README
# Conditional URL Advertisements
Plugin for [YOURLS](http://yourls.org).
## Description
This plugin allows you to redirect all shortlinks through a link monetizer.Currently, the following shorteners are supported:
* [AdFly](https://adf.ly/?id=2777408), trigger: `a/`
* [AdFoc.us](https://adfoc.us/?refid=287608), trigger `f/`
* [ouo.io](https://ouo.io/ref/0IqYvHOo), trigger `o/`Going to a shorturl with a trigger before it will automatically forward the url through the selected service (ex *sho.rt/a/test*). If it recognizes a trigger but there is no associated service it will not monetize the link.
If you have another sevice you want supported, make a ticket for it!
## Installation
1. Clone this repo to the `/user/plugins` plugins directory
2. Edit the plugin's settings (inside *plugin.php*) to suit your needs
3. Go to the Plugins administration page and activate the plugin
4. Test your shortlinks with each activated service
5. If everything works, celebrate!## Getting your IDs
To properly setup this plugin, you need to manually change the IDs from the defaults to your's. These instructions should show you how to do this for each service:### AdFly
1. Ensure you have a valid account and are logged in
2. Navigate to [this url](https://adf.ly/publisher/tools#tools-api)
3. Your ID is the number after 'Your User ID:' *not API key*### AdFocus
1. Ensure you have a valid account and are logged in
2. Navigate to [this url](http://adfoc.us/tools/site-links)
3. Your ID is the number after '?id='### ouo.io
1. Ensure you have a valid account and are logged in
2. Navigate to [this url](https://ouo.io/manage/tools/full-page-script)
3. Your ID is the bit inside the quotes for `ouo_token`