Closed daprela closed 9 years ago
@daprela You can treat the config.php kind of like a functions.php in the sense that you can add hooks and hook JS listeners to the admin page using code something like this:
add_action( 'admin_print_footer_scripts','cta_tweettodownload_print_admin_scripts' );
function cta_tweettodownload_print_admin_scripts() {
$screen = get_current_screen();
if ( !isset( $screen ) || $screen->id != 'wp-call-to-action' || $screen->parent_base != 'edit' ) {
return;
}
?>
<script>
jQuery(document).ready(function() {
});
</script>
<?php
}
Then you could code this improvement in with pure JS listeners. If you wanted to do it I would not be opposed. It would exist as a good example to others on how they might make unusual admin settings changes.
I was thinking that it would be a good idea to add a charachters count in the text editor. Since the lenght of the message is limited to 120 characters, without a counter it's a bit hard to guess if you are out of the limit. I've analyzed the plugin code but it seems that this addition is not so simple, and it involves many modifications. Maybe I'm overcomplicating the issue, any idea?