Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
pfaffman committed Aug 9, 2024
1 parent d6b20b1 commit c531ee9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,13 @@
Replace a link for a set of hostnames with their respective referral links.

For example, you might want to replace links to digitalocean.com with my referral link, which is https://m.do.co/c/a5bf212d9a92. Install this theme component and you can do just that! You can instead
use your referral ink for Digital Ocean or whatever other sites you wish.
use your referral link for Digital Ocean or whatever other sites you wish.

The theme setting `affilliate link map` takes a list of "HOSTNAME,referral_url" mappings and
then replaces those links (<div class='cooked'>) with the referral link. This replacement happens
in the browser, so there is no need to rebake posts after making changes.

This replaces _only_ links to the home page, so links to other pages on the site still function
as expected.
as expected. See https://dashboard.literatecomputing.com/t/discourse-affiliate-linker/950 for an example of its use.

For hostname you enter, it looks for with and without the `www`. It also checks for both `http` and `https` links. So `digitalocean.com` will match and replace `http://www.digitalocean.com/`, `https://digitalocean.com` and the other two variations.

0 comments on commit c531ee9

Please sign in to comment.