Skip to content
Snippets Groups Projects
=== SAI PuzzleAnywhere Plugin ===
Contributors: Glenn Turner
Requires at least: 5.0.2
Tested up to: 5.8
Requires PHP: 5.6+
Stable tag: 1.2.0
License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html

Plugin to interface with a puzzle publisher's PuzzleAnywhere instance.

== Description ==
Plugin to interface with a puzzle publisher's PuzzleAnywhere instance.

== Installation ==
1. Upload the "sai-puzzleanywhere folder to the "/wp-content/plugins/" directory.
2. Activate the plugin through the "Plugins" menu in WordPress.
3. Click on Settings > PuzzleAnywhere and configure your PuzzleAnywhere server and social media settings.
4. (Optional) Upload the PuzzleAnywhere WordPress theme folder to the "/wp-content/themes" directory.

== Frequently Asked Questions ==
= What exactly does the PuzzleAnywhere plugin do? =
The PuzzleAnywhere plugin allows your WordPress-based site to interface with your PuzzleAnywhere server, including:

- Subscription purchases
- Puzzle archive lists
- Puzzle resending
- Newsletter signup
- Individual puzzle purchases
- Tip jar support
- User account support
- Staff and author support

= How does the plugin interface with my PuzzleAnywhere server? =
The manager of your PuzzleAnywhere account should send you the PuzzleAnywhere API domain name. Just enter that domain name into the PuzzleAnywhere Plugin settings page, and you should be good to go.

= How do I set my service logo and name? =
The plugin takes that data from the WordPress blog info. Just assign your site title and upload your logo via the site customization tool!

= How do I set up subscription/puzzle pages? =
The PuzzleAnywhere plugin automatically generates the following new pages:

- About Us
- Available Bundles
- Buy Individual Puzzles
- Confirm Newsletter Subscription
- Contact Us
- Download Puzzle
- Download Your Purchase
- Enable Account
- Free Trial
- Free Trial Confirmation
- Home (the initial landing page)
- Learn More (your FAQ)
- Privacy Policy
- Purchase Renewal (completes the subscription renewal process)
- Puzzle (basic puzzle information)
- Puzzles By Year (displays a list of puzzles published in the requested year)
- Renew Subscription (initializes the renewal process)
- Resend Puzzle
- Reset Password (password change complete)
- Sample Puzzles
- Subscribe
- Supported Apps
- Tip Jar

= Why is my home page blank? =
You need to set the newly created Home page to be the WordPress installation's home page. You can do so by:

- Click Settings > Reading
- Select 'A static page' under 'Your homepage displays'
- Set Homepage to 'Home'

Please note: Your home page will be reset whenever you rebuild the Home Page. (See 'What are the debug options?')

= Why do I see all pages in my nav menu? =
If you haven't assigned a primary nav menu, all PuzzleAnywhere pages are assigned to the default nav menu. You can adjust this via your Admin Dashboard > Appearance > Menus.

= Are there any quick navigation groups I can use? =
Yes! There are two pre-made navigation groups:

- PuzzleAnywhere Primary: This group contains major nav items, such as 'Subscribe', 'Puzzles By Year', 'Buy Individual Puzzles', 'Tip Jar', and 'Learn More'.

- PuzzleAnywhere Secondary Nav: This grouph contains quick links to 'Resend Puzzles', 'Sample Puzzles', etc.

We recommend using 'PuzzleAnywhere Primary' as your primary nav, and adding 'PuzzleAnywhere Secondary Nav' to your sidebar via the 'Navigation Menu' widget.

= Can I embed PuzzleAnywhere data in other pages? =
Yes! The following PuzzleAnywhere blocks can be used by inserting a shortcode into any page:

