Hi,
Yes you’re on the right way, I think it should work now, but please here are some considerations:
1) It’s better to add custom javascript outside the plugin, otherwise new updates will remove your code
To do that you can add this code in your THEME functions.php:
function my_custom_scripts() {
wp_enqueue_script( ‘custom-script’, get_template_directory_uri() . ‘/js/my-custom-scripts.js’, array( ‘jquery’ ));
}
add_action( ‘wp_enqueue_scripts’, ‘my_custom_scripts’ );
So you can create a file in your THEME/js/my-custom-scripts.js
Here you can insert the code you wrote.
2) Make sure the “newvalue” is a correct value for “aws_price_calc_4”. I mean, what kind of field is #aws_price_calc_4? a numeric field, option field, etc?
Best regards
Ennie
AT101