3 config.pod - documents BSE configuration file options
7 BSE historically used Constants.pm to keep most configuration
8 information. The plan is to make sure any new configuration is kept
9 in bse.cfg, and to slowly move most configuration information into
12 Keeping configuration information in Constants.pm makes it difficult
13 to perform upgrades and makes it impossible to use tools such as
14 mod_perl, at least if you want more than one site on the machine.
16 =head1 CONFIGURATION ENTRIES
20 Contains URL configuration for the site.
26 The normal URL for the non-secure parts of the site.
30 The secure URL for the shop, products and other portions of the site
31 that should use SSL. This isn't checked to make sure it is https.
35 Used as the site "name" in a few places.
39 If set, this is used as the base URL for accessing the administrative
40 functions of your site.
44 Ignored if C<adminurl> is set.
46 If this is true then C<secureurl> is used as the base URL for
47 accessing the administrative functions of your site, otherwise C<url>
48 is used as the base URL. Default: false (C<url>'s value is used)
52 Configure the IP address of one or more front-end proxies. This can
53 be a regular expression except that C<.> is translated to C<\.> and
54 C<*> is tranlated to C<.*> to give more glob() like matching.
56 If the reqesting host matches then admin site URL matching is done
57 against HTTP_X_FORWARDED_SERVER instead of SERVER_NAME.
59 Default: no front-end server configured.
65 Contains various file system paths.
71 This is where the files uploads with the file wizard are stored. It
72 must be writable by the web server user.
76 Directory containing administrative templates. Note: this is not
77 completely implemented for now, so assume the default. Default: admin
78 directory under $TMPLDIR.
82 Directory base for most templates. This can contain references like
83 $(section/key) to other configuration entries. Split on the systems
84 PATH separators (run: perl -V:path_sep)
88 Local Directory base for templates. This is searched before the
89 templates directory. This can contain references like $(section/key)
90 to other configuration entries. Split on the system's PATH separator.
94 Web server document root. Static pages are generated under this
95 directory. Default: $CONTENTBASE.
99 Where uploaded images are stored. This is not yet completely
100 implemented. Default: $IMAGEDIR.
104 Local search path for BSE::Custom, or the class configured by
105 C<custom_class> in [basic].
107 =item siteuser_images
109 Where uploaded siteuser images are stored. This must be set in the
110 config file. The default bse.cfg include an entry to use the current
111 values of [paths].downloads
115 Pregenerated dynamic article pages are stored here. This must be
116 defined if you site contains any dynamicly generated pages.
120 The directory where cached versions of scaled thumbnails are stored.
121 Defaults to image_dir/scaled. This must be in the document tree. If
122 you set this you should also set scalecacheurl.
126 The URL to the directory represented by scalecache. Defaults to
133 This section is used by the file wizard to map uploaded file
134 extensions to MIME content types. This can be used to extend
135 BSE::FileEditor's internal extension map. It cannot override that
138 The key for each entry is the extension, without the leading '.'.
142 xls = application/msexcel
146 Used for translating symbolic template names into full names under the
149 In each case the default is the name with a C<.tmpl> extension.
159 user registration page
163 =head2 [admin templates]
165 Used for translating the names of administration templates into filenames.
167 In each case the default is the name with a C<.tmpl> extension.
177 Catalog editor page. Default admin/edit_catalog.tmpl
189 Article edit pages. Default admin/edit_<number>.tmpl
193 Step child/parent management page. Default admin/edit_steps.tmpl
205 The value of the charset keyword when outputting HTML from a script.
206 Set to the empty string to suppress the charset keyword. Default:
211 If this is a non-zero number, then all but mailto links are redirected
212 to C<nuser.pl/redirect> so you can display a diclaimer. If this
213 contained alphabetics it's treated as a comma separated list of url
214 schemes that should be handled via C<nuser.pl/redirect>. If 0 or not
215 present, no redirection is done.
217 The redirect URL includes a hash of the url, title and the redirect
218 salt to prevent using this mechanism by external sites for cookie
223 The salt used in generating the has for redirect_links. Default: an
232 =item cookie_lifetime
234 The expiry time for cookies. This should be in the form supported by
235 CGI.pm for the -expires parameter. Typically you want a plus ('+'), a
236 number, and a time character (s - seconds, m - minutes, h - hours, d -
237 days, M - months). Default: +3h
241 This overrides the domain value set for cookies. This is useful if
242 you allow the site to run under both example.com and www.example.com,
243 if you set cookie_domain to example.com then a user visiting
244 www.example.com will still have their cookies when they visit
249 This overrides the cookie name used to store the session id. Default:
250 sessionid. This is useful when you have 2 sites under the same
251 top-level domain, and helps disambiguate the cookie returned by the
256 Minimum password length in characters. Default: 4.
260 Device to read random data from. This device should not block when it
265 If this is true then the encrypted messages containing the customer's
266 credit card number are sent to the shop owner signed. To avoid
267 keeping a passphrase and signing key on the server you can set this to
268 false (0). This has the effect that anyone could send you an unsigned
269 message encrypted with your public key, though this may not be a
270 security threat. Default: True.
274 If this is true then the links to your articles within BSE will be
275 followed by a / and then by a simplified version of the article title.
276 The aim is to include at least some title information in the URL
277 without modifying the name of the HTML file. Default: False.
281 If this is true then the user/group/permissions database is used to
282 control access to the system. Default: False.
284 =item access_filter_steps
286 If this is true, then the drop-down lists of possible stepparents and
287 stepchildren on the article edit pages are filtered for access control.
290 =item access_filter_parents
292 If this is true, then the drop-down lists of possible parents on the
293 newsletter edit pages are filtered for access control.
298 Set this to non-zero to enable authentication via server
299 authentication (usually Basic Authentication.) You should normally
300 set this if you set htusers below. Default: 0 (disabled)
304 This should be the path to a file to be updated with the list of users
305 and crypt() versions of their passwords. If this is set then the
306 security system will check for a user set by the browser before
307 attempting a form based logon. Default: None.
311 The name of the custom class for your site. This is currently only
312 used for article editing customizations. This class should derive
313 from BSE::CustomBase. Default: BSE::Custom.
315 =item jit_dynamic_pregen
317 If this is true, then pre-generation for dynamic pages will be delayed
318 until the page is displayed to a user. Default: off.
322 If true, the ifAjax and ajax tags will be active for static pages.
324 =item cache_thumbnails
326 If set to zero the results of the thumbimage/gthumbimage body/template
327 tags will not be cached. Default: 1 (caching is enabled).
329 =item static_thumbnails
331 If true and cache_thumbnails is true then thumbnails for the thumbnail
332 cache will be generated when a static page is regenerated, and the
333 link from the page will link to the image in the cache rather than to
334 C<thumb.pl>. Default: 1 (static thumbnails enabled).
338 The prefix applied to articles that use a linkAlias url. This should
343 If this is non-zero then an article with linkAlias set will use an
344 alias url instead of the "real" url. You will need to configure a
345 RewriteRule or ErrorDocument to page.pl to direct the user to the
346 correct URL. Default: 1.
350 If this is non-zero then the title is cleaned up (all but
351 alphanumerics removed) and appended to the alias URL generated.
353 =item default_popupimage
355 This is the default popup image class for the popimage[] and
356 gpopimage[] tags. Default: popup.
360 Some obsolete tags will warn to stderr if this is non-zero. Default:
363 =item no_cache_dynamic
365 If non-zero, the default, dynamic responses will include a
366 C<Cache-Control: no-cache> header. This can be overridden for
367 articles via , article flags, C<[template >
368 I<templatename>C<].no_cache_dynamic> and [article].no_cache_dynamic.
373 If true then page.pl will 301 redirect (Moved Permanently) requests
374 for an article by its id to the generated link if the article has a
375 link alias. Default: false. Must only be used with use_alias true.
379 If this is non-zero, and a cache is configured (see [cache]), file
380 uploads are tracked in entries in the cache.
382 The fileprogress.pl script can be called by Ajax to display file
383 upload progress information to the user. The upload state is updated
384 a maximum of once a second.
386 =item http_only_session
388 If this is non-zero, the default, the session cookie sent to the
389 browser has the C<HttpOnly> attribute set. This can prevent session
390 cookie hijacking. Default: 1.
394 If this is non-zero then the session cookie sent to the browser has
395 the C<Secure> attribute set. This means that the cookie will only be
396 visible over https. This is only useful when the only URL the site is
397 visited over is a https URL. Default: 0.
399 =item make_userid_cookie
401 If this is non-zero, the default, then when the site member logs in, a
402 javascript visible cookie, C<userid> will be set that contains the
403 login name of the user. BSE's back-end doesn't use this cookie, its
404 only use is for Javascript to enable/disable user interface elements.
411 This section controls how BSE sends email.
417 The host or IP address of your mail server. If this is not set
418 C<sendmail> will be used instead. If this is set you must also set
423 The name that BSE uses to identify itself when sending mail via SMTP.
424 Required if I<smtp_server> is set.
428 The path to the C<sendmail> binary. Default: /usr/lib/sendmail
432 The options supplied to sendmail. Default: -t -oi
434 You may want to add the -odq option to this if you want mail queued
435 rather than sent immediately.
437 =item set_errors_to_from
439 If true, we add an Errors-To header set to the same as the From
440 header. Default: true.
442 =item html_system_email
444 If non-zero then emails sent via the compose mail system that aren't
445 being sent to a member record, will be sent as HTML, if the HTML
446 template is available.
450 =head2 [children of I<id>]
452 Where I<id> is the identifier for an article.
458 the name of the default template for children of the given parent
462 a comma-separated list of extra directories under $TMPLDIR to search
463 for templates that can be used for children of the given parent article.
467 =head2 [article I<id>]
469 Where I<id> is the identifier of an article.
475 A comma-separated list of extra directories under $TMPLDIR to search
476 for templates that can be used for children of the given parent
479 =item extra_templates
481 A comma-separated list of extra templates under $TMPLDIR that can be
482 used for the given article.
486 =head2 [level I<level>]
492 The default template for this level of article, assuming it hasn't
493 been set in the [children of I<article id>] section.
497 A comma-separated list of extra directories under $TMPLDIR to search
498 for templates that can be used for articles at the given I<level>.
508 The default template for catalogs.
518 The default template for products.
520 =item extra_templates
522 A comma separated list of extra templates that can be used for
529 This can be used to control translation of error messages. Each key
530 has a prefix identifying the module that uses the error, followed by
531 '/' followed by a specific identifier for the message.
533 Message parameters, expressed as $I<digit>, are replaced with the
534 parameters passed to the message. C<$$> is replaced with C<$>.
536 Each message identifier below is documented with the id, when it
537 occurs, the default message, and any parameters.
543 the user attempted to logon without entering a logon name. Default:
544 "Please enter a logon name". No parameters.
548 the user attempted to logon without entering a password. Default:
549 "Please enter your password." No parameters.
551 =item user/baduserpass
553 the user's logon name or password was not found or did not match.
554 Default: "Invalid user or password". No parameters.
556 =item user/notloggedon
558 the user attempted to logoff while not logged on. Default: "You
559 aren't logged on". No parameters.
561 =item user/optsoldpass
563 the user entered a new password on the options page without entering
564 their old password. Default: "You need to enter your old password to
565 change your password". No parameters.
567 =item shop/logonrequired
569 Displayed if the user attempts to checkout when [shop].require_logon
580 if non-zero, the order must be marked as paid for before the file can
585 if non-zero the order must be marked as filled before the files can be
590 if non-zero the user must be registered/logged on to download I<any>
595 if non-zero, downloads of userfiles will be logged. Default: 0
597 =item log_downufile_maxage
599 the maximum age of entries in the user file download log, in days.
604 =head2 [confirmations]
606 Control over confirmation emails.
612 The subject of email confirmation emails. Default: Subcription
617 The from field for the email. Default: $SHOP_FROM
621 =head2 [subscriptions]
623 Control over subscription messages.
629 The from field for the email. Default: $SHOP_FROM.
633 Default for the "Test Name" field for sending test subscription
638 Default for the "Test Email" field for sending test subscription
643 Set to 1 if you want the "Test Text Only" box checked by default for
644 sending test subscription messages.
648 Set to 0 to disable display of the test subscription messages portions
649 of the subscriptions send form.
651 =item text_link_inline
653 Set to format links as they appear in the text version of emails.
654 C<$1> is replaced with the title, C<$2> with the URL and C<$3> with
655 the index. C<$$> is replaced with '$'. Default: C<$1 [$3]>
659 Set to format links as they appear at the footer of the body text. If
660 this is set to the empty string then no list appears. C<$1>, C<$2>,
661 C<$3>, C<$$> are replaced as for I<text_link_inline> and $n is
662 replaced with newline. Default: C<[$3] $2>
664 =item text_link_list_prefix
666 A line of text produced above the list of URLs if there is one.
667 Default: C<----->. $n in this is replaced with newlines.
671 For example, if the configuration is:
673 text_link_inline="$1" ($3)
674 text_link_list_prefix=$n$n-------
675 text_link_list=($3) "$1"$n => $2
677 and the body text is:
680 link[http://www.example.com/|Example]
690 => http://www.yoursite.com/shop/index.html
692 => http://www.example.com/
698 =item highlight_partial
700 If this is true then partial matches will be highlight in search
701 result excerpts. Default: True
703 =item keep_inaccessible
705 If this is true then resulting articles that can't be accessed by the
706 user are listed in the search results. Default: false.
710 The default regular expression used to match words in text during
711 indexing. Default: \w+
713 =item wordre_I<fieldname>
715 The field specific word match regular expression for the built-in
716 search indexer. Default: the value of C<wordre>.
720 Module used to build the search index. Default: BSE::Index::BSE.
724 For C<BSE::Index::BSE>, the optimization priority. The default of
725 C<speed> builds the index in memory and is very fast, but can consume
726 a lot of memory. Otherwise, set this to C<memory> to reduce memory
729 C<memory> priority index building requires that the DBM::Deep module
734 =head2 [search highlight]
736 Sets the prefix and suffix used for highlighting matches for different
739 These are used by the highlight_result, excerpt, pageTitle, author,
740 keywords and matchFile tags.
742 Each field has a prefix and suffix entry. The key is
743 I<fieldname>_prefix or I<fieldname>_suffix. For file fields this is
744 file_I<fieldname>_prefix and file_I<fieldname>_suffix.
746 The default prefix is <b>. The default suffix is </b>.
748 For example you can do:
751 body_prefix=<span class="searchfound">
760 Used by some templates to check if the shop is enabled. Set this to 1
761 to enable the shop, or 0 to disable it.
763 =item secureurl_articles
765 If this is false then shop articles will not use the secureurl as their
766 baseurl. Default: True
768 =item register_if_files
770 If true the customer is required to register before checkout if there
771 are any for sale files attached to products in the cart. Default: True
775 If true the customer is required to be logged on before checkout,
776 whether or not for sale files are attached to products in the cart.
781 A comma-separated list of acceptable payment types. Default: 0
783 The possible payment types are:
789 0 - the user enters a credit card number, name and expiry date
793 1 - the customer will send a cheque
797 2 - contact customer for details
801 4 - paypal - see L<paypal.pod>
805 Other types can be added by adding entries to the [payment type names]
806 and [payment type descs] sections.
814 These are used by various shop templates to present an address that a
815 cheque payment should be sent to.
819 From email address for emails sent by the shop. Overides $SHOP_FROM
824 To name for emailed orders sent by the shop. Overrides $SHOP_TO_NAME
829 To email for emailed orders sent by the shop. Overrides $SHOP_TO_EMAIL
834 BCC email address for order confirmation emails sent to the customer.
839 If this is true then orders sent to you by the shop will not be
840 encrypted. Enabling this disabled acceptance of credit card orders,
841 and the default for C<payment_types> will become C<1> instead or C<0>.
843 Please realize that other potentially commercially sensitive
844 information is being sent in the clear to a central location,
849 If true, then the order is email to to_email, possibly with credit
850 card information included. Default: $SHOP_EMAIL_ORDER.
852 =item display_I<field>
854 Used to translate the stored order field name into a presentation name
855 suitable for error messages.
859 The name of a class to load to process credit card transactions online.
861 Currently this can be either DevHelp::Payments::Test or
862 DevHelp::Payments::Inpho.
866 Name of the encryption module to use. Default: $SHOP_CRYPTO.
868 =item crypt_signing_id
870 Id of the key to sign the order email with. If this is non-empty then
871 the email is signed even if [basic].sign is false. Default:
876 Path to the GnuPG program. Default: $SHOP_GPG
878 =item crypt_passphrase
880 Passphrase of the key used to sign the email. Default:
885 If true, request the card type when requesting credit card
886 information. Default: False.
888 =item cart_entry_limit
890 Maximum number of entries in the cart. This limits the number of
891 distinct products (with options) in the cart, not the total
892 quantities. Default: Unlimited.
896 The shop currency as a 3-letter currency code. Default: AUD.
897 Currencies other than "AUD" aren't supported by most of the system.
901 Set to non-zero if you're using country codes in the order country
902 field. If this is set then the delivCountry is supplied as is to
903 various parts of the system, otherwise it is translated from a country
904 name to a country code. Default: 0.
914 A space-separated list of modules under Courier::, e.g. "Fastway::Road
915 AustraliaPost::Air". These will be made available as shipping methods
916 on the checkout page.
920 The post code from which products are shipped.
922 =item fastwayfranchisee
924 The name of the Fastway franchisee used to ship products from the
927 =item fastwayfranchiseecode
929 The Fastway franchisee code for the customer, if any.
933 =head2 [Shop Order Validation]
935 This section can contain extra order validation information, including
936 specifying required fields, display names and extra validation rules.
944 The maximum length of the article title field. Default: 255. Should
945 not be set higher than this unless you change the database schema.
951 Controls the interest.pl script.
957 Email address that is notified of the interest. Defaults to $SHOP_FROM.
969 When a user logs on, and the site url is different to the secure url
970 BSE attempts to refresh to the other "side" of the site to set the
973 BSE does some simple comparisons to attempt to determine whether the
974 logon form was triggered on the secure side of the site (possibly from
975 the shop) or on the insecure side. Since CGI doesn't necessarily give
976 us all the information required, it's possible it will guess wrong.
978 Setting this option to 1 will enable debugging information sent to
979 standard error, which will be sent to the error log on Apache. This
980 probably isn't useful on IIS.
984 Reports errors to STDERR (hence to the error log on Apache) if there
985 is a problem deleting the actual file when an attached file is
988 =item mail_encryption
990 Reports debugging information to standard error while encrypting your
995 Reports cookies received from the browser and sent to the browser to
996 STDERR (hence to the error log on Apache.)
1000 If nonzero the session hash is dumped to STDERR after it is retrived
1003 =item subscription_expiry
1005 If non-zero then subscription expiry date calculations are dumped to
1008 =item jit_dynamic_regen
1010 If non-zero then information about jit_dynamic_regen is sent to
1015 If non-zero then the ifUserCan tag will output some trace information
1022 Contains various URIs.
1024 This is underused, so don't rely on it yet.
1030 The URI to the CGI directory. Default: /cgi-bin
1034 The URI where images are kept. Default: /images
1044 This will provide translations from symbolic names to article ids.
1046 Currently this is used for converting article ids in the access
1047 control code, and for looking up the id of the shop.
1049 =head2 [printable type]
1051 If the user supplies a template name to printable.pl then you can use
1052 a different content type by adding an entry to this section. The key
1053 is the template name, and the value is the full content type.
1055 =head2 [search index scores]
1057 This section is used when generating the search index to override the
1058 default scores for each field in the articles.
1060 The default scores are:
1070 description 0 Products only
1071 product_code 0 Products only
1072 file_displayName 2 displayName for files
1073 file_description 2 description for files
1074 file_notes 1 notes for files
1076 =head2 [article flags]
1078 =head2 [product flags]
1080 =head2 [catalog flags]
1082 Flags that can be set for articles, products and catalogs
1083 respectively. Note that flags for articles are also visible in
1084 products and catalogs.
1086 All flag Ids are single letters or digits. Uppercase letters are
1087 reserved for use by BSE internally, leaving lower-case letters and
1088 digits for your own use.
1090 Use the id of the flag as the key, and a description of the flag as
1093 =head2 [article uris]
1095 Each key is an article id, the values are base URIs to store the HTML
1096 form of those articles and their children under.
1098 =head2 [protect link]
1100 The keys are ids of articles that shouldn't have their link field
1101 overwritten. The value should be a true value, but is otherwise
1110 The recipient for the data dump email sent by datadump.pl. Default:
1115 the From for the data dump email sent by datadump.pl. Default:
1122 Configuration for site users.
1128 If this is set to true then no passwords are required during
1129 registration, a confirmation email is sent immediately upon
1130 registration and that confirmation email contains a link the user can
1131 use to manage their details.
1133 This option has some security concerns since it can leave links to the
1134 user's information in the browser history. This option is not
1137 You cannot use this to control access to the shop.
1143 =item require_address
1149 =item require_postcode
1151 =item require_telephone
1153 =item require_facsimile
1155 =item require_country
1159 =item require_organization
1161 Set these to true to require the corresponding field during
1162 registration, and to keep it required after modification. Default:
1165 If you enable any of these, you should enable C<info_on_register> as
1166 well, or modify the registration template to include the given fields.
1168 =item display_I<field name>
1170 Controls how the given field is displayed in error messages. If you
1171 change the field names on the registration and/or options forms you
1172 should probably change them here too. Default: internal field name
1173 with the first character converted to upper-case.
1175 =item info_on_register
1177 If this is set then the user info is prompted for during user
1178 registration. The information still isn't required unless the
1179 appropriate require_I<field> option is set. Default: false.
1181 =item register_refresh
1183 The default URL to refresh to on completing registration if no r
1184 parameter is supplied.
1188 If this is set then the subcription checkboxes are all checked on
1189 registration by default. Default: false.
1191 The user will only receive the subscriptions if they leave them checked
1192 and follow the link in the confirmation email.
1194 =item subscribe_I<id>
1196 Where I<id> is the number identifying a subscription. If this is set
1197 then the subscription checkbox for that subscription will be checked
1198 by default on the registration form. Default: false.
1200 The user will only receive the subscriptions if they leave it checked
1201 and follow the link in the confirmation email.
1203 You can get the I<id> of a subcription by looking at the Edit link on the
1204 subscriptions management page, the number after "id=" is the id.
1206 =item billing_on_main_opts
1208 If set to zero then user billing options will be managed on a separate
1209 page. This is controlled by the user/options_base.tmpl template.
1213 If set to zero then users cannot register themselves. Default: true,
1214 allowing users to register themselves.
1216 =item notify_register
1218 If true then an email is sent when a new user registers on your site.
1219 The email address sent to is the first set of [site
1220 users].notify_register_email, [shop].from or $SHOP_FROM from
1223 No email is sent if a new user is created from the administration user
1226 See also: notify_register_email, notify_register_subject.
1228 =item notify_register_email
1230 The email to sent the registration notification too. See
1231 notify_register above.
1233 =item notify_register_subject
1235 The subject of the notification email sent when a new user registers.
1236 Any {I<field>} is replaced with the given field from the registered
1237 user. See notify_register above.
1239 Default: New user {userId} registered
1241 =item notify_register_customer
1243 If non-zero then email id C<notify_register_customer> will be sent to
1244 new user on registration. By default this uses template
1245 user/email_register, subject "Thank you for registering" which can be
1246 overridden in [email notify_register_customer]
1250 =head2 [payment type names]
1252 This section and [payment type descs] are used to configure new
1255 The key is the integer representing the payment type. The value is
1256 the name used in tags for checking the payment type.
1258 You can also add a description (currently unused) to [payment type
1261 You should use numbers starting from 10 to avoid conflicts with future
1264 =head2 [payment type descs]
1266 See [payment type names].
1268 =head2 [payment type required]
1270 Set the key given by the payment type id to a value of a
1271 comma-separated list of fields required for that payment type.
1273 =head2 [help style I<style-name>]
1275 This type of configuration section is used to set values for a style
1276 of help icon. Only the C<template> and C<prefix> values are used
1277 directly by the code, the others are used by the default helpicon
1284 The URI to the help files for this style. Default: /help/ in style
1285 "user", /admin/help/ in style "admin".
1289 The template used to produce the icon. Default: helpicon in style
1290 user, admin/helpicon in style "admin".
1294 URI to the help icon image. Default: /images/admin/help.gif
1298 The width of the help icon image. Default: 16
1302 The height of the help icon image. Default: 16
1306 If you just want to change the help icon image for user help icons you
1310 icon=/images/help.gif
1316 =item allowed_referer
1318 A semi-colon (;) separated list of referer domains that are allowed to
1319 link to the C<a_set> target of L<affiliate.pl>.
1321 If the user's browser supplies a referer header then it will be
1322 checked against this list.
1324 =item require_referer
1326 If this is set then the C<a_set> target of L<affiliate.pl> will
1327 require that the user's browser supply a Referer header.
1329 =item default_refresh
1331 If no C<r> parameter is supplied to the C<a_set> target of
1332 L<affiliate.pl> then this is used as the default refresh.
1334 Default: the site base url.
1336 =item subscription_required
1338 This is either the numeric or text of a subscription for which the
1339 affiliate must have an active subscription.
1343 A single letter flag which the site administrator must set for the
1344 affiliate page to be displayed for the given member.
1348 If this is set then affiliate.pl will set the named cookie to the
1353 This is a comma-separated list of other cookies that should be set by
1354 the a_set target. The values for the cookies should be passed to the
1355 a_set target. For example with:
1358 other_cookies=alpha,beta
1362 http://your.site.com/cgi-bin/affiliate.pl?a_set=1&id=someid&alpha=1&beta=2&gamme=3
1364 is accessed, then the cookie alpha is set to "1", beta is set to "2".
1365 The cookie gamma will not be set since it's not listed.
1369 Used as the link base URL for the afflink.tmpl side bar template when
1370 an affiliate id is set. Default: example.com
1374 Used at the text of the link for the afflink.tmpl side bar template
1375 when an affiliate id is set. Default: Your Site.
1379 Used as the link URL for the afflink.tmpl side bar template when an
1380 affiliate id is not set. Default: example.com
1384 Used as the text of the link for the afflink.tmpl side bar template
1385 when an affiliate id is not set. Default: Our site
1389 =head2 [BSE Siteuser Images]
1391 Each key is the id of a member image, with a corresponding [BSE
1392 Siteuser Image I<image_id>] section. The values are ignored.
1394 =head2 [BSE Siteuser Image I<image_id>]
1396 Provides information about a single member image "template".
1402 Short description on the image, like "Logo". Used in error messages.
1406 Longer description of the image. Accessible with the member_image tag.
1416 The minimum and maximum dimensions of the image.
1418 =item widthsmallerror
1420 =item heightsmallerror
1422 =item widthlargeerror
1424 =item heightlargeerror
1426 Error messages displayed in the when the image is outside the
1427 configured dimensions.
1433 Default error messages for the above.
1437 Maximum storage the image can use in bytes. Default: 1000000.
1441 Error message displayed if the image uses too much storage.
1447 Various editor settings.
1453 If this is non-zero the system will attempt to load the configured
1454 thumbnail class, and put thumbnail images on the image manager page
1455 rather than full-size images. Default: off
1459 The name of a perl class that implement's BSE's thumbnail API. At
1460 this point the only class that implements that is BSE::Thumb::Imager,
1461 supplied with BSE. Default: None
1463 =item default_thumbnail
1465 URI to the default thumbnail image. This is presented when the
1466 runtime production of a thumbnail image fails.
1468 =item default_thumbnail_width
1470 =item default_thumbnail_height
1472 Dimensions of the default thumbnail image.
1474 =item default_thumbnail_alt
1476 Alt text for the default thumbnail image.
1478 =item check_modified
1480 If this is true then BSE will check the value of the lastModified
1481 parameter passed against the value in the article. If these don't
1482 match the article isn't saved and is redisplayed with an error
1483 message. This provides simple protection against one user saving
1484 changes over those made by another.
1498 Default values for the thumbimage tag.
1504 Each value is used as the relative or absolute name of a file or
1505 directory to load more configuration data from.
1507 The keywords must remain unique.
1509 Only the [includes] section from bse.cfg itself is used to locate more
1512 If the value references a directory, all files with an extension of
1513 C<.cfg> are read for configuration data.
1515 The order the files are read (which later files overriding older
1526 the entries in [includes] are sorted alphabetically (or rather
1527 asciily), so an entry with key "A" is read before one with key "B",
1528 one with key "01" is read before "02", but key "10" would be read
1533 if an entry is a file then that is read and the values merged.
1537 if an entry is a directory, then that is scanned and the files found
1538 read alphabetically as above.
1544 This is used to configure the error icon displayed next to fields that
1551 URI to the image file.
1557 The width and height of the error icon image.
1561 =head2 [site user flags]
1563 Flags that can be set for site users.
1565 All flag Ids are single letters or digits. Uppercase letters are
1566 reserved for use by BSE internally, leaving lower-case letters and
1567 digits for your own use.
1569 Use the id of the flag as the key, and a description of the flag as
1572 =head2 [article defaults]
1574 =head2 [catalog defaults]
1576 =head2 [product defaults]
1578 These sections contain defaults values for the corresponding article
1581 Each key is the name of a column for the article type.
1583 If an entry is not found in [catalog defaults] then [article defaults]
1586 If an entry is not found in [product defaults] then [article defaults]
1589 These sections are checked B<after> the C<[children of >I<id>C<]> and
1590 C<[level >I<level>C<]> sections.
1592 These defaults are used when creating an article where no value is
1593 supplied, they can also be accessed via the <:default I<name>:> tag.
1595 =head2 [newsletter filters]
1597 Contains C<criteria>I<index> entries starting from C<criteria1>, then
1600 Each entry consists of a filter class name, followed by a ; followed
1601 by data passed to that filter.
1603 ; user the original SQL based filter, configured from
1605 criteria1=BSE::NLFilter::SQL;foo
1607 See the documentation for each filter to configure the filters.
1609 =head2 [Query Groups]
1611 The key of each entry is the numeric identifier of a query group, the
1612 values are the name of the query group. For example:
1617 [query group some name]
1618 sql=select id from site_users where id = ? and name1 like '%some%'
1620 Each entry also has a corresponding [Query Group I<name>] section.
1622 =head2 [query group I<name>]
1624 This section corresponds to an entry in [Query Groups].
1630 This is an SQL statement. One placeholder is required and is passed
1631 the siteuser id (primary key) of the user to be checked. If this
1632 query returns I<any> rows then the user is considered part of the
1637 =head2 [template types]
1639 Each key is a template name, the value is the content type to be used
1640 when displaying the template dynamically.
1642 =head2 [template descriptions]
1644 Each key is a template name, the value is a description used in the
1645 template dropdown for that template.
1649 This section defines CSS class names for BSE's body text link tags.
1650 The key is the tag name, the value is the CSS class to be used.
1652 By default the class used is the same as the name of the tag, but you
1653 can switch this off by adding an entry setting the class to the empty
1654 string, for example:
1656 ; no class attribute for any of the links
1663 You can set p here too to set the class for paragraphs generated as
1664 body text. By default no class is set.
1668 Controls the behaviour of the window displayed by the popimage[] body
1669 text tag. If the Javascript for this has been customized then this
1678 Extra width and height for the window beyond the size of the image.
1679 Default: no extra width or height.
1683 If set to non-zero popimage[] will attempt to centre the popup within
1684 the current window. Default: 0.
1694 This is used to configure the DevHelp::Payments::Inpho module.
1700 If this is set then the test parameters are used instead of the
1705 The URL to process requests through.
1707 Default: https://extranet.inpho.com.au/cc_ssl/process
1711 Inpho supplied user name.
1715 Inpho supplied password.
1719 The URL to process test requests through.
1723 The user to supply to test requests.
1727 The password to supply to test requests.
1733 This section controls whether some custom class methods are called:
1739 If this is non-zero then siteuser_saveopts is called.
1743 =head2 [levelI<level> menus]
1745 Where I<level> is the article level at which the defined menu options will be available.
1746 Configure each menu value and description as I<key> and I<value>.
1757 To create a menus using such values, use the "allkids_of" iterator "filter" option.
1761 <:iterator begin allkids_of -1 filter: [menu] == 2 :>
1765 =head2 [title alias]
1767 Enable the "titleAlias" article field and set which level it will be available.
1773 Where I<level> is the article "level" for which the "titleAlias" field should be enabled. To enable
1774 set the value to non-zero.
1781 The "titleAlias" can be used as an alternate "short" title for the given article, especially useful
1782 for space critical iterated menus. A template conditional can be used to display the "titleAlias"
1783 in place of the article "title" when appropriate.
1787 =head2 [thumb geometries]
1789 Each key represents a geometry identifier for use by the thumbimage[],
1790 gthumbimage[] body text tags and the <:thumbimage ...:>, <:gthumbimage
1791 ...:>, <:dthumbimage ...:> template tags.
1793 The key is the geometry identifier, the value is the geometry string
1796 The geometry string consists of:
1806 crop flag - if present
1814 The dimensions can be in any of the following forms:
1820 <width>x<height> - the desired maximum width and height. eg 200x150
1824 <width>x - the desired width, with the height calculated
1825 proportionally based on the source image size
1829 x<height> - the designed height, with the width calculated
1830 proportionally based on the source image size.
1834 <size> - the desired maximum size in both directions. so "200" is
1835 equivalent to "200x200"
1839 The crop flag is a single letter "c", if present then the image should
1840 be scaled so the smaller dimension matches the requested size, and the
1841 longer dimension will be cropped to fit.
1843 The fill if present is: fill(color) where color is a color recognized
1844 by the underlying graphics implementation. This should be at least
1845 hex web colors without the #, eg fill(FF0000) will fill with red.
1847 =head2 [thumb classes]
1849 Each key represents a geometry identifier for use by the thumbimage[],
1850 gthumbimage[] body text tags and the <:thumbimage ...:>, <:gthumbimage
1851 ...:>, <:dthumbimage ...:> template tags.
1853 The value is used as the class for the generated img tag.
1857 Each value represents a handler or script name for the <:dyntarget
1858 I<script> I<target> ...:> tag.
1860 Each key has a TARGET version and a no-TARGET version, with the key
1861 suffixed with C<_n>.
1863 The default C<nuser> target is C</cgi-bin/nuser.pl/user/TARGET>. The
1864 default no-target C<nuser> is C</cgi-bin/nuser.pl/user>.
1866 For other targets the default is
1867 C</cgi-bin/>I<script>C<.pl?a_TARGET=1> and
1868 C</cgi-bin/>I<script>C<.pl>.
1870 The string C<TARGET> is replaced with the target specified in the
1873 This, along with dyntarget is intended to allow a more "Web 2.0" type
1874 of access to BSE. eg. you might set:
1880 and have a rewrite rule:
1882 RewriteRule ^/xshop/(.*)$ /cgi-bin/nuser.pl/shop/$1 [PT]
1884 =head2 [popimage class I<classname>]
1886 This defines the settings for a class of images generated by the
1887 popimage[] and gpopimage[] body text markup tags. For example, the
1888 settings for C<popimage[imageid|foo]> can be found in section
1889 C<[popimage class foo]>.
1895 The html generated for this class. Tags of the form
1896 C<{>I<identifier>C<}> are replaced, where I<identifier> can be
1897 C<inline_> or C<outline_> followed by an image field name, for example
1898 C<inline_src> is the URL to the inline image.
1900 Default: <a href="{outline_src}" rel="lightbox[id]" target="_blank"><img src="{inline_src}" alt="{inline_alt}" width="{inline_width}" height="{inline_height}" border="0" /></a>
1902 The default may be tuned as needed.
1906 The inline image geometry. Default: editor (the value used for
1907 thumbnails on the admin side)
1911 The outline image geometry. If no value is supplied then the original
1912 image values are used.
1916 =head2 [mail resources]
1918 Each key is the identifier of a file that can be attached to
1919 BSE::ComposeMail emails. The value is comma separated filename,
1920 content type, inline status.
1922 The files are searched for through the template search mechanism, so
1923 the filename can be relative to either the master or local templates
1926 If the content type is not supplied, if the filename end in gif, png
1927 or jpg the appropriate content type is used, otherwise
1928 application/octet-stream.
1930 If the inline status is not supplied then images are considered
1931 inline, and other files arent.
1933 =head2 [shop registration]
1935 Each key represents a message id from attempts to checkout. Except
1936 the all key which covers all cases.
1938 If the C<all> key or the message id key is non-zero then the checkout
1939 page will redirect to registration instead of login if the cart or
1940 configuration requires that the user be logged in.
1942 =head2 [template I<template-name>]
1944 Settings for articles based on a particular template.
1948 =item no_cache_dynamic
1950 Controls whether a cache-control: no-cache header will be produced.
1951 Can be overridden with the A and B article flags. If not set the
1952 value of [article].no_cache_dynamic is used.
1958 Global settings for articles.
1962 =item no_cache_dynamic
1964 Controls whether a cache-control: no-cache header will be produced.
1965 Can be overridden with the A and B article flags or [template
1966 I<template-name>].no_cache_dynamic. If not set the value of
1967 [basic].no_cache_dynamic is used.
1973 For the <:recaptcha:> tag currently only used for fmail.pl.
1977 =item api_public_key
1979 =item api_private_key
1981 The public and private key you receive when you register with reCAPTCHA.
1983 =item error_I<error_code>
1985 Replace the error message for the given I<error_code> where
1986 I<error_code> is the reCAPTCHA error code
1987 (eg. "incorrect-captcha-sol") with dash replaced by underscore.
1991 error_incorrect_captch_sol=VERY BAD INPUT
1995 =head2 [global file metadata]
1997 Each key represents an item of metadata for files attached to
2000 The values are ignored.
2002 For each key, extra information is defined in the [file metadata
2005 =head2 [file metadata I<name>]
2007 Definition for the file metadata item I<name>.
2013 title - descriptive name of the metadata. Defaults to I<name>.
2017 rules - validation rules, separated by ;. Custom rules can be defined
2018 in [file metadata validation].
2022 ro - if non-zero the metadata cannot be modified directly by the admin
2023 (applications can still generate it). Default: writable.
2027 type - the data type of the metadata, any of string, text, enum,
2028 integer, real, image. If this is enum values must be defined and
2029 labels should be. Default: string.
2037 string - single line of text
2041 text - one or more lines of text
2045 integer - whole number
2049 real - number with decimal points
2053 enum - select from a list of possible values.
2063 values - semi-colon separated list of values for this metadata.
2067 labels - semi-colon separated list of labels for the values
2071 help - help html to display for the metadata
2075 data_name - (images only) the key to use to store the image data.
2076 Default: I<name>_data.
2080 width_name - (images only) the key to use to store the image width.
2081 Default: I<name>_width.
2085 height_name - (images only) the key to use to store the image height.
2086 Default: I<name>_height.
2090 cond - a perl expression indicating whether the metadata should be
2091 prompted for, for this file. $file is the file object. Default: 1.
2095 unit - text displayed after the entry box for the metadata. Default:
2096 empty. Useful for including a unit ("pixels") or format help
2101 =head2 [session cleanup]
2103 Controls the processing of the bse_session_clean.pl script.
2109 days - the minimum age in days of sessions to be removed. Default: 30.
2113 per - the number of records to remove per SQL delete request.
2118 count - the number of SQL delete requests to perform, maximum.
2123 optimize - whether to perform a table optimization after deleting
2124 records. Default: 1 (set to 0 to skip optimization)
2128 =head2 [nightly work]
2130 Controls the bse_nightly.pl script.
2136 jobs - a comma separated list of BSE background processes to run when
2137 bse_nightly.pl is run. Default: bse_session_clean
2141 I<other keys> - each key is a sort key, and the value is a single
2142 background task name. This allows add-ons to setup extra tasks
2143 without overwriting each other. The sugessted key format is:
2145 99 - two digit priority - 00 is executed first, 99 last
2146 package-name - name of package the task is for
2147 unique - extra text to make the key unique, if necessary
2153 Parameters controlling where cached information - eg. file upload
2160 class - the BSE::Cache compatible cache class. See the documentation
2161 of BSE::Cache::Cache, BSE::Cache::CHI or BSE::Cache::Memcached.
2167 Database connection parameters. These override the settings in
2168 Constants.pm which are deprecated.
2174 dsn - the DBI dsn used to connect to the database. Default:
2179 user - the logon to the database. Default: $Constants::UN
2183 password - the password for the user. Default: $Constants::PW.
2187 dbopts - a perl expression that should evaluate to a hash reference.
2188 Default: $Constants::DBOPTs, or an empty hashref.
2192 class - the database wrapper class to use. Default: BSE::DB::Mysql.
2193 No other values are currently supported.
2197 =head2 [extra a_config]
2199 Defines extra configuration to be returned from the BSE system
2202 Each key is the keyword in the returned JSON object. If the key
2203 already exists it is not overwritten.
2205 Each value is the name of a section in the BSE configuration. The
2206 strings "{level}", "{generator}", "{parentid}", "{template}" are
2207 replaced with their values from the article that config is being
2213 menu=level{level} menu
2221 menu: { alpha: "One", beta: "Two" }
2223 in the returned configuration
2225 =head2 [cookie names]
2227 This section maps BSE's default cookie names to alternate names. This
2228 can be useful if you have two BSE sites under the same domain and need
2229 to ensure they use different cookies.
2236 =head2 [siteuser updates]
2238 Each key identifies an update specification for userupdate.pl, the
2239 value is a description of the specification.
2241 See L<<[siteuser update I<specid>]>> for the rest of the import
2245 =head2 [siteuser update I<specid>]
2247 Currently contains only a single key:
2253 fields - a semi-colon separated list of fields to import. Must
2254 contain one of C<id> or C<userId> which is used as a key to identify
2255 the user to update. An C<x> entry is a field to ignore. Some fields,
2256 such as C<confirmed> may not appear in this list.
2262 Configuration for BSE's PayPal integration.
2264 It shouldn't be necessary to change any of the URLs.
2270 test - if true, then the PayPal sandbox is used, and the configuration
2271 entries starting in C<test_> are used. If false, PayPal is live, and
2272 configuration entries starting in C<live_> are used. Default: 1.
2276 test_api_username, test_api_password, test_api_signature - API
2277 credentials for test mode. Required in test mode.
2281 live_api_username, live_api_password, live_api_signature - API
2282 credentials for live mode. Required for live mode.
2286 test_ws_url - URL to make NVP requests through in test mode. Default:
2287 https://api-3t.sandbox.paypal.com/nvp
2291 test_refresh_url - PayPal URL to refresh to in test mode. Default:
2292 https://www.sandbox.paypal.com/webscr
2296 live_ws_url - URL to make NVP requests through in live mode. Default:
2297 https://api-3t.paypal.com/nvp
2301 live_refresh_url - PayPal URL to refresh to in live mode. Default:
2302 https://www.paypal.com/cgibin/webscr
2306 =head2 [paypal custom]
2308 Extra parameters supplied to the SetExpressCheckout API. See the
2309 Express Checkout Advanced Features Guide (from PayPal) for details.
2311 Some settings that may be useful:
2317 PAGESTYLE - the style of payment page to use from those listed in your
2322 HDRIMG - https URL to an image to use in the payment page header.
2326 HDRBACKCOLOR - a 6 hex digit color to use as the background of the
2327 payment page header.
2331 HDRBORDERCOLOR - a 6 hex digit color to use as the border of the
2332 payment page header.
2342 mail - if non-zero any emails sent through BSE::ComposeMail are logged
2343 in the audit log. Default: 0.
2347 mail_max_dump - if non-zero this is the size limit of the dump stored
2348 in the audit log when [audit log].mail is enabled.
2354 Tony Cook <tony@develop-help.com>