Advanced Database Cleaner - Version 1.1.0

Version Description

Download this release

Release Info

Developer symptote
Plugin Icon 128x128 Advanced Database Cleaner
Version 1.1.0
Comparing to
See all releases

Code changes from version 1.0.0 to 1.1.0

README.txt CHANGED
@@ -1,33 +1,42 @@
1
=== Advanced Database Cleaner ===
2
Contributors: symptote
3
- Tags: wordpress database cleaner, clean database, database, clean, cleaner, delete orphan data, delete revisions, delete draft, delete trash, delete spam, delete auto drfat, delete postmeta, commentmeta, relationships, transient feed, optimize database, optimize
4
Requires at least: 2.7
5
Tested up to: 4.3
6
- Stable tag: 1.0.0
7
License: GPLv2 or later
8
License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
10
- Advanced Database Cleaner helps you remove all unused data such as "draft", "Spam Comments", "Orphan Postmeta", etc.
11
12
== Description ==
13
- Advanced Database Cleaner is a must-have plugin that cleans your Wordpress database by removing unused data such as "revision", "draft", "auto draft", "moderated comments", "spam comments", "trash comments", "orphan postmeta", "orphan commentmeta", "orphan relationships", "dashboard transient feed".
14
- It helps you optimize your Wordpress database and save space of your MySQL DB.
15
- It cleans your database by one click.
16
- The settings page allows you choose what data should be cleaned.
17
- It is a must-have plugin to keep your database clean.
18
19
== Installation ==
20
This section describes how to install the plugin and get it working.
21
22
- WordPress:
23
-
24
- 1. Download and extract 'advanced-db-cleaner' to 'wp-content/plugins/'
25
2. In wordpress 'Plugins' page, choose 'Activate'
26
- 3. Go to "Dashboard" -> "Settings" -> "DB Cleaner"
27
28
== Screenshots ==
29
- 1. Admin page screenshot
30
31
== Changelog ==
32
= 1.0.0 =
33
* First release
1
=== Advanced Database Cleaner ===
2
Contributors: symptote
3
+ Tags: plugin, plugins, plugin wordpress, wordpress, database cleaner, clean database, database clean, database, clean, cleaner, delete orphan data, delete revisions, delete draft, delete trash, delete spam, delete auto drfat, delete postmeta, delete commentmeta, delete relationships, delete transient feed, optimize database, database optimize, optimize, admin
4
Requires at least: 2.7
5
Tested up to: 4.3
6
+ Stable tag: 1.1.0
7
License: GPLv2 or later
8
License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
10
+ Advanced Database Cleaner helps you remove all unused data such as "draft", "revision", etc. It helps also optimize your database.
11
12
== Description ==
13
+
14
+ <h4>Description</h4>
15
+ <br>
16
+ Advanced Database Cleaner is a must-have plugin that cleans your WP database by:<br><br>
17
+ 1. Removing unused data such as "revision", "draft", "auto draft", "moderated comments", "spam comments", "trash comments", "orphan postmeta", "orphan commentmeta", "orphan relationships", "dashboard transient feed".<br>
18
+ 2. It helps you optimize your Wordpress database and save space of your MySQL DB.
19
+ <br><br>
20
+ * It cleans your database by one click.<br>
21
+ * The settings page allows you choose what data should be cleaned.<br>
22
+ * It is a must-have plugin to keep your database clean.<br>
23
24
== Installation ==
25
This section describes how to install the plugin and get it working.
26
27
+ 1. Download and extract 'advanced-database-cleaner' to 'wp-content/plugins/'
28
2. In wordpress 'Plugins' page, choose 'Activate'
29
+ 3. Go to "Dashboard" -> "Settings" -> "Database Cleaner"
30
31
== Screenshots ==
32
+ 1. "Clean database" admin page screenshot
33
+ 2. "Optimize database" admin page screenshot
34
35
== Changelog ==
36
+
37
+ = 1.5.0 =
38
+ * Some optimizations and style modifications
39
+ * Adding "Optimize Database"
40
+
41
= 1.0.0 =
42
* First release
advanced-db-cleaner-admin.php CHANGED
@@ -1,12 +1,24 @@
1
<?php
2
3
- add_action('admin_menu', 'adv_db_cleaner_admin');
4
5
- // Add 'DB Cleaner' option page under settings in wordpress admin pannel
6
- function adv_db_cleaner_admin() {
7
- add_options_page('Advanced DB Cleaner Options', 'DB Cleaner','manage_options', __FILE__, 'adv_db_cleaner_page');
8
}
9
10
function adv_db_cleaner_page(){
11
?>
12
<div class="wrap">
@@ -20,80 +32,219 @@ function adv_db_cleaner_page(){
20
}
21
$adv_db_cleaner_message = __('Your database is now cleaned.', 'advanced-db-cleaner');
22
}
23
if($adv_db_cleaner_message != ''){
24
echo '<div id="adbc_message" class="updated settings-error notice is-dismissible"><p><strong>' . $adv_db_cleaner_message . '</strong></p></div>';
25
}
26
?>
27
- <form action="" method="post">
28
- <p>
29
- <table class="widefat" style="width:419px;">
30
- <thead>
31
- <tr>
32
- <th scope="col"><?php _e('Type','advanced-db-cleaner'); ?></th>
33
- <th scope="col"><?php _e('Count','advanced-db-cleaner'); ?></th>
34
- <th scope="col"><?php _e('Select','advanced-db-cleaner'); ?></th>
35
- </tr>
36
- </thead>
37
- <tbody id="the-list">
38
- <tr class="alternate">
39
- <td class="column-name"><?php _e('Revision','advanced-db-cleaner'); ?></td>
40
- <td class="column-name"><?php echo adv_db_cleaner_count('revision'); ?></td>
41
- <td class="column-name"><input type="checkbox" name="adbc_post_type[]" value="revision"></td>
42
- </tr>
43
- <tr>
44
- <td class="column-name"><?php _e('Draft','advanced-db-cleaner'); ?></td>
45
- <td class="column-name"><?php echo adv_db_cleaner_count('draft'); ?></td>
46
- <td class="column-name"><input type="checkbox" name="adbc_post_type[]" value="draft"></td>
47
- </tr>
48
- <tr class="alternate">
49
- <td class="column-name"><?php _e('Auto Draft','advanced-db-cleaner'); ?></td>
50
- <td class="column-name"><?php echo adv_db_cleaner_count('autodraft'); ?></td>
51
- <td class="column-name"><input type="checkbox" name="adbc_post_type[]" value="autodraft"></td>
52
- </tr>
53
- <tr>
54
- <td class="column-name"><?php _e('Moderated Comments','advanced-db-cleaner'); ?></td>
55
- <td class="column-name"><?php echo adv_db_cleaner_count('moderated'); ?></td>
56
- <td class="column-name"><input type="checkbox" name="adbc_post_type[]" value="moderated"></td>
57
- </tr>
58
- <tr class="alternate">
59
- <td class="column-name"><?php _e('Spam Comments','advanced-db-cleaner'); ?></td>
60
- <td class="column-name"><?php echo adv_db_cleaner_count('spam'); ?></td>
61
- <td class="column-name"><input type="checkbox" name="adbc_post_type[]" value="spam"></td>
62
- </tr>
63
- <tr>
64
- <td class="column-name"><?php _e('Trash Comments','advanced-db-cleaner'); ?></td>
65
- <td class="column-name"><?php echo adv_db_cleaner_count('trash'); ?></td>
66
- <td class="column-name"><input type="checkbox" name="adbc_post_type[]" value="trash"></td>
67
- </tr>
68
- <tr class="alternate">
69
- <td class="column-name"><?php _e('Orphan Postmeta','advanced-db-cleaner'); ?></td>
70
- <td class="column-name"><?php echo adv_db_cleaner_count('postmeta'); ?></td>
71
- <td class="column-name"><input type="checkbox" name="adbc_post_type[]" value="postmeta"></td>
72
- </tr>
73
- <tr>
74
- <td class="column-name"><?php _e('Orphan Commentmeta','advanced-db-cleaner'); ?></td>
75
- <td class="column-name"><?php echo adv_db_cleaner_count('commentmeta'); ?></td>
76
- <td class="column-name"><input type="checkbox" name="adbc_post_type[]" value="commentmeta"></td>
77
- </tr>
78
- <tr class="alternate">
79
- <td class="column-name"><?php _e('Orphan Relationships','advanced-db-cleaner'); ?></td>
80
- <td class="column-name"><?php echo adv_db_cleaner_count('relationships'); ?></td>
81
- <td class="column-name"><input type="checkbox" name="adbc_post_type[]" value="relationships"></td>
82
- </tr>
83
- <tr>
84
- <td class="column-name"><?php _e('Dashboard Transient Feed','advanced-db-cleaner'); ?></td>
85
- <td class="column-name"><?php echo adv_db_cleaner_count('feed'); ?></td>
86
- <td class="column-name"><input type="checkbox" name="adbc_post_type[]" value="feed"></td>
87
- </tr>
88
- </tbody>
89
- </table>
90
- </p>
91
- <p>
92
- <input type="submit" class="button-primary" value="<?php _e('Delete selected items','advanced-db-cleaner'); ?>" />
93
- </p>
94
- </form>
95
<br />
96
- <div style="text-align:center">&copy; <?php echo date("Y"); ?> By Symptote</div>
97
</div>
98
<?php
99
}
@@ -192,4 +343,14 @@ function adv_db_cleaner_count($type){
192
}
193
return $count;
194
}
195
?>
1
<?php
2
+ add_action('admin_init', 'adv_db_cleaner_register_styles' );
3
+ add_action('admin_menu', 'adv_db_cleaner_add_admin_menu');
4
5
+ // Add 'DB Cleaner' to Wordpress settings menu
6
+ function adv_db_cleaner_add_admin_menu() {
7
+ $hook_adv_db_cleaner = add_options_page('Advanced DB Cleaner Options', 'Database Cleaner','manage_options', __FILE__, 'adv_db_cleaner_page');
8
+ add_action('admin_print_styles-' . $hook_adv_db_cleaner, 'adv_db_cleaner_enqueue_styles');
9
+ }
10
+
11
+ /* Register stylesheet. */
12
+ function adv_db_cleaner_register_styles() {
13
+ wp_register_style('adv_db_cleaner_css', plugins_url() .'/'. dirname(plugin_basename(__FILE__)) . '/css/style.css');
14
+ }
15
16
+ /* Enqueue stylesheet. */
17
+ function adv_db_cleaner_enqueue_styles() {
18
+ wp_enqueue_style( 'adv_db_cleaner_css' );
19
}
20
21
+ /* The admin page content */
22
function adv_db_cleaner_page(){
23
?>
24
<div class="wrap">
32
}
33
$adv_db_cleaner_message = __('Your database is now cleaned.', 'advanced-db-cleaner');
34
}
35
+
36
+ if(isset($_POST['aDBc_optimize_form'])){
37
+ adv_db_cleaner_optimize();
38
+ $adv_db_cleaner_message = __('Your database is now optimized.', 'advanced-db-cleaner');
39
+ }
40
+
41
if($adv_db_cleaner_message != ''){
42
echo '<div id="adbc_message" class="updated settings-error notice is-dismissible"><p><strong>' . $adv_db_cleaner_message . '</strong></p></div>';
43
}
44
?>
45
+
46
+
47
+ <div class="tabBox">
48
+ <?php
49
+ $aDBc_tab_list = array(
50
+ array("id"=>"aDBc-clean","title"=>"Clean Database"),
51
+ array("id"=>"aDBc-optimize","title"=>"Optimize Database")
52
+ );
53
+
54
+ foreach ($aDBc_tab_list as $key => $value){
55
+ $checked = "";
56
+ if((!isset($_POST["aDBc_clean_form"]) && !isset($_POST["aDBc_optimize_form"]) && $value["id"] == "aDBc-clean")
57
+ || (isset($_POST["aDBc_optimize_form"]) && $value["id"] == "aDBc-optimize")
58
+ || (isset($_POST["aDBc_clean_form"]) && $value["id"] == "aDBc-clean")){
59
+ $checked = 'checked = "checked"';
60
+ }
61
+ echo '<input '.$checked.' type="radio" id="'.$value["id"].'" name="tabGroup1">'."\n";
62
+ echo '<label for="'.$value["id"].'">'.$value["title"].'</label>'."\n";
63
+ }
64
+ ?>
65
+
66
+ <div class="tab1">
67
+ <form action="" method="post">
68
+ <p>
69
+ <table class="widefat" style="border: 0px; box-shadow: 0 1px 0px #ccc;">
70
+ <thead>
71
+ <tr>
72
+ <th scope="col"><b><?php _e('Type','advanced-db-cleaner'); ?></b></th>
73
+ <th scope="col"><b><?php _e('Count','advanced-db-cleaner'); ?></b></th>
74
+ <th scope="col"><b><?php _e('Select','advanced-db-cleaner'); ?></b></th>
75
+ </tr>
76
+ </thead>
77
+ <tbody id="the-list">
78
+ <tr class="alternate">
79
+ <td class="column-name"><?php _e('Revision','advanced-db-cleaner'); ?></td>
80
+ <td class="column-name aDBcCount"><?php echo adv_db_cleaner_count('revision'); ?></td>
81
+ <td class="column-name">
82
+ <div class="squaredFour">
83
+ <input id="aDBc_check1" type="checkbox" name="adbc_post_type[]" value="revision" />
84
+ <label for="aDBc_check1"></label>
85
+ </div>
86
+ </td>
87
+ </tr>
88
+ <tr class="alternate">
89
+ <td class="column-name"><?php _e('Draft','advanced-db-cleaner'); ?></td>
90
+ <td class="column-name aDBcCount"><?php echo adv_db_cleaner_count('draft'); ?></td>
91
+ <td class="column-name">
92
+ <div class="squaredFour">
93
+ <input id="aDBc_check2" type="checkbox" name="adbc_post_type[]" value="draft" />
94
+ <label for="aDBc_check2"></label>
95
+ </div>
96
+ </td>
97
+ </tr>
98
+ <tr class="alternate">
99
+ <td class="column-name"><?php _e('Auto Draft','advanced-db-cleaner'); ?></td>
100
+ <td class="column-name aDBcCount"><?php echo adv_db_cleaner_count('autodraft'); ?></td>
101
+ <td class="column-name">
102
+ <div class="squaredFour">
103
+ <input id="aDBc_check3" type="checkbox" name="adbc_post_type[]" value="autodraft" />
104
+ <label for="aDBc_check3"></label>
105
+ </div>
106
+ </td>
107
+ </tr>
108
+ <tr class="alternate">
109
+ <td class="column-name"><?php _e('Moderated Comments','advanced-db-cleaner'); ?></td>
110
+ <td class="column-name aDBcCount"><?php echo adv_db_cleaner_count('moderated'); ?></td>
111
+ <td class="column-name">
112
+ <div class="squaredFour">
113
+ <input id="aDBc_check4" type="checkbox" name="adbc_post_type[]" value="moderated" />
114
+ <label for="aDBc_check4"></label>
115
+ </div>
116
+ </td>
117
+ </tr>
118
+ <tr class="alternate">
119
+ <td class="column-name"><?php _e('Spam Comments','advanced-db-cleaner'); ?></td>
120
+ <td class="column-name aDBcCount"><?php echo adv_db_cleaner_count('spam'); ?></td>
121
+ <td class="column-name">
122
+ <div class="squaredFour">
123
+ <input id="aDBc_check5" type="checkbox" name="adbc_post_type[]" value="spam" />
124
+ <label for="aDBc_check5"></label>
125
+ </div>
126
+ </td>
127
+ </tr>
128
+ <tr class="alternate">
129
+ <td class="column-name"><?php _e('Trash Comments','advanced-db-cleaner'); ?></td>
130
+ <td class="column-name aDBcCount"><?php echo adv_db_cleaner_count('trash'); ?></td>
131
+ <td class="column-name">
132
+ <div class="squaredFour">
133
+ <input id="aDBc_check6" type="checkbox" name="adbc_post_type[]" value="trash" />
134
+ <label for="aDBc_check6"></label>
135
+ </div>
136
+ </td>
137
+ </tr>
138
+ <tr class="alternate">
139
+ <td class="column-name"><?php _e('Orphan Postmeta','advanced-db-cleaner'); ?></td>
140
+ <td class="column-name aDBcCount"><?php echo adv_db_cleaner_count('postmeta'); ?></td>
141
+ <td class="column-name">
142
+ <div class="squaredFour">
143
+ <input id="aDBc_check7" type="checkbox" name="adbc_post_type[]" value="postmeta" />
144
+ <label for="aDBc_check7"></label>
145
+ </div>
146
+ </td>
147
+ </tr>
148
+ <tr class="alternate">
149
+ <td class="column-name"><?php _e('Orphan Commentmeta','advanced-db-cleaner'); ?></td>
150
+ <td class="column-name aDBcCount"><?php echo adv_db_cleaner_count('commentmeta'); ?></td>
151
+ <td class="column-name">
152
+ <div class="squaredFour">
153
+ <input id="aDBc_check8" type="checkbox" name="adbc_post_type[]" value="commentmeta" />
154
+ <label for="aDBc_check8"></label>
155
+ </div>
156
+ </td>
157
+ </tr>
158
+ <tr class="alternate">
159
+ <td class="column-name"><?php _e('Orphan Relationships','advanced-db-cleaner'); ?></td>
160
+ <td class="column-name aDBcCount"><?php echo adv_db_cleaner_count('relationships'); ?></td>
161
+ <td class="column-name">
162
+ <div class="squaredFour">
163
+ <input id="aDBc_check9" type="checkbox" name="adbc_post_type[]" value="relationships" />
164
+ <label for="aDBc_check9"></label>
165
+ </div>
166
+ </td>
167
+ </tr>
168
+ <tr class="alternate">
169
+ <td class="column-name"><?php _e('Dashboard Transient Feed','advanced-db-cleaner'); ?></td>
170
+ <td class="column-name aDBcCount"><?php echo adv_db_cleaner_count('feed'); ?></td>
171
+ <td class="column-name">
172
+ <div class="squaredFour">
173
+ <input id="aDBc_check10" type="checkbox" name="adbc_post_type[]" value="feed" />
174
+ <label for="aDBc_check10"></label>
175
+ </div>
176
+ </td>
177
+ </tr>
178
+ </tbody>
179
+ </table>
180
+ </p>
181
+ <p>
182
+ <input type="hidden" name="aDBc_clean_form" value="" />
183
+ <input type="submit" class="button-primary" value="<?php _e('Delete selected items','advanced-db-cleaner'); ?>" />
184
+ </p>
185
+ </form>
186
+ </div>
187
+
188
+ <div class="tab2">
189
+ <form action="" method="post">
190
+ <p>
191
+ <table class="widefat" style="border: 0px; box-shadow: 0 1px 0px #ccc;">
192
+ <thead>
193
+ <tr>
194
+ <th scope="col"><b><?php _e('#','advanced-db-cleaner'); ?></b></th>
195
+ <th scope="col"><b><?php _e('Table','advanced-db-cleaner'); ?></b></th>
196
+ <th scope="col" style="text-align:right; width:80px"><b><?php _e('Rows','advanced-db-cleaner'); ?></b></th>
197
+ <th scope="col" style="text-align:right; width:100px"><b><?php _e('Size','advanced-db-cleaner'); ?></b></th>
198
+ <th scope="col" style="text-align:right; width:80px"><b><?php _e('Lost','advanced-db-cleaner'); ?></b></th>
199
+ </tr>
200
+ </thead>
201
+ <tbody id="the-list">
202
+ <?php
203
+ global $wpdb;
204
+ $aDBc_tableID = 0;
205
+ $total_rows = 0;
206
+ $total_size = 0;
207
+ $total_lost = 0;
208
+ $adbc_sql = 'SHOW TABLE STATUS FROM `'.DB_NAME.'`';
209
+ $result = $wpdb->get_results($adbc_sql);
210
+ foreach($result as $row){
211
+ $aDBc_tableID += 1;
212
+ $total_rows += $row->Rows;
213
+ $table_size = ($row->Data_length + $row->Index_length) / 1024;
214
+ $total_size += $table_size;
215
+ $total_lost += $row->Data_free;
216
+ echo "<tr class='alternate'>
217
+ <td class='column-name' style='width:30px'>". $aDBc_tableID ."</td>
218
+ <td class='column-name'>". $row->Name ."</td>
219
+ <td class='column-name' style='text-align:right'>". $row->Rows ."</td>
220
+ <td class='column-name' style='text-align:right'>". sprintf("%0.2f", $table_size) ." KB</td>
221
+ <td class='column-name' style='text-align:right'>". ($row->Data_free > 0 ? $row->Data_free . ' o' : '--') ."</td>
222
+ </tr>\n";
223
+ }
224
+ ?>
225
+ </tbody>
226
+ <tfoot>
227
+ <tr class="alternate">
228
+ <th scope="col" style="font-size:12px"><?php _e('Total','advanced-db-cleaner'); ?></th>
229
+ <th scope="col" style="text-align:left"><b><?php echo $aDBc_tableID; ?></b></th>
230
+ <th scope="col" style="text-align:right"><b><?php echo $total_rows; ?></b></th>
231
+ <th scope="col" style="text-align:right"><b><?php echo sprintf("%0.2f", $total_size).'</b> KB'; ?></th>
232
+ <th scope="col" style="text-align:right"><b><?php echo $total_lost .'</b> o'; ?></th>
233
+ </tr>
234
+ </tfoot>
235
+ </table>
236
+ </p>
237
+ <p>
238
+ <input type="hidden" name="aDBc_optimize_form" value="" />
239
+ <input type="submit" class="button-primary" value="<?php _e('Optimize database','advanced-db-cleaner'); ?>" />
240
+ </p>
241
+ </form>
242
+ </div>
243
+ </div>
244
+
245
<br />
246
+
247
+ <div style="text-align:center; clear: both">&copy; <?php echo date("Y"); ?> By Symptote</div>
248
</div>
249
<?php
250
}
343
}
344
return $count;
345
}
346
+
347
+ function adv_db_cleaner_optimize(){
348
+ global $wpdb;
349
+ $adbc_sql = 'SHOW TABLE STATUS FROM `'.DB_NAME.'`';
350
+ $result = $wpdb->get_results($adbc_sql);
351
+ foreach($result as $row){
352
+ $adbc_sql = 'OPTIMIZE TABLE '.$row->Name;
353
+ $wpdb->query($adbc_sql);
354
+ }
355
+ }
356
?>
advanced-db-cleaner.php CHANGED
@@ -2,7 +2,7 @@
2
/*
3
Plugin Name: Advanced Database Cleaner
4
Description: Clean your database and save space by removing unused data such as "draft", "Spam Comments", "Orphan Postmeta", etc.
5
- Version: 1.0.0
6
Author: Jaafar Y.
7
Contributors: symptote
8
Text Domain: advanced-db-cleaner
@@ -13,18 +13,9 @@ License URI: http://www.gnu.org/licenses/gpl-2.0.html
13
14
defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
15
16
- add_action('init','load_db_cleaner_language');
17
- function load_db_cleaner_language(){
18
- $activeLocale = get_locale();
19
- if(!empty($activeLocale)){
20
- $langFile = dirname(__FILE__) . "/languages/" . $activeLocale . ".mo";
21
- if(@file_exists($langFile) && is_readable($langFile)){
22
- load_textdomain('advanced-db-cleaner', $langFile);
23
- }
24
- }
25
- }
26
-
27
add_filter('plugin_action_links_' . plugin_basename(__FILE__), 'db_cleaner_add_action_links');
28
function db_cleaner_add_action_links($links){
29
$adc_settings_link = '<a href = "options-general.php?page=' . dirname(plugin_basename(__FILE__)) . '/advanced-db-cleaner-admin.php">' . __('Settings', 'advanced-db-cleaner') . '</a>';
30
array_unshift($links, $adc_settings_link);
2
/*
3
Plugin Name: Advanced Database Cleaner
4
Description: Clean your database and save space by removing unused data such as "draft", "Spam Comments", "Orphan Postmeta", etc.
5
+ Version: 1.1.0
6
Author: Jaafar Y.
7
Contributors: symptote
8
Text Domain: advanced-db-cleaner
13
14
defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
15
16
add_filter('plugin_action_links_' . plugin_basename(__FILE__), 'db_cleaner_add_action_links');
17
+
18
+ // Add 'settings' link under the plugin name in plugins page
19
function db_cleaner_add_action_links($links){
20
$adc_settings_link = '<a href = "options-general.php?page=' . dirname(plugin_basename(__FILE__)) . '/advanced-db-cleaner-admin.php">' . __('Settings', 'advanced-db-cleaner') . '</a>';
21
array_unshift($links, $adc_settings_link);
css/index.php ADDED
@@ -0,0 +1,3 @@
1
+ <?php
2
+ #Silence is golden.
3
+ ?>
css/style.css ADDED
@@ -0,0 +1,129 @@
1
+ /* Set the size and font of the tab widget */
2
+ .tabBox {
3
+ border-radius: 4px;
4
+ margin: 10px 0 40px 0;
5
+ width: 550px;
6
+ height: auto;
7
+ float: left;
8
+ }
9
+
10
+ /* Configure the radio buttons to hide off screen */
11
+ .tabBox > input[type="radio"] {
12
+ position: absolute;
13
+ left:-100px;
14
+ top:-100px;
15
+ }
16
+
17
+ /* Configure labels to look like tabs */
18
+ .tabBox > input[type="radio"] + label {
19
+ /* inline-block such that the label can be given dimensions */
20
+ display: inline-block;
21
+
22
+ /* A nice curved border around the tab */
23
+ border: 1px solid #DEDBD1;
24
+ border-radius: 5px 5px 0 0;
25
+ -moz-border-radius: 5px 5px 0 0;
26
+ -webkit-border-radius: 5px 5px 0 0;
27
+
28
+ /* the bottom border is handled by the tab content div */
29
+ border-bottom: 0;
30
+
31
+ /* Padding around tab text */
32
+ padding: 5px 10px;
33
+
34
+ /* Set the background color to default gray (non-selected tab) */
35
+ background-color:#ddd;
36
+ color: black;
37
+ }
38
+
39
+ /* Checked tabs must be white with the bottom border removed */
40
+ .tabBox > input[type="radio"]:checked + label {
41
+ background-color:white;
42
+ font-weight: bold;
43
+ border-bottom: 1px solid white;
44
+ margin-bottom: -1px;
45
+ }
46
+
47
+ /* The tab content must fill the widgets size and have a nice border */
48
+ .tabBox > div {
49
+ display: none;
50
+ border: 1px solid #DEDBD1;
51
+ background-color: white;
52
+ padding: 10px 20px 10px 20px;
53
+ height: auto;
54
+ overflow: auto;
55
+ margin-top: -1px;
56
+
57
+ border-radius: 0 5px 5px 5px;
58
+ -moz-border-radius: 0 5px 5px 5px;
59
+ -webkit-border-radius: 0 5px 5px 5px;
60
+ }
61
+
62
+ /* This matchs tabs displaying to thier associated radio inputs */
63
+ #aDBc-clean:checked ~ .tab1, #aDBc-optimize:checked ~ .tab2, #aDBc-stats:checked ~ .tab3{
64
+ display: block;
65
+ }
66
+
67
+
68
+ /* style for count numbers */
69
+ .aDBcCount {
70
+ text-align:center;
71
+ color: #666 !important;
72
+ }
73
+
74
+
75
+ /* Style for check box */
76
+
77
+ input[type=checkbox] {
78
+ visibility: hidden;
79
+ }
80
+
81
+ /* SQUARED FOUR */
82
+ .squaredFour {
83
+ position: relative;
84
+ }
85
+
86
+ .squaredFour label {
87
+ cursor: pointer;
88
+ position: absolute;
89
+ width: 16px;
90
+ height: 16px;
91
+ top: 0;
92
+ border-radius: 4px;
93
+ border: 1px solid #999;
94
+ background: #fcfff4;
95
+ }
96
+
97
+ .squaredFour label:after {
98
+ -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
99
+ filter: alpha(opacity=0);
100
+ opacity: 0;
101
+ content: '';
102
+ position: absolute;
103
+ width: 7px;
104
+ height: 4px;
105
+ background: transparent;
106
+ top: 4px;
107
+ left: 4px;
108
+ border: 2px solid #71ADE1;
109
+ border-top: none;
110
+ border-right: none;
111
+ -webkit-transform: rotate(-45deg);
112
+ -moz-transform: rotate(-45deg);
113
+ -o-transform: rotate(-45deg);
114
+ -ms-transform: rotate(-45deg);
115
+ transform: rotate(-45deg);
116
+ }
117
+
118
+ .squaredFour label:hover::after {
119
+ -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=30)";
120
+ filter: alpha(opacity=30);
121
+ opacity: 0.3;
122
+ }
123
+
124
+ .squaredFour input[type=checkbox]:checked + label:after {
125
+ -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";
126
+ filter: alpha(opacity=100);
127
+ opacity: 1;
128
+ }
129
+
index.php ADDED
@@ -0,0 +1,3 @@
1
+ <?php
2
+ #Silence is golden.
3
+ ?>
screenshot-1.png CHANGED
Binary file
screenshot-2.png ADDED
Binary file