Changeset 653153
- Timestamp:
- 01/15/2013 08:09:19 PM (13 years ago)
- Location:
- linear-tag-cloud
- Files:
-
- 11 added
- 2 deleted
- 4 edited
-
tags/1.1/index.php (modified) (6 diffs)
-
tags/1.1/ltc-style.css (added)
-
tags/1.1/readme.txt (modified) (2 diffs)
-
tags/1.1/style.css (deleted)
-
tags/1.2 (added)
-
tags/1.2/assets (added)
-
tags/1.2/assets/banner-772x250.png (added)
-
tags/1.2/assets/screenshot-1.png (added)
-
tags/1.2/assets/screenshot-2.png (added)
-
tags/1.2/assets/screenshot-3.png (added)
-
tags/1.2/index.php (added)
-
tags/1.2/ltc-style.css (added)
-
tags/1.2/readme.txt (added)
-
trunk/index.php (modified) (6 diffs)
-
trunk/ltc-style.css (added)
-
trunk/readme.txt (modified) (2 diffs)
-
trunk/style.css (deleted)
Legend:
- Unmodified
- Added
- Removed
-
linear-tag-cloud/tags/1.1/index.php
r653033 r653153 5 5 Description: A tag clob with bars and not dimensions. 6 6 Author: Andrea Rufo 7 Version: 1.17 Version: 0.1 8 8 Author URI: http://www.orangedropdesign.com/ 9 9 … … 35 35 <p> 36 36 <label for="<?php echo $this->get_field_id( 'number' ); ?>">Max number of tags:</label> 37 <input class="widefat" type=" number" id="<?php echo $this->get_field_id( 'number' ); ?>" name="<?php echo $this->get_field_name( 'number' ); ?>" value="<?php echo $instance['number']; ?>" request/>37 <input class="widefat" type="text" id="<?php echo $this->get_field_id( 'number' ); ?>" name="<?php echo $this->get_field_name( 'number' ); ?>" value="<?php echo $instance['number']; ?>" /> 38 38 </p> 39 39 40 40 <p> 41 41 <label for="<?php echo $this->get_field_id( 'border' ); ?>">Border color:</label> 42 <input class="widefat" type=" color" id="<?php echo $this->get_field_id( 'border' ); ?>" name="<?php echo $this->get_field_name( 'border' ); ?>" value="<?php echo $instance['border']; ?>" />42 <input class="widefat" type="text" id="<?php echo $this->get_field_id( 'border' ); ?>" name="<?php echo $this->get_field_name( 'border' ); ?>" value="<?php echo $instance['border']; ?>" /> 43 43 </p> 44 44 45 45 <p> 46 46 <label for="<?php echo $this->get_field_id( 'background' ); ?>">Background color:</label> 47 <input class="widefat" type=" color" id="<?php echo $this->get_field_id( 'background' ); ?>" name="<?php echo $this->get_field_name( 'background' ); ?>" value="<?php echo $instance['background']; ?>" />47 <input class="widefat" type="text" id="<?php echo $this->get_field_id( 'background' ); ?>" name="<?php echo $this->get_field_name( 'background' ); ?>" value="<?php echo $instance['background']; ?>" /> 48 48 </p> 49 49 50 50 <p> 51 <label for="<?php echo $this->get_field_id( 'color' ); ?>">Text color (applied on a tag):</label>52 <input class="widefat" type=" color" id="<?php echo $this->get_field_id( 'color' ); ?>" name="<?php echo $this->get_field_name( 'color' ); ?>" value="<?php echo $instance['color']; ?>" />51 <label for="<?php echo $this->get_field_id( 'color' ); ?>">Text color:</label> 52 <input class="widefat" type="text" id="<?php echo $this->get_field_id( 'color' ); ?>" name="<?php echo $this->get_field_name( 'color' ); ?>" value="<?php echo $instance['color']; ?>" /> 53 53 </p> 54 54 … … 103 103 } 104 104 105 // aggiorna i dati105 //update the input 106 106 public function update( $new_instance, $old_instance ){ 107 107 108 108 $instance = $old_instance; 109 $instance['title'] = strip_tags( $new_instance['title'] );110 $instance['number'] = strip_tags( $new_instance['number'] );111 $instance['border'] = strip_tags( $new_instance['border'] );112 $instance['background'] = strip_tags( $new_instance['background'] );113 $instance['color'] = strip_tags( $new_instance['color'] );109 $instance['title'] = strip_tags( $new_instance['title'] ); 110 $instance['number'] = strip_tags( $new_instance['number'] ); 111 $instance['border'] = strip_tags( $new_instance['border'] ); 112 $instance['background'] = strip_tags( $new_instance['background'] ); 113 $instance['color'] = strip_tags( $new_instance['color'] ); 114 114 115 115 return $instance; … … 117 117 } 118 118 119 // includo lo stile del widget119 //add the plugin's css to the page 120 120 add_action( 'wp_enqueue_scripts', 'ltc_add_my_stylesheet' ); 121 121 122 122 function ltc_add_my_stylesheet() { 123 wp_register_style( 'ltc-style', plugins_url(' style.css', __FILE__) );123 wp_register_style( 'ltc-style', plugins_url('ltc-style.css', __FILE__) ); 124 124 wp_enqueue_style( 'ltc-style' ); 125 125 } 126 126 127 // Custom get_tags function to support ignoring tags with less than $minnum posts.127 //custom get_all_tags function to get all tags ordered by count whit $max number of elements 128 128 function get_all_tags($max) { 129 129 130 130 $args = array( 131 'orderby' => 'count', 131 'orderby' => 'count', 132 132 'order' => 'DESC', 133 133 'number' => $max … … 139 139 $tags = array(); 140 140 141 foreach ($alltags as $tag) { 142 //if ($tag->count < $minnum || $tag->count > $maxnum) 143 //continue; 144 141 foreach ($alltags as $tag){ 145 142 array_push($tags, $tag); 146 143 } … … 155 152 } 156 153 157 // registro il widget 154 // register the widget 155 add_action( 'widgets_init', 'ltc_register_widgets' ); 156 158 157 function ltc_register_widgets(){ 159 158 register_widget( 'ltc_widget' ); 160 159 } 161 160 162 add_action( 'widgets_init', 'ltc_register_widgets' );163 164 161 ?> -
linear-tag-cloud/tags/1.1/readme.txt
r653033 r653153 1 1 === Linear Tag Cloud === 2 2 Contributors: andrearufo 3 Donate link: http://www.orangedropdesign.com4 Tags: bar chart, tag -cloud, responsive, widget, alternative tag3 Donate link: www.orangedropdesign.com 4 Tags: bar chart, tag cloud, percentage, responsive, chart 5 5 Requires at least: 3 6 6 Tested up to: 3.5 … … 20 20 2. Upload the folder `linear-tag-cloud` to the `/wp-content/plugins/` directory 21 21 3. Activate the plugin through the 'Plugins' menu in WordPress 22 4. Add the widget in the sidebar areas and configure it whit max tag number, border color, bars color, link color22 4. Add the widget in the sidebar areas and configure it 23 23 5. Done! 24 24 25 25 == Frequently asked questions == 26 26 27 = Is it possib ile to configure it? =27 = Is it possible to configure it? = 28 28 Yes, you can configure max number of tags; background, text and border color of the bars 29 30 = Can I change the style? =31 You can apply whatever CSS rules to the elements of the widget. The main class of the `div` contain the tag cloud is `.linear-tag-cloud`.32 29 33 30 == Screenshots == 34 31 35 32 1. The control panel in the widget page on Wordpress admin panel 36 2. An example of the application as widget in a custom theme37 3. An example of the application in the Twenty Twelve default Wordpress theme33 2. An example of the application 34 3. An example of the application in the Twenty Twelve default Wordpress Theme 38 35 39 36 == Changelog == 40 37 41 38 = 1.1 = 42 * Some fix 43 * Add HTML5 tags to admin panel 39 * Bug fix 40 * Add CSS rules 41 * Optimized code 44 42 45 43 = 1.0 = 46 * Max numbero of tags configurable 47 * Background and border color configurable for bars 48 * Text color configurable for link in the bars 44 * Bug fix 45 * HTML5 tag applied 49 46 50 47 = 0.1 = 51 48 * First release 49 * Max number of tags configurable 50 * Background and border color configurable for bars 51 * Text color configurable for link in the bars 52 52 53 53 == Upgrade notice == -
linear-tag-cloud/trunk/index.php
r653024 r653153 5 5 Description: A tag clob with bars and not dimensions. 6 6 Author: Andrea Rufo 7 Version: 1.17 Version: 0.1 8 8 Author URI: http://www.orangedropdesign.com/ 9 9 … … 35 35 <p> 36 36 <label for="<?php echo $this->get_field_id( 'number' ); ?>">Max number of tags:</label> 37 <input class="widefat" type=" number" id="<?php echo $this->get_field_id( 'number' ); ?>" name="<?php echo $this->get_field_name( 'number' ); ?>" value="<?php echo $instance['number']; ?>" request/>37 <input class="widefat" type="text" id="<?php echo $this->get_field_id( 'number' ); ?>" name="<?php echo $this->get_field_name( 'number' ); ?>" value="<?php echo $instance['number']; ?>" /> 38 38 </p> 39 39 40 40 <p> 41 41 <label for="<?php echo $this->get_field_id( 'border' ); ?>">Border color:</label> 42 <input class="widefat" type=" color" id="<?php echo $this->get_field_id( 'border' ); ?>" name="<?php echo $this->get_field_name( 'border' ); ?>" value="<?php echo $instance['border']; ?>" />42 <input class="widefat" type="text" id="<?php echo $this->get_field_id( 'border' ); ?>" name="<?php echo $this->get_field_name( 'border' ); ?>" value="<?php echo $instance['border']; ?>" /> 43 43 </p> 44 44 45 45 <p> 46 46 <label for="<?php echo $this->get_field_id( 'background' ); ?>">Background color:</label> 47 <input class="widefat" type=" color" id="<?php echo $this->get_field_id( 'background' ); ?>" name="<?php echo $this->get_field_name( 'background' ); ?>" value="<?php echo $instance['background']; ?>" />47 <input class="widefat" type="text" id="<?php echo $this->get_field_id( 'background' ); ?>" name="<?php echo $this->get_field_name( 'background' ); ?>" value="<?php echo $instance['background']; ?>" /> 48 48 </p> 49 49 50 50 <p> 51 <label for="<?php echo $this->get_field_id( 'color' ); ?>">Text color (applied on a tag):</label>52 <input class="widefat" type=" color" id="<?php echo $this->get_field_id( 'color' ); ?>" name="<?php echo $this->get_field_name( 'color' ); ?>" value="<?php echo $instance['color']; ?>" />51 <label for="<?php echo $this->get_field_id( 'color' ); ?>">Text color:</label> 52 <input class="widefat" type="text" id="<?php echo $this->get_field_id( 'color' ); ?>" name="<?php echo $this->get_field_name( 'color' ); ?>" value="<?php echo $instance['color']; ?>" /> 53 53 </p> 54 54 … … 103 103 } 104 104 105 // aggiorna i dati105 //update the input 106 106 public function update( $new_instance, $old_instance ){ 107 107 108 108 $instance = $old_instance; 109 $instance['title'] = strip_tags( $new_instance['title'] );110 $instance['number'] = strip_tags( $new_instance['number'] );111 $instance['border'] = strip_tags( $new_instance['border'] );112 $instance['background'] = strip_tags( $new_instance['background'] );113 $instance['color'] = strip_tags( $new_instance['color'] );109 $instance['title'] = strip_tags( $new_instance['title'] ); 110 $instance['number'] = strip_tags( $new_instance['number'] ); 111 $instance['border'] = strip_tags( $new_instance['border'] ); 112 $instance['background'] = strip_tags( $new_instance['background'] ); 113 $instance['color'] = strip_tags( $new_instance['color'] ); 114 114 115 115 return $instance; … … 117 117 } 118 118 119 // includo lo stile del widget119 //add the plugin's css to the page 120 120 add_action( 'wp_enqueue_scripts', 'ltc_add_my_stylesheet' ); 121 121 122 122 function ltc_add_my_stylesheet() { 123 wp_register_style( 'ltc-style', plugins_url(' style.css', __FILE__) );123 wp_register_style( 'ltc-style', plugins_url('ltc-style.css', __FILE__) ); 124 124 wp_enqueue_style( 'ltc-style' ); 125 125 } 126 126 127 // Custom get_tags function to support ignoring tags with less than $minnum posts.127 //custom get_all_tags function to get all tags ordered by count whit $max number of elements 128 128 function get_all_tags($max) { 129 129 130 130 $args = array( 131 'orderby' => 'count', 131 'orderby' => 'count', 132 132 'order' => 'DESC', 133 133 'number' => $max … … 139 139 $tags = array(); 140 140 141 foreach ($alltags as $tag) { 142 //if ($tag->count < $minnum || $tag->count > $maxnum) 143 //continue; 144 141 foreach ($alltags as $tag){ 145 142 array_push($tags, $tag); 146 143 } … … 155 152 } 156 153 157 // registro il widget 154 // register the widget 155 add_action( 'widgets_init', 'ltc_register_widgets' ); 156 158 157 function ltc_register_widgets(){ 159 158 register_widget( 'ltc_widget' ); 160 159 } 161 160 162 add_action( 'widgets_init', 'ltc_register_widgets' );163 164 161 ?> -
linear-tag-cloud/trunk/readme.txt
r653033 r653153 1 1 === Linear Tag Cloud === 2 2 Contributors: andrearufo 3 Donate link: http://www.orangedropdesign.com4 Tags: bar chart, tag -cloud, responsive, widget, alternative tag3 Donate link: www.orangedropdesign.com 4 Tags: bar chart, tag cloud, percentage, responsive, chart 5 5 Requires at least: 3 6 6 Tested up to: 3.5 7 Stable tag: 1. 17 Stable tag: 1.2 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 20 20 2. Upload the folder `linear-tag-cloud` to the `/wp-content/plugins/` directory 21 21 3. Activate the plugin through the 'Plugins' menu in WordPress 22 4. Add the widget in the sidebar areas and configure it whit max tag number, border color, bars color, link color22 4. Add the widget in the sidebar areas and configure it 23 23 5. Done! 24 24 25 25 == Frequently asked questions == 26 26 27 = Is it possib ile to configure it? =27 = Is it possible to configure it? = 28 28 Yes, you can configure max number of tags; background, text and border color of the bars 29 30 = Can I change the style? =31 You can apply whatever CSS rules to the elements of the widget. The main class of the `div` contain the tag cloud is `.linear-tag-cloud`.32 29 33 30 == Screenshots == 34 31 35 32 1. The control panel in the widget page on Wordpress admin panel 36 2. An example of the application as widget in a custom theme37 3. An example of the application in the Twenty Twelve default Wordpress theme33 2. An example of the application 34 3. An example of the application in the Twenty Twelve default Wordpress Theme 38 35 39 36 == Changelog == 40 37 41 38 = 1.1 = 42 * Some fix 43 * Add HTML5 tags to admin panel 39 * Bug fix 40 * Add CSS rules 41 * Optimized code 44 42 45 43 = 1.0 = 46 * Max numbero of tags configurable 47 * Background and border color configurable for bars 48 * Text color configurable for link in the bars 44 * Bug fix 45 * HTML5 tag applied 49 46 50 47 = 0.1 = 51 48 * First release 49 * Max number of tags configurable 50 * Background and border color configurable for bars 51 * Text color configurable for link in the bars 52 52 53 53 == Upgrade notice ==
Note: See TracChangeset
for help on using the changeset viewer.