Template Overrides
The plugin’s front-end templates can be overridden from your theme, so you can restyle output without editing the plugin.
Override order
Section titled “Override order”For any template, the plugin looks in this order and uses the first match:
yourtheme/academic-references/{template-name}.phpyourtheme/{template-name}.phpacademic-references/public/partials/{template-name}.php(plugin default)
To override a template, copy the plugin default into a folder named academic-references inside your active theme, then edit your copy.
Templates you can override
Section titled “Templates you can override”| Template | Used for |
|---|---|
single-reference.php |
The single reference view |
reference-library.php |
The [abt_reference_library] listing |
dashboard.php |
The [abt_dashboard] dashboard |
my-references-dashboard.php |
The user’s own references view |
submit-reference-form.php |
The front-end submission form |
edit-reference-form.php |
The front-end edit form |
import-references.php |
The front-end import form |
export-references.php |
The front-end export form |
Hooks for templates
Section titled “Hooks for templates”abt_locate_template- filter the resolved template path programmatically.abt_get_template_part- filter the arguments passed to a template part.abt_before_template_part/abt_after_template_part- actions that run around a template part, useful for injecting markup without copying the template.
add_filter( 'abt_locate_template', function ( $template, $template_name ) { if ( 'single-reference.php' === $template_name ) { return MY_PLUGIN_DIR . 'templates/single-reference.php'; } return $template;}, 10, 2 );
