This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: PDB Autosuggest Term Cache Set | |
* Description: shows how to set the cache time for the Combo Multisearch autrosuggest term list | |
* | |
*/ | |
// set the cache time to 1 second, effectively bypassing it | |
add_filter( 'pdbcms-autosuggest_term_list_expiration', function( $cache_time ) { return 1; } ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: PDB Custom Format Tag | |
* Description: shows how to add a custom formatting tag for use in a Participants Database calculated field | |
* Version: 1.0 | |
* Tutorial: https://xnau.com/using-custom-format-tags-for-calculation-fields/ | |
* | |
* this requires Participants Database version 2.4.8 or later! | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* Plugin Name: PDb Multi-Field Match Import | |
* Description: Demonstrates how to set up a multiple-field match when a signup form is submitted or importing a CSV to Participants Database | |
* Version: 2.0 | |
* | |
*/ | |
class PDb_Multifield_Match_Import { | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* when the user opens their record for editing, we check on their approval status | |
* and then select the shortcode to use based on that. | |
*/ | |
switch ( $this->participant_values['approved'] ) { | |
case 'yes' : | |
echo do_shortcode( '[pdb_record]' ); | |
break; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: PDB Custom Log Sum | |
* Description: calculates a summary value for a participant log | |
*/ | |
class pdb_custom_log_sum { | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$wp_locale_conversion = array( | |
'af' => array( | |
'name' => 'Afrikaans', | |
'code' => 'af', | |
'wp_locale' => 'af' | |
) , | |
'ak' => array( | |
'name' => 'Akan', | |
'code' => 'ak', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @name pdb single template | |
* @version 2.2 | |
* | |
* demonstrates how to skip displaying a field based on a value in the record | |
* | |
* you will need to change 3 values: | |
* 'conditional_field' should be the name of the field you may want to skip showing | |
* 'check_field' should be the name of the record value you are checking |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* | |
* template for the signup form | |
* | |
* shows an example of letting the selected value of a radio control enable or disable another field | |
* | |
*/ | |
?> | |
<script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @version 1.1 | |
* | |
* PDbList template demonstrating how to show a "reverse" table with records as | |
* columns and fields as rows | |
* | |
*/ | |
/** @var PDb_List $this */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: PDb With Selected Signup Email | |
* Description: adds the send signup email item to the "with selected" function | |
*/ | |
add_filter( 'pdb-admin_list_with_selected_actions', function ( $actions ) { | |
return $actions + array( | |
'send signup email' => 'send_signup_email' | |
); |