Created
April 5, 2016 17:25
-
-
Save thomasplevy/b1b99f7cb64ad5e58177a1d73c5b7f15 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php // don't include this when pasting | |
| add_action( 'wp_print_footer_scripts', 'i_know_this_is_bad' ); | |
| function i_know_this_is_bad() { | |
| // lets only load this on lessons where it would be used | |
| if ( 'lesson' === get_post_type() ) { | |
| echo " | |
| <script> | |
| jQuery( document ).ready( function() { | |
| var $btn = jQuery( 'input[name=\"mark_complete\"]' ); | |
| $btn.hide(); | |
| setTimeout( function() { | |
| $btn.show(); | |
| }, 10000 ); | |
| } ); | |
| </script> | |
| "; | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment