source: trunk/www.guidonia.net/wp/wp-content/plugins/lexi/templates/lexi_manage.php@ 44

Last change on this file since 44 was 44, checked in by luciano, 15 years ago
File size: 4.7 KB
Line 
1<?php
2 global $wp_query;
3
4 //Actions messages
5 if(count($messages)>0) {
6 echo "<div class='updated'>";
7 foreach($messages as $message) {
8 echo "<p><strong>$message</strong></p>";
9 }
10 echo "</div>";
11 }
12
13 //if pressed deletespam, delete all spam
14 if($_POST['deletespam']) {
15 sk_deleteSpam();
16 }
17
18?>
19<div class="wrap">
20 <div id="icon-tools" class="icon32"><br /></div>
21 <h2><?php _e( 'Lexi', 'lexi' ); ?></h2>
22 <form name="form1" method="post" action="<?php echo add_query_arg(array('mode'=>'', 'text'=>$text)); ?>"><?
23 $feedlist = $wpdb->get_results("SELECT * FROM $table_name ORDER BY position ASC");
24 $max_position = $wpdb->get_var("SELECT MAX(position) FROM $table_name");
25 $count=count($feedlist);
26 if($count==0) { ?>
27 <div class="clear"></div>
28 <p><?php _e('No feeds found', 'lexi') ?> <input type="submit" value="<?php _e( 'Add Feed', 'lexi' ); ?>" class="button" name="addfeed" /></p><?php
29 } else { ?>
30 <div class="tablenav">
31 <div class="alignleft actions">
32 <select name="action">
33 <option value="-1" selected="selected"><?php _e('Bulk Actions'); ?></option>
34 <option value="delete"><?php _e('Delete'); ?></option>
35 </select>
36 <input type="submit" name="doaction" id="doaction" value="<?php _e('Apply'); ?>" class="button-secondary apply" />
37 <input type="hidden" id="_wpnonce" name="_wpnonce" value="c70ddc4ef7" /><input type="hidden" name="_wp_http_referer" value="/wordpress/wp-admin/edit-feeds.php" />
38 <input type="submit" value="<?php _e( 'Add Feed', 'lexi' ); ?>" class="button" name="addfeed" />
39 </div>
40 <br class="clear" />
41 </div>
42 <div class="clear"></div>
43 <table class="widefat feeds fixed" cellspacing="0">
44 <thead>
45 <tr>
46 <th scope="col" id="cb" class="manage-column column-cb check-column" style=""><input type="checkbox" /></th>
47 <th scope="col" width="90%" style=""><?php _e( 'Feed' , 'lexi'); ?></th>
48 <th scope="col" width="80px" style=""><div align="center"><?php _e( 'Show contents' , 'lexi'); ?></div></th>
49 <th scope="col" width="80px" style=""><div align="center"><?php _e( 'Save cache' , 'lexi'); ?></div></th>
50 </tr>
51 </thead>
52 <tbody id="the-feed-list" class="list:feed"><?
53 foreach($feedlist as $feed) { ?>
54 <tr id='feed-<?php echo $feed->id; ?>'>
55 <th scope="row" class="check-column"><input type='checkbox' name='checked_feeds[]' value='<?php echo $feed->id; ?>' /></th>
56 <td>
57 <strong><?php echo $feed->name." (".$feed->items.")"; ?></strong><br /><?php echo $feed->ip; ?>
58 <div class="row-actions">
59 <span><a href="<?php echo wp_nonce_url(add_query_arg( array('mode' => 'edit', 'id' => $feed->id) ), 'lexi_editfeed')?>" class='edit'><?php _e('Edit', 'lexi') ?></a></span>
60 <span class='delete'> | <a href="<?php echo wp_nonce_url(add_query_arg( array('mode' => 'delete', 'id' => $feed->id) ), 'lexi_deletefeed')?>" class="delete" onclick="javascript:check=confirm( '<?php _e("Delete this Feed?",'lexi')?>');if(check==false) return false;"><?php _e('Delete', 'lexi') ?></a></span>
61 <span class='edit'><?php if($feed->position!=1) {?> | <a href="<?php echo wp_nonce_url(add_query_arg( array('mode' => 'up', 'id' => $feed->id) ), 'lexi_upfeed')?>" class='edit'> <?php echo "<img src='../wp-content/plugins/lexi/img/up.png' border='0'>"; ?></a><?php } ?></span>
62 <span class='edit'><?php if($feed->position!==$max_position) { ?> | <a href="<?php echo wp_nonce_url(add_query_arg( array('mode' => 'down', 'id' => $feed->id) ), 'lexi_downfeed')?>" class='edit'> <?php echo "<img src='../wp-content/plugins/lexi/img/down.png' border='0'>"; ?></a><?php } ?></span>
63 </div>
64 </td>
65 <td class="feed column-feed"><div align="center"><?php if($feed->showcontent) echo "<img src='../wp-content/plugins/lexi/img/yes.png'>"; else echo "<img src='../wp-content/plugins/lexi/img/no.png'>";?></div></td>
66 <td><div align="center"><?php if($feed->cached) echo "<img src='../wp-content/plugins/lexi/img/yes.png'>"; else echo "<img src='../wp-content/plugins/lexi/img/no.png'>";?></div></td>
67 </tr><?php
68 } ?>
69 </tbody>
70 </table>
71 <div class="tablenav">
72 <div class="alignleft actions">
73 <select name="action2">
74 <option value="-1" selected="selected"><?php _e('Bulk Actions'); ?></option>
75 <option value="delete"><?php _e('Delete'); ?></option>
76 </select>
77 <input type="submit" name="doaction2" id="doaction2" value="<?php _e('Apply'); ?>" class="button-secondary apply" />
78 <input type="hidden" id="_wpnonce" name="_wpnonce" value="c70ddc4ef7" /><input type="hidden" name="_wp_http_referer" value="/wordpress/wp-admin/edit-feeds.php" />
79 <input type="submit" value="<?php _e( 'Add Feed', 'lexi' ); ?>" class="button" name="addfeed" />
80 </div>
81 <br class="clear" />
82 </div><?php
83 } ?>
84 </form>
85</div>
Note: See TracBrowser for help on using the repository browser.