Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Bloke committed Mar 9, 2023
1 parent fa7c5c2 commit e0e1400
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 11 deletions.
19 changes: 11 additions & 8 deletions README.textile
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ Permit access to downloads, pages or parts of pages for a certain configurable t

h2. Installation / uninstallation

p(important). Requires TXP 4.7.0+
p(important). Requires Textpattern 4.7.0+

Download the plugin from either "textpattern.org":http://textpattern.org/plugins/1222/smd_access_keys, or the "software page":http://stefdawson.com/sw, paste the code into the TXP _Admin->Plugins_ pane, install and enable the plugin. The table will be installed automatically unless you use the plugin from the cache directory; in which case, visit the _Extensions->Access keys_ tab and click the _Install table_ button before trying to use the plugin.
Download the plugin from either "the official Textpattern plugin repository":https://plugins.textpattern.com/plugins/smd_access_keys, the "software page":https://stefdawson.com/smd_access_keys, or "GitHub":https://github.com/Bloke/smd_access_keys/releases, paste the code into the TXP _Admin->Plugins_ pane, install and enable the plugin. The table will be installed automatically unless you use the plugin from the cache directory; in which case, visit the _Extensions->Access keys_ tab and click the _Install table_ button before trying to use the plugin.

To uninstall the plugin, delete from the _Admin->Plugins_ page. The access keys table will be deleted automatically.

Visit the "forum thread":http://forum.textpattern.com/viewtopic.php?id=35996 for more info or to report on the success or otherwise of the plugin.
Visit the "forum thread":https://forum.textpattern.com/viewtopic.php?id=35996 for more info or to report on the success or otherwise of the plugin.

h2. Overview

Expand All @@ -37,7 +37,7 @@ Generates an access token for a given URL. Configure it using the following attr
: This string is added to your url so the plugin knows it is protected content.
: Default: @smd_akey@
; %site_name%
: Whether to automatically add the site name (http://example.org) to the URL or not. Choose from:
: Whether to automatically add the site name (https://example.org) to the URL or not. Choose from:
:: 0: leave the site out
:: 1: add the site URL (but only if its not in the URL already)
: Default: 1
Expand Down Expand Up @@ -82,7 +82,7 @@ bc. <txp:smd_access_key

This might generate an access-controlled URL such as the following (newlines just for clarity):

bc. http://example.org/music/next-big-hit/demo/
bc. https://example.org/music/next-big-hit/demo/
42c531d13423eecaaab73a2df43a8b7c337a360a/4d9d12a5

Send that link to your friend and she'll be able to listen to your cool new demo song.
Expand Down Expand Up @@ -202,9 +202,9 @@ Display access information from the current protected page. Attributes:
: Default: @page@
; %escape%
: Whether to escape HTML entities such as @<@, @>@ and @&@ in the item. Set @escape=""@ to turn this off.
: Defualt: @html@
: Default: @html@
; %format%
: If displaying a time-related item (now, issued, or expires) you can format it using the "strftime() formatting codes":http://php.net/manual/en/function.strftime.php.
: If displaying a time-related item (now, issued, or expires) you can format it using the "strftime() formatting codes":https://php.net/manual/en/function.strftime.php.
: Default: @%Y-%m-%d %H:%M:%S@
; %wraptag%
: HTML tag (without angle brackets) to wrap around the output.
Expand Down Expand Up @@ -240,6 +240,9 @@ The plugin exposes some global preference settings that govern its operation:
; %Salt length%
: Number of characters to use as a salt in your secret key. The default is usually fine but if you want to alter this for greater/reduced security then do so. IMPORTANT: if you change this value, all your existing access keys become instantly invalid.
: Default: 8
; %Access key length%
: Number of characters to use as a token in your final key. The default delivers fairly long URLs so if you prefer to shorten this for ease of use, then do so. IMPORTANT notes: a) if you change this value, all your existing access keys become instantly invalid. b) the shorter the value, the easier it will be to crack.
: Default: 32
; %Log IP addresses%
: Whether you wish the plugin to log the IP address of each visitor who tries to access a protected resource
: Default: no
Expand Down Expand Up @@ -356,4 +359,4 @@ p. Ta da!

h2. Author

Written by "Stef Dawson":http://stefdawson.com/contact.
Written by "Stef Dawson":https://stefdawson.com/contact.
6 changes: 3 additions & 3 deletions smd_access_keys.php
Original file line number Diff line number Diff line change
Expand Up @@ -1435,9 +1435,9 @@ function smd_access_info($atts, $thing = null)

h2. Installation / uninstallation

p(important). Requires TXP 4.7.0+
p(important). Requires Textpattern 4.7.0+

Download the plugin from either "textpattern.org":https://textpattern.org/plugins/1222/smd_access_keys, or the "software page":https://stefdawson.com/sw, paste the code into the TXP _Admin->Plugins_ pane, install and enable the plugin. The table will be installed automatically unless you use the plugin from the cache directory; in which case, visit the _Extensions->Access keys_ tab and click the _Install table_ button before trying to use the plugin.
Download the plugin from either "the official Textpattern plugin repository":https://plugins.textpattern.com/plugins/smd_access_keys, the "software page":https://stefdawson.com/smd_access_keys, or "GitHub":https://github.com/Bloke/smd_access_keys/releases, paste the code into the TXP _Admin->Plugins_ pane, install and enable the plugin. The table will be installed automatically unless you use the plugin from the cache directory; in which case, visit the _Extensions->Access keys_ tab and click the _Install table_ button before trying to use the plugin.

To uninstall the plugin, delete from the _Admin->Plugins_ page. The access keys table will be deleted automatically.

Expand Down Expand Up @@ -1633,7 +1633,7 @@ function smd_access_info($atts, $thing = null)
: Default: @page@
; %escape%
: Whether to escape HTML entities such as @<@, @>@ and @&@ in the item. Set @escape=""@ to turn this off.
: Defualt: @html@
: Default: @html@
; %format%
: If displaying a time-related item (now, issued, or expires) you can format it using the "strftime() formatting codes":https://php.net/manual/en/function.strftime.php.
: Default: @%Y-%m-%d %H:%M:%S@
Expand Down

0 comments on commit e0e1400

Please sign in to comment.