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.0 3.6.0 3.6.1 3.6.2 3.6.3 3.6.4 3.7.0 3.7.1 3.7.2 3.7.3 3.7.4 3.8.0 3.8.1 3.8.2 3.8.3 3.9.0 3.9.1 3.9.10 3.9.2 3.9.3 3.9.4 3.9.5 3.9.6 3.9.7 3.9.8 3.9.9
tutor / views / pages / tools / tutor_pages.php
tutor / views / pages / tools Last commit date
status.php 4 years ago tutor_pages.php 4 years ago
tutor_pages.php
114 lines
1 <?php
2 $tutor_pages = tutor_utils()->tutor_pages();
3 ?>
4
5 <div id="tools-tutor-pages" class="tools-tutor-pages">
6 <table class="tutor-table tutor-pages-table">
7 <thead>
8 <tr>
9 <th><?php _e( 'ID', 'tutor' ); ?></th>
10 <th><?php _e( 'Page Name', 'tutor' ); ?></th>
11 <th><?php _e( 'Status', 'tutor' ); ?></th>
12 </tr>
13 </thead>
14 <tbody>
15 <?php
16 foreach ( $tutor_pages as $page ) {
17 $page_id = $page['page_id'];
18 ?>
19 <tr>
20 <td><?php echo esc_attr( $page_id ); ?></td>
21 <td>
22 <p>
23 <?php
24 if ( $page['page_exists'] ) {
25 $edit_url = admin_url( "post.php?post={$page_id}&action=edit" );
26 echo '<a href="' . esc_url( $edit_url ) . '" target="_blank">'. $page['page_name'] .'</a>';
27 } else {
28 echo $page['page_name'];
29 }
30 ?>
31 </p>
32 </td>
33
34 <td>
35 <?php if ( ! $page_id ): ?>
36 <p style="color: red;">
37 <i class="dashicons dashicons-warning"></i> <?php _e( ' Page not set', 'tutor' ); ?>
38 </p>
39 <?php endif; ?>
40
41 <?php if ( ! $page['page_exists'] ): ?>
42 <p style="color: red;">
43 <i class="dashicons dashicons-warning"></i>
44 <?php _e( ' Page deleted, please set new one', 'tutor' ); ?>
45 </p>
46 <?php endif; ?>
47
48 <?php if ( $page['page_exists'] && ! $page['page_visible'] ): ?>
49 <p style="color: red;">
50 <i class="dashicons dashicons-warning"></i>
51 <?php _e( 'Page visibility is not public', 'tutor' ); ?>
52 </p>
53 <?php endif; ?>
54
55 <?php
56 if ( $page['page_exists'] && $page['page_visible'] ) {
57 $page = get_post( $page_id );
58 echo '<a href="' . get_permalink( $page ) . '" target="_blank" style="color: green;">
59 <i class="dashicons dashicons-yes-alt"></i> /' . esc_attr( $page->post_name ) . '
60 </a>';
61 }
62 ?>
63 </td>
64 </tr>
65 <?php
66 }
67 ?>
68 <tr>
69 <td><?php echo $page_id; ?></td>
70 <td>
71 <?php
72 echo "<p>";
73
74 if ($page['page_exists']){
75 $edit_url = admin_url("post.php?post={$page_id}&action=edit");
76 echo "<a href='{$edit_url}' target='_blank'>";
77 }
78 echo $page['page_name'];
79
80 if ($page['page_exists']){
81 echo '</a>';
82 }
83 echo "</p>";
84 ?>
85 </td>
86
87 <td>
88 <?php
89 if ( ! $page_id ){
90 echo '<p style="color: red;">';
91 echo "<i class='dashicons dashicons-warning'></i> "; _e(' Page not set', 'tutor');
92 echo '</p>';
93 }
94 ?>
95
96 <form action="" method="post">
97 <?php
98 tutor_action_field( 'regenerate_tutor_pages' );
99 tutor_nonce_field();
100 ?>
101
102 <p>
103 <button class="tutor-btn" type="submit"><?php _e('Re-Generate Tutor Pages','tutor'); ?></button>
104 </p>
105 </form>
106 </td>
107 </tr>
108 </tbody>
109 </table>
110 <?php
111 tutor_alert( __( 'Note: This tool will install all the missing Tutor pages. Pages already defined and set up will not be replaced.', 'tutor' ), 'info' );
112 ?>
113 </div>
114