Implementing in WordPress

The web toolkit

Iframe descriptions

Other components

Building the page

Implementing in WordPress

Implementing in HTML

Configuring CSS styles

Iframe CSS styles

The checkout screens

Club selection and signup

The account manager

In an installation using standard HTML techniques, each of the scenarios listed at Building the page is implemented by inserting the appropriate <DIV> segment for each of the required iframe components. When the page is designed in WordPress, however, attempting to edit the project in this manner will lead to corruption, as the WordPress editor is likely to alter the code in undesired ways. For this reason, WordPress installations should instead use the Active Club plugin for WordPress. The plugin manages the details of adding the appropriate code to the project through the use of WordPress shortcodes.

For a tutorial video on setting up a WordPress site, see https://player.vimeo.com/video/306121223.

Using the plugin

Installing and activating

To install the Active plugin in WordPress, obtain a copy of the file ACSSource.php (currently ver. 3). Add it to the projectʼs inc or include folder, normally found in a subfolder under wp-content/themes/.

Next, open the file functions.php and add the following lines:

/ Include ACS Shortcodes /
require_once('includes/ACSSource.php' );

or

/ Include ACS Shortcodes /
require get_template_directory() . '/inc/ACSSource.php';

(Note: You may need to test both of these variants to determine which one works in your version of WordPress.)

Inserting shortcodes

To use a shortcode, open the project page where you want to install one or more of the Active iframe elements. Enter the appropriate shortcodes for that page, as outlined at Plugin shortcodes below. (Note that the first of these will always be ACSScript.) Change the parameter arguments as needed for the page you are building.

For example, the text in the ACS Forgot Password page might look as follows:

WordPress page with plugin

WordPress newsletter hook widget An exception to this rule is the newsletter “hook.” To add it to a page, choose Appearance : Widgets from the WordPress project explorer. In one of the widget areas (Main, Footer, etc.), enter the ACSScript and ACSNewsletterHook shortcodes as described below, changing the parameter arguments as needed.

Plugin shortcodes

The following WordPress “shortcodes” are available. Each one requires a number of arguments, as described in the examples. For details on the argumentsʼ functions and permitted values, see Shortcode parameters below.

ACSScript

Required in all iframes; enables communication between iframe elements.

Example: [ACSScript server=CA dbname=demodb_6]

ACSiFrame

Manages iframe scenarios.

Example: [ACSiFrame server=CA dbname=demodb_6 scenario=5 fcridcart=FC0000002 fcridclub=FC0000003 waitcursor=winepour.gif bottommargin=20 scrollpoint=135 cursortopmargin=23]

ACSForgotPassword

(See “Forgot password” and “Reset password”)..

Example: [ACSForgotPassword server=CA dbname=demodb_6 fcrid=FC0000002 waitcursor=ring.gif bottommargin=20 cursortopmargin=-23]

ACSResetPassword

(See “Forgot password” and “Reset password”)..

Example: [ACSResetPassword server=CA dbname=demodb_6 fcrid=FC0000002 waitcursor=applespin.gif bottommargin=20 cursortopmargin=-23]

ACSUnsubscribe

Accepts parameters for Unsubscribe (“Opt Out”) page.

Example: [ACSUnsubscribe server=CA dbname=demodb_6 fcrid=FC0000002 waitcursor=gears.gif bottommargin=20 cursortopmargin=-23]

ACSNewsletterHook

Captures e-mail address in the Newsletter “hook” widget.

Example: [ACSNewsletterHook server=CA dbname=demodb_6 fcrid=FC0000002]

ACSNewsletter

For newsletter signup page.

Example: [ACSNewsletter server=CA dbname=demodb_6 fcrid=0000002 waitcursor=gears.gif bottommargin=20 cursortopmargin=-23]

Shortcode parameters

Each of the shortcodes requires arguments that specify operating parameters for the associated iframes:


ArgumentMeaningDefaultAllowedNotes
bottommarginbottom margin (px)0(numeric)
dbnameweb service namedemodb_3(any valid DB web service name)
fcridFrame Config record IDFC0000001(created in Manager)
fcridcartFrame Config record ID(none)(Frame Config record number — cart)(if not specified, use fcrid)
fcridclubFrame Config record ID(none)(Frame Config record number — club)(if not specified, use fcrid)
scrollpointvertical scroll point (px)0(numeric)
scenarioiframe scenario number11–8
serverserver locationTESTCA, WA, TX, VA
usesessionenable page persistenceyesyes, noThis argument is not illustrated in any of the examples above. Where does it go?
waitcursorwait cursor top margin (px)progressbar.gifapplespin.gif, gears.gif, rotator.gif, rotator2.gif, winepour.gif, ring.gif, (none)(user can supply URL)