Presentation is loading. Please wait.

Presentation is loading. Please wait.

Plugins & Hooks (Basics) Introduction to Concepts and Basic Examples

Similar presentations


Presentation on theme: "Plugins & Hooks (Basics) Introduction to Concepts and Basic Examples"— Presentation transcript:

1 Plugins & Hooks (Basics) Introduction to Concepts and Basic Examples
Rob Taylor Lead Developer · REDCap Development Team Kyle McGuffin Senior Application Developer · Vanderbilt Data Core Team

2 REDCap is… Data management platform Developer platform Collecting data
Administering surveys And more Developer platform Plugins and Hooks are used to extend REDCap’s capabilities for customization purposes without modifying the REDCap base code Documentation for Hooks and Plugins is found on left-hand menu of your Control Center in REDCap

3 Hooks vs. Plugins (vs. External Modules)
Are PHP scripts external to REDCap Can appear as if part of REDCap (but are not) Cannot affect behavior or look of existing REDCap pages Hooks… Are PHP scripts executed internally by REDCap in specific places in the application Can affect behavior or look of REDCap pages External Modules… (coming soon) Are the next generation of REDCap plugins and hooks Are kind of a hybrid of plugins and hooks Will be able to be downloaded from the external modules “app store” and enabled by a REDCap administrator on a given project

4 Hooks vs. Plugins (vs. External Modules)
Plugin examples Extra page in a REDCap project Simple dashboards and reports Entire web applications that sit on top of REDCap Hook examples Customize a survey page, data entry form, etc. Perform additional back-end operations on data entry forms, survey pages, or during a “save record” event External Module examples @NONEOFTHEABOVE action tag hook On Condition module (similar to Auto-Notify plugin)

5 SDK Developer methods for Plugins & Hooks
REDCap::allowProjects REDCap::allowUsers REDCap:: REDCap::escapeHtml REDCap::filterHtml REDCap::getCopyright REDCap::getData REDCap::getDataDictionary REDCap::getEventIdFromUniqueEvent REDCap::getEventNames REDCap::getExportFieldNames REDCap::getFieldNames REDCap::getFieldType REDCap::getGroupNames REDCap::getInstrumentNames REDCap::getPDF REDCap::getParticipant REDCap::getParticipantList REDCap::getProjectTitle REDCap::getProjectXML REDCap::getRecordIdField REDCap::getSurveyLink REDCap::getSurveyQueueLink REDCap::getSurveyReturnCode REDCap::getUserRights REDCap::getUsers REDCap::isLongitudinal REDCap::logEvent REDCap::saveData REDCap::versionCompare

6 Hook functions redcap_add_edit_records_page redcap_control_center redcap_custom_verify_username redcap_data_entry_form redcap_data_entry_form_top redcap_every_page_before_render redcap_every_page_top redcap_project_home_page redcap_save_record redcap_survey_complete redcap_survey_page redcap_survey_page_top redcap_user_rights

7 Demos & Examples with Kyle


Download ppt "Plugins & Hooks (Basics) Introduction to Concepts and Basic Examples"

Similar presentations


Ads by Google