- About Us: [about_us] (Includes `featured_providers`, `staff`, and `authors`)
- Authors: [authors] (Featured authors)
- Buy Individual Puzzles: [buy_puzzles]
- Enable Account: [request_password_reset]
- Manage Emails: [manage_newsletters]
- Provider: [provider slug="provider_slug"]
- Puzzles By Year: [puzzles_by_year] (If there's a year in the url as /2015, it'll use that year.)
- Puzzles By Year, with a passed year: [puzzles_by_year year="2015"]
- Puzzle Request Form: [puzzle_request_form]
- Puzzle: [puzzle date="2019-01-01"] Retrieves puzzle summary info by date
- Resend Puzzle: [puzzle_request_form]
- Staff: [staff]
- Subscription Form: [subscribe]
- Tip Jar Form: [tip_jar]
- Your Account: [account]

= Are there any other shortcodes I should know about? =
We have the additional helper shortcodes to prevent redundancy:

- [facebook_url]: Inserts the user-defined Facebook url.
- [twitter_url]: Inserts the user-defined Twitter url.
- [support_email]: Inserts just the support email as defined in the PuzzleAnywhere Settings.
- [support_email_link]: The same as [support_email], but as an HMTL link.

= Does the plugin include any widgets? =
Yes, to allow you to better handle data blocks, the following widgets are automatically created to a PA-specific secondary nav menu:

- Your Puzzle Contributors: this widget allows you to manage author info without having to create explicit WordPress users for them.
- Puzzle Newsletter: Allows you to customize presentational newsletter signup text.

However, these widgets will be deprecated -- puzzle contributors should be handled via staff and authors instead -- and the newsletter signup text will be moved to theme options.

= How much of the pages can I alter? =
You can alter pages as much as you want, as long as you retain the shortcodes for the specific pages. Predictably, removing those shortcodes will prevent PuzzleAnywhere blocks from rendering.

= How can I add authors or staff? =
While authors can be added via the Puzzle Contributor widget, available via Appearances > Widgets, this widget is being deprecated.

If you want to set a custom default author or staff portrait image, you can do so by creating a theme media setting with the id  `default_portrait`. Otherwise, it'll use the generic default user portrait via the PuzzleAnywhere instance.

= How do I update this plugin? =
Our plugin is only available via our GitLab instance. You can either manually download and update it by overwriting the prior sai-puzzleanywhere folder, or use WP Pusher (https://wppusher.com/) to automate it.

= What happens if I deactivate the plugin? =
Deactivating the plugin will destroy all of the pages that the plugin created, including any changes you may have made. Activating the plugin again will regenerate them, but any changes you made will be lost.

= What are the debug options?
The debug options are meant to aid troubleshooting and to reset the plugin if there's an issue. The options consist of:

- Rebuild Pages: This allows you to rebuild any page that PuzzleAnywhere automatically generates. This should be used if you've made destructive changes to pages and want to revert back to the default page content.

- Disable API Cache: This will prevent the plugin from caching results from the API server. For performance reasons, it's suggested that you only use this under development/testing circumstances.

- Empty Cache: PuzzleAnywhere automatically caches non-personalized API requests and retains them for five minutes, which means that newly uploaded puzzles or bundles will not immediately appear on the site. Emptying the cache allows you to immediately view fresh API content.

= I'm a developer -- which methods and objects are available to me? =

Please see https://standalone.com/apis/sai-puzzleanywhere-wp!

= I'm a developer actively working _on_ this plugin -- how can I generate documentation? =

We follow the syntax that `phpDocumentator` uses, which is similar to `rDoc` and other inline documentation generators. If you have a copy of the plugin and an executable of `phpDocumentator`, you can generate your own documentation while working on the plugin via:

`phpDocumentor -d . -t docs/api`

= Anything else I should know? =

PuzzleAnywhere leaves most of the presentational style to you, but it does include some very basic layout styling (mostly for forms) via Bootstrap or embedded styling. All of those style rules can be overridden.

= What if I have a feature request? =

You can feel free to contact me at glenn@standlone.com with a feature request.

== Screenshots ==

== Changelog ==
= 1.1 - 2022-05-23 =
* Added proper authors and staff support.
* Added theme mod support for default author and staff portraits.

= 1.0 - 2021-01-21 =
* Added user account support.

* Improved view and theme handling.
= 0.9 - 2019-12-09 =
* Preliminary production release.
= 0.1 - 2019-09-10 =
* Initial release.

* Initial production release.