Skip to content

Commit

Permalink
Updated README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
zanderwar committed Jan 11, 2018
1 parent 55e16ab commit 1a557d3
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
# silverstripe-securelinkparser
This module provides you with a page and the functionality to redirect viewers to user defined links to:

> **TL;DR** Will convert "https://google.com" into "https://yourdomain.com/external-links?url=https://google.com"
## What's it do?
* Warns the viewer that they're about to be redirected to external link
* Give the user the ability to cancel the redirection.
* If they cancel then provide them with an option to continue to the link anyway in case they changed their mind.
* Track how many hits an external URL has had from your domain.
* Prevents potentially breaking SSL due to insecure links

## Requirements
* silverstripe/framework: ^4
Expand All @@ -14,6 +18,20 @@ This module provides you with a page and the functionality to redirect viewers t
```bash
composer install vulcandigital/silverstripe-securelinkparser
```

## Usage
An extension is packaged with this module and gives you access to the `$SecureUserDefinedLink` method from within any `PageController`

```twig
<a href='$SecureUserDefinedLink($CustomLink)'>$CustomLinkTitle</a>
```

or

```php
$link = \Vulcan\SecureLinkParser\SecureLinkParser::getSecureLink($this->CustomLink);
```

## Configuration
The only configuration variable available is `create_default_page`, which will create the redirection page automatically upon `dev/build`

Expand Down

0 comments on commit 1a557d3

Please sign in to comment.