Changes

Jump to navigation Jump to search
511 bytes removed ,  20:48, 19 August 2019
Mod version 3
Line 1: Line 1:  
{{TNGmod
 
{{TNGmod
 
| mod_name        = Field Buttons
 
| mod_name        = Field Buttons
|  mod_summary    = This strictly optional utility mod installs a Javascript library that supports Field Buttons, which must be defined by other Mods. It also defines a new TNG system parameter. By itself, it has no affect on TNG programs other than those that implement the Admin >> Setup >> General Settings form.
+
|  mod_summary    = This strictly optional utility mod installs a Javascript library that supports  
 +
"Field Buttons" that are placed in HTML forms by other mods.
 
| mod_validation  =  
 
| mod_validation  =  
| mod_last_update = 15 May 2018
+
| mod_last_update = 18 Aug 2019
| download_link  =  <div>[[Media:field_buttons_v12.0.0.2.zip|v12.0.0.2]]{{Tv120}}</div>
+
| download_link  =  <div>Beta: [[Media:field_buttons_v12.0.0.3.zip|v12.0.0.3]]{{Tv120}}</div>
<div>[[Media:field_buttons_v10.1.0.2.zip|v10.1.0.2]]{{Tv100}}</div>
+
<div>[[Media:field_buttons_v12.0.0.2.zip|v12.0.0.2]]{{Tv120}}</div>
 
| download_stats  =
 
| download_stats  =
 
| mod_author      = [[User:Robinrichm|Robin Richmond]]
 
| mod_author      = [[User:Robinrichm|Robin Richmond]]
Line 11: Line 12:  
| mod_contact    = [http://www.robinrichmond.com/family/mod_support.php My Mod Support form]
 
| mod_contact    = [http://www.robinrichmond.com/family/mod_support.php My Mod Support form]
 
| mod_support    = [http://robinr.org/family/mod_support.php My Mod Support form] or [http://tng.community/ TNG Community Forums]
 
| mod_support    = [http://robinr.org/family/mod_support.php My Mod Support form] or [http://tng.community/ TNG Community Forums]
| mod_version    = v10.1.0.2 & v12.0.0.2
+
| mod_version    = v12.0.0.3
 
| min_TNG_ver    = 10.1
 
| min_TNG_ver    = 10.1
| max_TNG_ver    = at least 12.0
+
| max_TNG_ver    = at least 12.1
 
|  TNG_file_list  = Modifies admin_genconfig.php, admin_updateconfig.php, genstyle.css, English cust_text.php;<br/>Installs js/fieldbuttonsmod.js  
 
|  TNG_file_list  = Modifies admin_genconfig.php, admin_updateconfig.php, genstyle.css, English cust_text.php;<br/>Installs js/fieldbuttonsmod.js  
 
| related_mods  = [[Admin_Branches]], [[Admin Cemeteries Search]], [[Admin Places Search]], [[Admin Reports Search]] [[Cemetery Edit]], [[Mod Manager Compare]], and possibly others.
 
| related_mods  = [[Admin_Branches]], [[Admin Cemeteries Search]], [[Admin Places Search]], [[Admin Reports Search]] [[Cemetery Edit]], [[Mod Manager Compare]], and possibly others.
Line 21: Line 22:  
To support the use of configurable "Field Buttons" by other mods, by installing  
 
To support the use of configurable "Field Buttons" by other mods, by installing  
 
* A Javascript library that is used by various TNG programs ''only if this mod has been installed'', and
 
* A Javascript library that is used by various TNG programs ''only if this mod has been installed'', and
* Administrative setup form fields that implement a new TNG system variable, '''$tngconfig['rrfieldbuttonflags']''', which allows Field Buttons types to be disabled.
+
* A mod option that control whether each type of field button is active.
 
{| style="margin-right:0.5 em;" align="right"  
 
{| style="margin-right:0.5 em;" align="right"  
 
| __TOC__
 
| __TOC__
Line 27: Line 28:     
This mod is needed only if a TNG site administrator,
 
This mod is needed only if a TNG site administrator,
* Installs at least one mod that defines Field Buttons, and
+
* Installs at least one mod that places Field Buttons in HTML forms, and
 
* Wants to see Field Buttons in forms.
 
* Wants to see Field Buttons in forms.
 
That is, if this mod has not been installed, no errors will occur; Field Buttons that have been defined by various other mods will simply not appear.
 
That is, if this mod has not been installed, no errors will occur; Field Buttons that have been defined by various other mods will simply not appear.
   −
The buttons are configurable in these senses:
+
The buttons are configurable in that
 
* The one-character labels for the field buttons are defined in cust_text.php, and can be changed for different languages.
 
* The one-character labels for the field buttons are defined in cust_text.php, and can be changed for different languages.
* The button labels change be changed - even given multple-character labels - by overriding the button definition string ($admtext['rrfb-buttonlabels']) in the English cust_text.php files
+
** The button labels change be changed - even given multple-character labels - by overriding the button definition string ($admtext['rrfb-buttonlabels']) in the English cust_text.php files
* Any of the four types of field buttons can be disabled through the configuration settings at Admin >> Setup >> General Settings >> Miscellaneous.
+
* Any of the four types of field buttons can be disabled through a mod option at '''Admin >> Setup >> General&nbsp;Settings >> Robin's&nbsp;Mods. (See documentation of this new subform)
    
==Field Buttons==
 
==Field Buttons==
Line 104: Line 105:     
==Compatibility & Dependencies With Other Mods==
 
==Compatibility & Dependencies With Other Mods==
This mod is compatible with other mods that modify the Admin >> Setup >> General Settings screen, and is not dependent on any other mods.  No mods are ''strictly'' dependent on this mod, but there functional dependency in that, when other mods install Field Buttons, this mod must be installed in order for those field buttons to be visible. No errors will occur if the Field Buttons mod is not installed in conjunction with mods that define Field Buttons. The forms will simple act as if the Field Buttons were not defined in the first place.  
+
No mods are ''strictly'' dependent on this mod, but there is a functional dependency in that, when other mods define Field Buttons in their HTML forms, this mod must be installed for those field buttons to be visible. No errors will occur if the Field Buttons mod is not installed in conjunction with mods that define Field Buttons. The forms will simple act as if the Field Buttons were not defined in the first place.  
    
== Installation ==
 
== Installation ==
===Requirements===
+
This mod uses the standard installation procedure, though it should be noted that this mod contains a mod subfolder that is shared with other mods that implement the "Inner Mod Menu" and that put their options in '''Admin >> Setup >> General&nbsp;Settings >> Robin's&nbsp;Mods'''.  As a result, as you unzip or copy the mod, you might get a warning noting that a folder already exists. You can just ignore that warning.
* A working TNG installation.
+
{{RobinInstallationBoilerplate}}
* An installed current version of the [[Mod Manager]].
  −
* You should backup files listed in the panel on the right.
  −
 
  −
===Automated Installation===
  −
# Remove and delete previous version of this mod.
  −
# Backup the files updated by this mod.  They are listed in the panel at the upper right.
  −
# Download the .zip file, Extract its .cfg file to the mods folder.
  −
# Follow the normal automated installation for Mod Manager, as shown in the example [[Mod Manager - Installing Config Files]].
  −
 
  −
=== In the event of a problem ===
  −
# Try using the [[Mod_Manager_-_Installing_Config_Files#Remove_Mod_Steps|Mod Manager Remove]] capability
  −
# Contact me through [http://www.robinrichmond.com/family/mod_support.php My Mod Support form].
      
== Language Strings ==
 
== Language Strings ==
This mod defines several strings for use by the Admin >> Setup >> General Settings form, but two language strings that are used for the operation of field buttons are worth mentioning here.
+
This mod defines several strings for the Admin program that defines my mod options, but two language strings that are used for the operation of field buttons are worth mentioning here.
 
* <code>$admtext['rrfb-buttonlabels'] = "X,R,D,A";</code> defines the four letters that identify the four types of field buttons.
 
* <code>$admtext['rrfb-buttonlabels'] = "X,R,D,A";</code> defines the four letters that identify the four types of field buttons.
 
* <code>$admtext['rrfb-all'] = "all";</code> defines the value that represents "All Items" to 'Results per page' fields implemented by several options.
 
* <code>$admtext['rrfb-all'] = "all";</code> defines the value that represents "All Items" to 'Results per page' fields implemented by several options.
Both strings can be changed for any other language in that language's cust_text definitions.  And it be change
+
 
<syntaxhighlight lang="php" enclose="div">
  −
## The buttons labels - for all mods that use them
  −
$admtext['rrfb-buttonlabels'] = 'X,R,D,A';
  −
$admtext['rrfb-all'] = 'all'; #The value that fields are set to for "All items"
  −
</syntaxhighlight>
  −
The PHP and Javascript code that handle Field Buttons and the 'Results per page' feature always use the translation strings rather than hardcoded values, so these values can be changed to any value you may want in other languages.
   
   
 
   
 
== Revision History ==
 
== Revision History ==
*** The latest version of the mod is at the top of this table ***
+
{| border="1" cellspacing="1" cellpadding="2" class="wikitable"
{| border="0" cellspacing="1" cellpadding="2" class="wikitable"
   
! Mod Version !! TNG Version !! Date !! Note
 
! Mod Version !! TNG Version !! Date !! Note
 
|-  
 
|-  
| [[Media:modname_v12.0.0.2.zip|12.0.0.2]]
+
| [[Media:field_buttons_v12.0.0.3.zip|12.0.0.3]]
 +
| 12.0+
 +
| 18 Aug 2019
 +
| The field buttons behave as they did before, but the Field Buttons API has changed slightly.
 +
* The previous version allowed (actually, required) some mods to directly access the library's internal variables.
 +
* The previous version didn't accommodate some situations where changes to HTML form fields should change the state of the form fields' field buttons.
 +
* Mods written for Field Buttons version 2 can sometimes result in program crashes if the Field Buttons mod is not installed.
 +
* Mods released before August, 2019 should be able to work with version 3 of the Field Buttons mod.
 +
* Mods released after August 1, 2019 cannot work with version 2 of the mod.
 +
|-
 +
| [[Media:field_buttons_v12.0.0.2.zip|12.0.0.2]]
 
| 12.0+
 
| 12.0+
 
| 15 May 2018
 
| 15 May 2018
 
| No functional changes; made compatible with TNGv12.
 
| No functional changes; made compatible with TNGv12.
 
|-  
 
|-  
| 10.1.0.2
+
| [[Media:field_buttons_v10.1.0.2.zip|v10.1.0.2]]
 
| 10.1 - 11.1.2+
 
| 10.1 - 11.1.2+
 
| 9 Jan 2018
 
| 9 Jan 2018
'''Experienced'''
5,069

edits

Navigation menu