Require box score importer to be accessed from within an event

This commit is contained in:
Brian Miyaji
2017-11-18 18:57:23 +11:00
parent fbf385258b
commit 77f46b23b0
3 changed files with 20 additions and 19 deletions

View File

@@ -116,16 +116,6 @@ class SP_Admin {
})(jQuery);
</script>
<?php
} elseif ( 'post.php' === $pagenow ) {
?>
<script type="text/javascript">
(function($) {
$(".wrap .page-title-action").first().after(
$("<a class=\"add-new-h2\" href=\"<?php echo esc_url( admin_url( add_query_arg( array( 'import' => 'sp_event_performance_csv' ), 'admin.php' ) ) ); ?>\"><?php _e( 'Import Box Score', 'sportspress' ); ?></a>")
);
})(jQuery);
</script>
<?php
}
} else {
if ( 'edit.php' === $pagenow ) {