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 Dynamic Field | |
* Description: demonstrates how to place a value from the shortcode into a dynamic hidden field | |
*/ | |
class PDb_Custom_Dynamic_Field { | |
/** |
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 Export Absolute Image Paths | |
* Description: Shows how to include the absolute path to image files in a CSV export | |
* | |
*/ | |
class PDb_Image_Paths_Export { | |
/** |
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: Participants Database Alternate ID Field | |
* Version: 0.1 | |
* Description: allows the use of a custom field for the general ID that is used to show a record | |
* Author: xnau webdesign | |
*/ | |
class PDb_alternate_id_field { | |
/** |
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 Summary | |
* Description: provides a customized sum value for the "Work Log" log | |
* Version: 1.0 | |
* | |
*/ | |
class pdb_work_log_summary { | |
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
on any administrative page, add ?pdb-remove-orphan-columns to the URL, then hit return to execute it. | |
This will delete the columns that do not have a corresponding field definition from the main Participants Database table. | |
WARNING: THIS WILL DELETE DATA | |
Always work with a backup for operations like this. | |
for example: | |
https://xnau.com/wp-admin/admin/php?pdb-remove-orphan-columns |
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 | |
/** | |
* checks a signup submission for a valid email | |
* | |
* @return bool true to accept the submission, false to reject it | |
*/ | |
add_filter( 'pdb-check_submission', function() { | |
// this check is only applied to signups | |
if ( filter_input( INPUT_POST, 'action', FILTER_SANITIZE_STRING ) === 'signup' ) { |
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 | |
// adds a KML to a a Google Map | |
add_filter( 'pdbgmap-additional_map_code', 'xnau_add_kml' ); | |
/** | |
* adds a KML file to the map configuration | |
* | |
* this is based on the example at Google | |
* @see https://developers.google.com/maps/documentation/javascript/kml | |
* @param string $js_object empty string | |
* @return string a valid JS object |
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 show timestamp | |
* @version 2.0 | |
* | |
* template for displaying a single record | |
* | |
*/ | |
if ( $this->participant_id > 0 ) : | |
?> |
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: Participants Database Custom Signup Email Recipient | |
* Version: 0.1 | |
* Description: sets the signup notification email recipient based on a value in the signup submission | |
* Author: Roland Barker, xnau webdesign http://xnau.com | |
* | |
*/ |