refactor: Reimplement calculator logic with new JavaScript and PHP files, removing numerous old Python scripts and related content.
This commit is contained in:
22
hdyc-csp-fix.php
Normal file
22
hdyc-csp-fix.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
/**
|
||||
* Plugin Name: HDYC CSP Calculator Fix
|
||||
* Description: Enqueues the universal calculator script for CSP compliance.
|
||||
* Version: 1.0
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
function hdyc_enqueue_calculator_script() {
|
||||
// Note: Assuming hdyc-calculators.js is in the same directory as this plugin
|
||||
wp_enqueue_script(
|
||||
'hdyc-calculators',
|
||||
plugins_url( 'hdyc-calculators.js', __FILE__ ),
|
||||
array(),
|
||||
'1.1',
|
||||
true
|
||||
);
|
||||
}
|
||||
add_action( 'wp_enqueue_scripts', 'hdyc_enqueue_calculator_script' );
|
||||
Reference in New Issue
Block a user