| 1 |
<?php if (!defined ('ABSPATH')) die ('No direct access allowed'); ?> |
| 2 |
<div class="wrap"> |
| 3 |
<?php screen_icon(); ?> |
| 4 |
|
| 5 |
<h2><?php _e ('Redirection Log', 'redirection'); ?></h2> |
| 6 |
|
| 7 |
<?php $this->render( 'submenu', array( 'options' => $options ) ); ?> |
| 8 |
|
| 9 |
<form action="tools.php"> |
| 10 |
<input type="hidden" name="page" value="redirection.php"/> |
| 11 |
<input type="hidden" name="sub" value="<?php echo esc_attr( $type ); ?>"/> |
| 12 |
|
| 13 |
<?php $table->search_box( __( 'Search' ), 'search_id' ); ?> |
| 14 |
</form> |
| 15 |
|
| 16 |
<form method="POST" action=""> |
| 17 |
<?php $table->display(); ?> |
| 18 |
|
| 19 |
<h3><?php _e( 'Log Management', 'redirection' ); ?></h3> |
| 20 |
|
| 21 |
<?php wp_nonce_field( 'redirection-log_management' ); ?> |
| 22 |
|
| 23 |
<p><?php _e( 'These apply to the current search term, if any, otherwise all logs.', 'redirection' ); ?></p> |
| 24 |
<p> |
| 25 |
<input class="button action" type="submit" name="delete-all" value="<?php esc_attr_e( 'Delete All' ); ?>"/> |
| 26 |
</p> |
| 27 |
<p> |
| 28 |
<input class="button action" type="submit" name="export-csv" value="<?php esc_attr_e( 'Export To CSV' ); ?>"/> |
| 29 |
</p> |
| 30 |
</form> |
| 31 |
|
| 32 |
<div style="clear: both"></div> |
| 33 |
</div> |
| 34 |
|
| 35 |
<?php $this->render( 'add', array( 'hidden' => true ) )?> |
| 36 |
|
| 37 |
<script type="text/javascript"> |
| 38 |
( function( $ ) { |
| 39 |
$( document ).ready( function() { |
| 40 |
var logs = new Redirection_Logs( $, '#add', '#added', '#old' ); |
| 41 |
var adder = new Redirection_Add( $, '#target', false ); |
| 42 |
|
| 43 |
adder.setup( 'select[name=red_action]', '#add' ); |
| 44 |
logs.setup( '.add-log' ); |
| 45 |
} ); |
| 46 |
} )( jQuery ); |
| 47 |
</script> |
| 48 |
|