Merge lp:~quam-plures-core/quam-plures/qp-core-widgets into lp:quam-plures

Proposed by Yabs
Status: Merged
Merged at revision: not available
Proposed branch: lp:~quam-plures-core/quam-plures/qp-core-widgets
Merge into: lp:quam-plures
Diff against target: 3183 lines (+728/-785)
43 files modified
blogs/inc/_core/_class5.funcs.php (+0/-23)
blogs/inc/_core/model/__core.install.php (+1/-1)
blogs/inc/skins/_skin.funcs.php (+2/-4)
blogs/inc/widgets/model/_widget.class.php (+131/-92)
blogs/inc/widgets/model/_widgetcache.class.php (+29/-7)
blogs/inc/widgets/views/_widget_list_available.view.php (+7/-5)
blogs/inc/widgets/widgets.ctrl.php (+11/-4)
blogs/install/_functions_evoupgrade.php (+12/-1)
blogs/install/_functions_install.php (+25/-25)
blogs/plugins/coll_category_list_widget/_coll_category_list.widget.php (+19/-30)
blogs/plugins/coll_comment_list_widget/_coll_comment_list.widget.php (+18/-31)
blogs/plugins/coll_common_links_widget/_coll_common_links.widget.php (+17/-30)
blogs/plugins/coll_item_list_widget/_coll_item_list.widget.php (+45/-54)
blogs/plugins/coll_link_list_widget/_coll_link_list.widget.php (+8/-12)
blogs/plugins/coll_logo_widget/_coll_logo.widget.php (+5/-13)
blogs/plugins/coll_longdesc_widget/_coll_longdesc.widget.php (+5/-36)
blogs/plugins/coll_media_index_widget/_coll_media_index.widget.php (+21/-34)
blogs/plugins/coll_page_list_widget/_coll_page_list.widget.php (+7/-14)
blogs/plugins/coll_post_list_widget/_coll_post_list.widget.php (+7/-14)
blogs/plugins/coll_related_post_list_widget/_coll_related_post_list.widget.php (+7/-14)
blogs/plugins/coll_search_form_widget/_coll_search_form.widget.php (+11/-24)
blogs/plugins/coll_tag_cloud_widget/_coll_tag_cloud.widget.php (+10/-23)
blogs/plugins/coll_tagline_widget/_coll_tagline.widget.php (+6/-13)
blogs/plugins/coll_title_widget/_coll_title.widget.php (+4/-11)
blogs/plugins/coll_xml_feeds_widget/_coll_xml_feeds.widget.php (+11/-24)
blogs/plugins/colls_list_owner_widget/_colls_list_owner.widget.php (+14/-47)
blogs/plugins/colls_list_public_widget/_colls_list_public.widget.php (+15/-48)
blogs/plugins/colls_list_widget/_colls_list.widget.php (+171/-0)
blogs/plugins/free_html_widget/_free_html.widget.php (+8/-20)
blogs/plugins/linkblog_widget/_linkblog.widget.php (+7/-14)
blogs/plugins/menu_link_widget/_menu_link.widget.php (+27/-36)
blogs/plugins/user_tools_widget/_user_tools.widget.php (+24/-38)
blogs/skins/asevo/style.css (+5/-5)
blogs/skins/custom/style.css (+4/-4)
blogs/skins/evocamp/style.css (+2/-2)
blogs/skins/evopress/style.css (+1/-1)
blogs/skins/glossyblue/style.css (+10/-10)
blogs/skins/miami_blue/style.css (+1/-1)
blogs/skins/natural_pink/style.css (+4/-4)
blogs/skins/nifty_corners/style.css (+4/-4)
blogs/skins/pixelgreen/style.css (+3/-3)
blogs/skins/terrafirma/style.css (+1/-1)
blogs/skins/vastitude/style.css (+8/-8)
To merge this branch: bzr merge lp:~quam-plures-core/quam-plures/qp-core-widgets
Reviewer Review Type Date Requested Status
Tilman Blumenbach (community) merge Approve
Review via email: mp+16128@code.launchpad.net

Commit message

Author : Yabs
Reviewer :

Implements blueprint : Remove core widgets from the core

Changes :
Core widgets have been moved to the plugins folder
Trans ability added to widget class
All widgets have localised translation ability
Deprecated Public and Same owner widgets, replaced with Blog List widget

To post a comment you must log in.
Revision history for this message
Yabs (yabs) wrote :

Implemented stage one of changing core widgets

7400. By Yabs

merged trunk

Revision history for this message
Tilman Blumenbach (tblue) wrote :

When trying to upgrade the DB, I got the following error:

> MySQL error!
> Data truncated for column 'wi_type' at row 1(Errno=1265)
> Your query:
> ALTER TABLE evo_widget CHANGE COLUMN wi_type wi_type ENUM('widget', 'plugin') NOT NULL DEFAULT 'widget'

File: blogs/install/_functions_evoupgrade.php on line 2469

There may be more errors, but since I cannot test the changes because of the DB error, I cannot say for sure whether these really exist:
 - You removed the get_name() method from the widgets. I don't know whether you changed it to work through method inheritance, though.
 - You also removed the "Block title" widget setting. If you have managed to keep it working e. g. by letting the base class handle/list this option, that's great! :-)

review: Needs Fixing
7401. By Yabs

correcting installer for conveting core to widget

7402. By Tilman Blumenbach

Optimized WidgetCache::load_widget() by removing the static $loaded_widgets array and relying on PHP to not include widget class files twice (require_once()). Frequent calls to file_exists() should not impact IO performance since PHP uses a stat() cache.

Revision history for this message
Tilman Blumenbach (tblue) wrote :

Looks better now, but there are new problems:
 - Fatal error: Call to undefined method Calendar::T_() in blogs/plugins/calendar_plugin/_calendar.plugin.php on line 486
 - The blog title is not centered anymore (see Blog 1).

review: Needs Fixing
Revision history for this message
Tilman Blumenbach (tblue) wrote :

> Looks better now, but there are new problems:
> - Fatal error: Call to undefined method Calendar::T_() in
> blogs/plugins/calendar_plugin/_calendar.plugin.php on line 486

Oops, that's not your fault. Actually, it's mine -- I overlooked this bug on the last code review.

Revision history for this message
Tilman Blumenbach (tblue) wrote :

The only issue of the above that remains is:
> - The blog title is not centered anymore (see Blog 1).

7403. By Tilman Blumenbach

Rename CSS classes (widget_core_* -> widget_widget_*).

Revision history for this message
Tilman Blumenbach (tblue) wrote :

Seems like everything works now.

review: Approve (merge)
7404. By Tilman Blumenbach

merged trunk

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'blogs/inc/_core/_class5.funcs.php'
--- blogs/inc/_core/_class5.funcs.php 2009-12-06 09:37:19 +0000
+++ blogs/inc/_core/_class5.funcs.php 2009-12-21 15:13:15 +0000
@@ -82,26 +82,6 @@
82 'filecache' => $inc_path.'files/model/_filecache.class.php',82 'filecache' => $inc_path.'files/model/_filecache.class.php',
83 'filelist' => $inc_path.'files/model/_filelist.class.php',83 'filelist' => $inc_path.'files/model/_filelist.class.php',
84 'fileroot' => $inc_path.'files/model/_fileroot.class.php',84 'fileroot' => $inc_path.'files/model/_fileroot.class.php',
85 'coll_xml_feeds_widget' => $inc_path.'widgets/widgets/_coll_xml_feeds.widget.php',
86 'coll_longdesc_widget' => $inc_path.'widgets/widgets/_coll_longdesc.widget.php',
87 'coll_title_widget' => $inc_path.'widgets/widgets/_coll_title.widget.php',
88 'menu_link_widget' => $inc_path.'widgets/widgets/_menu_link.widget.php',
89 'user_tools_widget' => $inc_path.'widgets/widgets/_user_tools.widget.php',
90 'coll_media_index_widget' => $inc_path.'widgets/widgets/_coll_media_index.widget.php',
91 'coll_category_list_widget' => $inc_path.'widgets/widgets/_coll_category_list.widget.php',
92 'coll_common_links_widget' => $inc_path.'widgets/widgets/_coll_common_links.widget.php',
93 'colls_list_owner_widget' => $inc_path.'widgets/widgets/_colls_list_owner.widget.php',
94 'coll_post_list_widget' => $inc_path.'widgets/widgets/_coll_post_list.widget.php',
95 'coll_comment_list_widget' => $inc_path.'widgets/widgets/_coll_comment_list.widget.php',
96 'coll_search_form_widget' => $inc_path.'widgets/widgets/_coll_search_form.widget.php',
97 'colls_list_public_widget' => $inc_path.'widgets/widgets/_colls_list_public.widget.php',
98 'coll_logo_widget' => $inc_path.'widgets/widgets/_coll_logo.widget.php',
99 'links_widget' => $inc_path.'widgets/widgets/_links.widget.php',
100 'coll_tagline_widget' => $inc_path.'widgets/widgets/_coll_tagline.widget.php',
101 'free_html_widget' => $inc_path.'widgets/widgets/_free_html.widget.php',
102 'coll_page_list_widget' => $inc_path.'widgets/widgets/_coll_page_list.widget.php',
103 'coll_tag_cloud_widget' => $inc_path.'widgets/widgets/_coll_tag_cloud.widget.php',
104 'linkblog_widget' => $inc_path.'widgets/widgets/_linkblog.widget.php',
105 'widgetcache' => $inc_path.'widgets/model/_widgetcache.class.php',85 'widgetcache' => $inc_path.'widgets/model/_widgetcache.class.php',
106 'componentwidget' => $inc_path.'widgets/model/_widget.class.php',86 'componentwidget' => $inc_path.'widgets/model/_widget.class.php',
107 'session' => $inc_path.'sessions/model/_session.class.php',87 'session' => $inc_path.'sessions/model/_session.class.php',
@@ -149,10 +129,7 @@
149 'adminui' => $adminskins_path.'/evo/_adminUI.class.php',129 'adminui' => $adminskins_path.'/evo/_adminUI.class.php',
150 'adminui' => $adminskins_path.'/legacy/_adminUI.class.php',130 'adminui' => $adminskins_path.'/legacy/_adminUI.class.php',
151 'adminui' => $adminskins_path.'/chicago/_adminUI.class.php',131 'adminui' => $adminskins_path.'/chicago/_adminUI.class.php',
152 'coll_item_list_widget' => $inc_path.'widgets/widgets/_coll_item_list.widget.php',
153 'menu' => $inc_path.'_core/ui/_menu.class.php',132 'menu' => $inc_path.'_core/ui/_menu.class.php',
154 'coll_related_post_list_widget' => $inc_path.'widgets/widgets/_coll_related_post_list.widget.php',
155 'coll_link_list_widget' => $inc_path.'widgets/widgets/_coll_link_list.widget.php',
156 'rfc822_addresses_class' => $inc_path.'_ext/mime_parser/rfc822_addresses.php',133 'rfc822_addresses_class' => $inc_path.'_ext/mime_parser/rfc822_addresses.php',
157 'mime_parser_class' => $inc_path.'_ext/mime_parser/mime_parser.php',134 'mime_parser_class' => $inc_path.'_ext/mime_parser/mime_parser.php',
158 /* AUTOGENERATED LIST END */135 /* AUTOGENERATED LIST END */
159136
=== modified file 'blogs/inc/_core/model/__core.install.php'
--- blogs/inc/_core/model/__core.install.php 2009-12-06 09:37:19 +0000
+++ blogs/inc/_core/model/__core.install.php 2009-12-21 15:13:15 +0000
@@ -202,7 +202,7 @@
202 wi_sco_name VARCHAR( 40 ) NOT NULL,202 wi_sco_name VARCHAR( 40 ) NOT NULL,
203 wi_order INT(10) NOT NULL,203 wi_order INT(10) NOT NULL,
204 wi_enabled TINYINT(1) NOT NULL DEFAULT 1,204 wi_enabled TINYINT(1) NOT NULL DEFAULT 1,
205 wi_type ENUM( 'core', 'plugin' ) NOT NULL DEFAULT 'core',205 wi_type ENUM( 'widget', 'plugin' ) NOT NULL DEFAULT 'widget',
206 wi_code VARCHAR(32) NOT NULL,206 wi_code VARCHAR(32) NOT NULL,
207 wi_params TEXT NULL,207 wi_params TEXT NULL,
208 PRIMARY KEY ( wi_ID ),208 PRIMARY KEY ( wi_ID ),
209209
=== modified file 'blogs/inc/skins/_skin.funcs.php'
--- blogs/inc/skins/_skin.funcs.php 2009-12-10 02:40:40 +0000
+++ blogs/inc/skins/_skin.funcs.php 2009-12-21 15:13:15 +0000
@@ -661,23 +661,21 @@
661 */661 */
662function skin_widget( $params )662function skin_widget( $params )
663{663{
664 global $inc_path;
665
666 if( empty( $params['widget'] ) )664 if( empty( $params['widget'] ) )
667 {665 {
668 echo 'No widget code provided!';666 echo 'No widget code provided!';
669 return false;667 return false;
670 }668 }
671669
670 $wiCache = get_Cache('WidgetCache');
672 $widget_code = $params['widget'];671 $widget_code = $params['widget'];
673 unset( $params['widget'] );672 unset( $params['widget'] );
674673
675 if( ! file_exists( $inc_path.'widgets/widgets/_'.$widget_code.'.widget.php' ) )674 if( ! $wiCache->load_widget( $widget_code ) )
676 { // For some reason, that widget doesn't seem to exist... (any more?)675 { // For some reason, that widget doesn't seem to exist... (any more?)
677 echo "Invalid widget code provided [$widget_code]!";676 echo "Invalid widget code provided [$widget_code]!";
678 return false;677 return false;
679 }678 }
680 require_once $inc_path.'widgets/widgets/_'.$widget_code.'.widget.php';
681679
682 $widget_classname = $widget_code.'_Widget';680 $widget_classname = $widget_code.'_Widget';
683681
684682
=== modified file 'blogs/inc/widgets/model/_widget.class.php'
--- blogs/inc/widgets/model/_widget.class.php 2009-12-06 09:37:19 +0000
+++ blogs/inc/widgets/model/_widget.class.php 2009-12-21 15:13:15 +0000
@@ -39,12 +39,15 @@
39 var $sco_name;39 var $sco_name;
40 var $order;40 var $order;
41 /**41 /**
42 * @var string Type of the plugin ("core" or "plugin")42 * @var string Type of the widget ("widget" or "plugin")
43 */43 */
44 var $type;44 var $type;
45 var $code;45 var $code;
46 var $params;46 var $params;
4747
48 var $widget_name;
49 var $widget_title;
50
48 /**51 /**
49 * Indicates whether the widget is enabled.52 * Indicates whether the widget is enabled.
50 *53 *
@@ -74,11 +77,27 @@
7477
7578
76 /**79 /**
80 * The translations keyed by locale. They get loaded through include() of _global.php.
81 * @see ComponentWidget::T_()
82 * @var array
83 */
84 var $_trans = array();
85
86 /**
87 * Has the global /locales/_global.php file (where translation for
88 * all languages can be put into) been loaded?
89 *
90 * @var boolean
91 */
92 var $_trans_loaded_global = false;
93
94
95 /**
77 * Constructor96 * Constructor
78 *97 *
79 * @param object data row from db98 * @param object data row from db
80 */99 */
81 function ComponentWidget( $db_row = NULL, $type = 'core', $code = NULL )100 function ComponentWidget( $db_row = NULL, $type = 'widget', $code = NULL )
82 {101 {
83 // Call parent constructor:102 // Call parent constructor:
84 parent::DataObject( 'T_widget', 'wi_', 'wi_ID' );103 parent::DataObject( 'T_widget', 'wi_', 'wi_ID' );
@@ -150,17 +169,36 @@
150 */169 */
151 function get_name()170 function get_name()
152 {171 {
153 if( $this->type == 'plugin' )172 if( $this->widget_name )
154 {173 { // we have a name
155 // Make sure Plugin is loaded:174 $name = $this->widget_name;
156 if( $this->get_Plugin() )175 }
176 else
177 { // we don't have a name
178 if( $this->type == 'plugin' )
157 {179 {
158 return $this->Plugin->name;180 // Make sure Plugin is loaded:
159 }181 if( $this->get_Plugin() )
160 return T_('Inactive / Uninstalled plugin');182 {
161 }183 $name = $this->Plugin->name;
162184 }
163 return T_('Unknown');185 else
186 {
187 $name = T_('Inactive / Uninstalled plugin');
188 }
189 }
190 else
191 { // it's a widget
192 $name = T_('Unknown widget');
193 }
194 }
195
196 if( $this->disp_params['widget_name'] && $name != $this->disp_params['widget_name'] )
197 { // user has renamed us
198 $name .= ' : '.$this->disp_params['widget_name'];
199 }
200
201 return $name;
164 }202 }
165203
166204
@@ -228,6 +266,18 @@
228 function get_param_definitions( $params )266 function get_param_definitions( $params )
229 {267 {
230 $r = array(268 $r = array(
269 'widget_name' => array(
270 'label' => T_( 'Name' ),
271 'size' => 20,
272 'note' => T_( 'Displayed in the widget list.'),
273 'defaultvalue' => $this->widget_name,
274 ),
275 'widget_title' => array(
276 'label' => T_( 'Title' ),
277 'size' => 20,
278 'note' => T_( 'Displayed in your template.'),
279 'defaultvalue' => $this->widget_title,
280 ),
231 'widget_css_class' => array(281 'widget_css_class' => array(
232 'label' => '<span class="dimmed">'.T_( 'CSS Class' ).'</span>',282 'label' => '<span class="dimmed">'.T_( 'CSS Class' ).'</span>',
233 'size' => 20,283 'size' => 20,
@@ -458,7 +508,7 @@
458 {508 {
459 if( is_null($title) )509 if( is_null($title) )
460 {510 {
461 $title = & $this->disp_params['title'];511 $title = $this->disp_params['widget_title'];
462 }512 }
463513
464 if( $this->disp_params['block_display_title'] && !empty( $title ) )514 if( $this->disp_params['block_display_title'] && !empty( $title ) )
@@ -471,83 +521,6 @@
471521
472522
473 /**523 /**
474 * List of collections/blogs
475 *
476 * @param array MUST contain at least the basic display params
477 */
478 function disp_coll_list( $filter = 'public' )
479 {
480 /**
481 * @var Blog
482 */
483 global $Blog, $baseurl;
484
485 echo $this->disp_params['block_start'];
486
487 $this->disp_title();
488
489 /**
490 * @var BlogCache
491 */
492 $BlogCache = & get_Cache( 'BlogCache' );
493
494 if( $filter == 'owner' )
495 { // Load blogs of same owner
496 $blog_array = $BlogCache->load_owner_blogs( $Blog->owner_user_ID, 'ID' );
497 }
498 else
499 { // Load all public blogs
500 $blog_array = $BlogCache->load_public( 'ID' );
501 }
502
503 {
504 echo $this->disp_params['list_start'];
505
506 foreach( $blog_array as $l_blog_ID )
507 { // Loop through all public blogs:
508
509 $l_Blog = & $BlogCache->get_by_ID( $l_blog_ID );
510
511 if( $Blog && $l_blog_ID == $Blog->ID )
512 { // This is the blog being displayed on this page:
513 echo $this->disp_params['item_selected_start'];
514 $link_class = $this->disp_params['link_selected_class'];
515 }
516 else
517 {
518 echo $this->disp_params['item_start'];
519 $link_class = $this->disp_params['link_default_class'];;
520 }
521
522 echo '<a href="'.$l_Blog->gen_blogurl().'" class="'.$link_class.'" title="'
523 .$l_Blog->dget( 'name', 'htmlattr' ).'">';
524
525 if( $Blog && $l_blog_ID == $Blog->ID )
526 { // This is the blog being displayed on this page:
527 echo $this->disp_params['item_selected_text_start'];
528 printf( $this->disp_params['item_selected_text'], $l_Blog->dget( 'shortname', 'htmlbody' ) );
529 echo $this->disp_params['item_selected_text_end'];
530 echo '</a>';
531 echo $this->disp_params['item_selected_end'];
532 }
533 else
534 {
535 echo $this->disp_params['item_text_start'];
536 printf( $this->disp_params['item_text'], $l_Blog->dget( 'shortname', 'htmlbody' ) );
537 echo $this->disp_params['item_text_end'];
538 echo '</a>';
539 echo $this->disp_params['item_end'];
540 }
541 }
542
543 echo $this->disp_params['list_end'];
544 }
545
546 echo $this->disp_params['block_end'];
547 }
548
549
550 /**
551 * Insert object into DB based on previously recorded changes.524 * Insert object into DB based on previously recorded changes.
552 *525 *
553 * @return boolean true on success526 * @return boolean true on success
@@ -577,7 +550,73 @@
577550
578 return $res;551 return $res;
579 }552 }
553
554
555 /**
556 * Translate a given string, in the Widget's context.
557 *
558 * This means, that the translation is obtained from the Widget's "locales" folder.
559 * @link [doclink] Localization#Extensions
560 *
561 * It uses the global/regular {@link T_()} function as a fallback.
562 *
563 * @param string The string (english), that should be translated
564 * @param string Requested locale ({@link $current_locale} gets used by default)
565 * @return string The translated string.
566 * @uses T_()
567 */
568 function T_( $string, $req_locale = '' )
569 {
570 if( $this->type == 'plugin' )
571 { // use plugin translation function
572 return $this->Plugin->T_( $string, $req_locale );
573 }
574
575 global $plugins_path,$Debuglog;
576
577 $globalfile_path = $plugins_path.$this->code.'_widget/locales/_global.php';
578 $trans = & $this->_trans;
579
580 // Load the global messages file, if existing:
581 if( ! $this->_trans_loaded_global )
582 {
583 $this->_trans_loaded_global = true;
584
585 if( file_exists( $globalfile_path ) && is_readable( $globalfile_path ) )
586 {
587 include_once $globalfile_path;
588 }
589 else
590 {
591 $Debuglog->add( 'Global messages file '.$globalfile_path.' does not exist or is not readable!', 'locale' );
592 }
593 }
594
595 if ( ( $return = T_( $string, $req_locale, array(
596 'ext_transarray' => & $this->_trans,
597 'alt_basedir' => $plugins_path.$this->code.'_widget',
598 ) ) ) == $string )
599 { // Fallback to global translation file:
600 return T_( $string, $req_locale );
601 }
602 return $return;
603 }
604
605
606 /**
607 * Translate and escape single quotes.
608 *
609 * This is to be used mainly for Javascript strings.
610 *
611 * @uses ComponentWidget::T_()
612 *
613 * @param string String to translate
614 * @param string Locale to use
615 * @return string The translated and escaped string.
616 */
617 function TS_( $string, $req_locale = '' )
618 {
619 return str_replace( "'", "\\'", $this->T_( $string, $req_locale ) );
620 }
580}621}
581
582
583?>622?>
584623
=== modified file 'blogs/inc/widgets/model/_widgetcache.class.php'
--- blogs/inc/widgets/model/_widgetcache.class.php 2009-12-06 09:37:19 +0000
+++ blogs/inc/widgets/model/_widgetcache.class.php 2009-12-21 15:13:15 +0000
@@ -109,18 +109,16 @@
109 */109 */
110 function & new_obj( $row = NULL )110 function & new_obj( $row = NULL )
111 {111 {
112 global $inc_path;
113112
114 if( $row->wi_type == 'core' )113 if( $row->wi_type == 'widget' )
115 {114 {
116 if( ! file_exists( $inc_path.'widgets/widgets/_'.$row->wi_code.'.widget.php' ) )115 if( !$this->load_widget( $row->wi_code ) )
117 { // For some reason, that widget doesn't seem to exist... (any more?)116 {
118 // echo "Widget $row->wi_code could not be loaded! ";117 // echo "Widget $row->wi_code could not be loaded! ";
119 // TODO: replace with dummy widget in order to give a chance to clean up.118 // TODO: replace with dummy widget in order to give a chance to clean up.
120 $r = NULL;119 $r = NULL;
121 return $r;120 return $r;
122 }121 }
123 require_once $inc_path.'widgets/widgets/_'.$row->wi_code.'.widget.php';
124 $objtype = $row->wi_code.'_Widget';122 $objtype = $row->wi_code.'_Widget';
125 }123 }
126 else124 else
@@ -136,6 +134,32 @@
136134
137135
138 /**136 /**
137 * Loads appropriate widget class file.
138 *
139 * @param string $wi_code widget to load
140 * @return boolean Whether the class file could be loaded. Note that this method will return true
141 * if the file has been included before (there is no way to find out whether require_once()
142 * really included a file).
143 */
144 function load_widget( $wi_code )
145 {
146 global $plugins_path, $Debuglog;
147
148 // Note: file_exists() should not have a big impact on IO performance since PHP caches the
149 // results.
150 if( file_exists( $plugins_path.$wi_code.'_widget/_'.$wi_code.'.widget.php' ) )
151 { // widget is in its own folder
152 //$Debuglog->add( 'Loading class: '.$wi_code, 'widgets' );
153 // require_once makes sure each widget class is only loaded once.
154 require_once $plugins_path.$wi_code.'_widget/_'.$wi_code.'.widget.php';
155 return true;
156 }
157
158 return false;
159 }
160
161
162 /**
139 * @param integer Collection (blog) ID163 * @param integer Collection (blog) ID
140 * @param string Container164 * @param string Container
141 * @return array of Widget165 * @return array of Widget
@@ -148,6 +172,4 @@
148 return $this->cache_container_Widget_array[$coll_ID][$container];172 return $this->cache_container_Widget_array[$coll_ID][$container];
149 }173 }
150}174}
151
152
153?>175?>
154176
=== modified file 'blogs/inc/widgets/views/_widget_list_available.view.php'
--- blogs/inc/widgets/views/_widget_list_available.view.php 2009-12-06 09:37:19 +0000
+++ blogs/inc/widgets/views/_widget_list_available.view.php 2009-12-21 15:13:15 +0000
@@ -44,11 +44,13 @@
44 'coll_tagline',44 'coll_tagline',
45 'coll_longdesc',45 'coll_longdesc',
46 '*'.T_('Other'),46 '*'.T_('Other'),
47 'colls_list_public',47// 'colls_list_public', deprecated use colls_list
48 'colls_list_owner',48// 'colls_list_owner', deprecated use colls_list
49 'colls_list',
49 'user_tools',50 'user_tools',
50 );51 );
51$i = 0;52$i = 0;
53$wiCache = get_Cache( 'WidgetCache');
52foreach( $core_componentwidget_defs as $code )54foreach( $core_componentwidget_defs as $code )
53{55{
54 $i++;56 $i++;
@@ -62,12 +64,12 @@
62 }64 }
63 else65 else
64 {66 {
65 load_class( 'widgets/widgets/_'.$code.'.widget.php' );67 $wiCache->load_widget( $code );
66 $classname = $code.'_Widget';68 $classname = $code.'_Widget';
67 $ComponentWidget = & new $classname( NULL, 'core', $code );69 $ComponentWidget = & new $classname( NULL, 'widget', $code );
6870
69 echo '<li>';71 echo '<li>';
70 echo '<a href="'.regenerate_url( '', 'action=create&amp;type=core&amp;code='.$ComponentWidget->code ).'" title="'.T_('Add this widget to the container').'">';72 echo '<a href="'.regenerate_url( '', 'action=create&amp;type=widget&amp;code='.$ComponentWidget->code ).'" title="'.T_('Add this widget to the container').'">';
71 echo get_icon( 'new' ).'<strong>'.$ComponentWidget->get_name().'</strong>';73 echo get_icon( 'new' ).'<strong>'.$ComponentWidget->get_name().'</strong>';
72 echo '</a> <span class="notes">'.$ComponentWidget->get_desc().'</span>';74 echo '</a> <span class="notes">'.$ComponentWidget->get_desc().'</span>';
73 echo '</li>';75 echo '</li>';
7476
=== removed directory 'blogs/inc/widgets/widgets'
=== modified file 'blogs/inc/widgets/widgets.ctrl.php'
--- blogs/inc/widgets/widgets.ctrl.php 2009-12-06 09:37:19 +0000
+++ blogs/inc/widgets/widgets.ctrl.php 2009-12-21 15:13:15 +0000
@@ -137,11 +137,18 @@
137137
138 switch( $type )138 switch( $type )
139 {139 {
140 case 'core':140 case 'widget':
141 // Check the requested core widget is valid:141 // Check the requested core widget is valid:
142 load_class( 'widgets/widgets/_'.$code.'.widget.php' );142 $WidgetCache = & get_Cache( 'WidgetCache' );
143 $objtype = $code.'_Widget';143 if( $WidgetCache->load_widget( $code ) )
144 $edited_ComponentWidget = & new $objtype();144 {
145 $objtype = $code.'_Widget';
146 $edited_ComponentWidget = & new $objtype();
147 }
148 else
149 {
150 debug_die( 'Requested widget not found' );
151 }
145 break;152 break;
146153
147 case 'plugin':154 case 'plugin':
148155
=== modified file 'blogs/install/_functions_evoupgrade.php'
--- blogs/install/_functions_evoupgrade.php 2009-12-06 09:37:19 +0000
+++ blogs/install/_functions_evoupgrade.php 2009-12-21 15:13:16 +0000
@@ -1836,7 +1836,7 @@
1836 wi_coll_ID INT(11) UNSIGNED NOT NULL,1836 wi_coll_ID INT(11) UNSIGNED NOT NULL,
1837 wi_sco_name VARCHAR( 40 ) NOT NULL,1837 wi_sco_name VARCHAR( 40 ) NOT NULL,
1838 wi_order INT(10) UNSIGNED NOT NULL,1838 wi_order INT(10) UNSIGNED NOT NULL,
1839 wi_type ENUM( \'core\', \'plugin\' ) NOT NULL DEFAULT \'core\',1839 wi_type ENUM( \'widget\', \'plugin\' ) NOT NULL DEFAULT \'widget\',
1840 wi_code VARCHAR(32) NOT NULL,1840 wi_code VARCHAR(32) NOT NULL,
1841 wi_params TEXT NULL,1841 wi_params TEXT NULL,
1842 PRIMARY KEY ( wi_ID ),1842 PRIMARY KEY ( wi_ID ),
@@ -2462,6 +2462,17 @@
2462 */2462 */
24632463
24642464
2465 if( $old_db_version < 100000 )
2466 { // 0.0.0
2467 task_begin( 'Updating widgets table...' );
2468 $DB->query( "ALTER TABLE T_widget
2469 CHANGE COLUMN wi_type wi_type ENUM('widget', 'core', 'plugin') NOT NULL DEFAULT 'widget'" );
2470 $DB->query( "UPDATE T_widget SET wi_type='widget' WHERE NOT( wi_type='plugin' )" );
2471 $DB->query( "ALTER TABLE T_widget
2472 CHANGE COLUMN wi_type wi_type ENUM('widget', 'plugin') NOT NULL DEFAULT 'widget'" );
2473 task_end();
2474 }
2475
2465 // Just in case, make sure the db schema version is upto date at the end.2476 // Just in case, make sure the db schema version is upto date at the end.
2466 if( $old_db_version != $new_db_version )2477 if( $old_db_version != $new_db_version )
2467 { // Update DB schema version to $new_db_version2478 { // Update DB schema version to $new_db_version
24682479
=== modified file 'blogs/install/_functions_install.php'
--- blogs/install/_functions_install.php 2009-12-16 13:53:18 +0000
+++ blogs/install/_functions_install.php 2009-12-21 15:13:16 +0000
@@ -530,33 +530,33 @@
530530
531 // Add blog list to all blog Page Tops:531 // Add blog list to all blog Page Tops:
532 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )532 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
533 SELECT blog_ID, "Page Top", 1, "core", "colls_list_public"533 SELECT blog_ID, "Page Top", 1, "widget", "colls_list_public"
534 FROM T_blogs' );534 FROM T_blogs' );
535535
536 // Add title to all blog Headers:536 // Add title to all blog Headers:
537 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )537 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
538 SELECT blog_ID, "Header", 1, "core", "coll_title"538 SELECT blog_ID, "Header", 1, "widget", "coll_title"
539 FROM T_blogs' );539 FROM T_blogs' );
540 // Add tagline to all blogs Headers:540 // Add tagline to all blogs Headers:
541 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )541 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
542 SELECT blog_ID, "Header", 2, "core", "coll_tagline"542 SELECT blog_ID, "Header", 2, "widget", "coll_tagline"
543 FROM T_blogs' );543 FROM T_blogs' );
544544
545 // Add home link to all blogs Menus:545 // Add home link to all blogs Menus:
546 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )546 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )
547 SELECT blog_ID, "Menu", 1, "core", "menu_link", "'.$DB->escape(serialize(array('link_type'=>'home'))).'"547 SELECT blog_ID, "Menu", 1, "widget", "menu_link", "'.$DB->escape(serialize(array('link_type'=>'home'))).'"
548 FROM T_blogs' );548 FROM T_blogs' );
549 // Add info pages to all blogs Menus:549 // Add info pages to all blogs Menus:
550 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )550 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
551 SELECT blog_ID, "Menu", 2, "core", "coll_page_list"551 SELECT blog_ID, "Menu", 2, "widget", "coll_page_list"
552 FROM T_blogs' );552 FROM T_blogs' );
553 // Add contact link to all blogs Menus:553 // Add contact link to all blogs Menus:
554 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )554 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )
555 SELECT blog_ID, "Menu", 3, "core", "menu_link", "'.$DB->escape(serialize(array('link_type'=>'ownercontact'))).'"555 SELECT blog_ID, "Menu", 3, "widget", "menu_link", "'.$DB->escape(serialize(array('link_type'=>'ownercontact'))).'"
556 FROM T_blogs' );556 FROM T_blogs' );
557 // Add login link to all blogs Menus:557 // Add login link to all blogs Menus:
558 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )558 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )
559 SELECT blog_ID, "Menu", 4, "core", "menu_link", "'.$DB->escape(serialize(array('link_type'=>'login'))).'"559 SELECT blog_ID, "Menu", 4, "widget", "menu_link", "'.$DB->escape(serialize(array('link_type'=>'login'))).'"
560 FROM T_blogs' );560 FROM T_blogs' );
561561
562 // Add Calendar plugin to all blog Sidebars except blog A:562 // Add Calendar plugin to all blog Sidebars except blog A:
@@ -566,54 +566,54 @@
566 WHERE blog_ID > 1' );566 WHERE blog_ID > 1' );
567 // Add title to all blog Sidebars:567 // Add title to all blog Sidebars:
568 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )568 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
569 SELECT blog_ID, "Sidebar", 2, "core", "coll_title"569 SELECT blog_ID, "Sidebar", 2, "widget", "coll_title"
570 FROM T_blogs' );570 FROM T_blogs' );
571 // Add longdesc to all blogs Sidebars:571 // Add longdesc to all blogs Sidebars:
572 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )572 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
573 SELECT blog_ID, "Sidebar", 3, "core", "coll_longdesc"573 SELECT blog_ID, "Sidebar", 3, "widget", "coll_longdesc"
574 FROM T_blogs' );574 FROM T_blogs' );
575 // Add common links to all blogs Sidebars:575 // Add common links to all blogs Sidebars:
576 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )576 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
577 SELECT blog_ID, "Sidebar", 4, "core", "coll_common_links"577 SELECT blog_ID, "Sidebar", 4, "widget", "coll_common_links"
578 FROM T_blogs' );578 FROM T_blogs' );
579 // Add search form to all blogs Sidebars:579 // Add search form to all blogs Sidebars:
580 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )580 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
581 SELECT blog_ID, "Sidebar", 5, "core", "coll_search_form"581 SELECT blog_ID, "Sidebar", 5, "widget", "coll_search_form"
582 FROM T_blogs' );582 FROM T_blogs' );
583 // Add categories list to all blog Sidebars:583 // Add categories list to all blog Sidebars:
584 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )584 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
585 SELECT blog_ID, "Sidebar", 6, "core", "coll_category_list"585 SELECT blog_ID, "Sidebar", 6, "widget", "coll_category_list"
586 FROM T_blogs' );586 FROM T_blogs' );
587 // Add Random photo to blog Sidebars except blog B:587 // Add Random photo to blog Sidebars except blog B:
588 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )588 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )
589 SELECT blog_ID, "Sidebar", 7, "core", "coll_media_index", \'a:11:{s:5:"title";s:12:"Random photo";s:10:"thumb_size";s:11:"fit-160x120";s:12:"thumb_layout";s:4:"grid";s:12:"grid_nb_cols";s:1:"1";s:5:"limit";s:1:"1";s:8:"order_by";s:4:"RAND";s:9:"order_dir";s:3:"ASC";s:7:"blog_ID";s:1:"4";s:11:"widget_name";s:12:"Random photo";s:16:"widget_css_class";s:0:"";s:9:"widget_ID";s:0:"";}\'589 SELECT blog_ID, "Sidebar", 7, "widget", "coll_media_index", \'a:11:{s:5:"title";s:12:"Random photo";s:10:"thumb_size";s:11:"fit-160x120";s:12:"thumb_layout";s:4:"grid";s:12:"grid_nb_cols";s:1:"1";s:5:"limit";s:1:"1";s:8:"order_by";s:4:"RAND";s:9:"order_dir";s:3:"ASC";s:7:"blog_ID";s:1:"4";s:11:"widget_name";s:12:"Random photo";s:16:"widget_css_class";s:0:"";s:9:"widget_ID";s:0:"";}\'
590 FROM T_blogs590 FROM T_blogs
591 WHERE blog_ID <> 2' );591 WHERE blog_ID <> 2' );
592 // Add linkblog to blog Sidebars for blog A & B:592 // Add linkblog to blog Sidebars for blog A & B:
593 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )593 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )
594 SELECT blog_ID, "Sidebar", 8, "core", "linkblog", "'.$DB->escape(serialize(array('blog_ID'=>3))).'"594 SELECT blog_ID, "Sidebar", 8, "widget", "linkblog", "'.$DB->escape(serialize(array('blog_ID'=>3))).'"
595 FROM T_blogs595 FROM T_blogs
596 WHERE blog_ID <= 2' );596 WHERE blog_ID <= 2' );
597 // Add XML feeds to all blogs Sidebars:597 // Add XML feeds to all blogs Sidebars:
598 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )598 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
599 SELECT blog_ID, "Sidebar", 9, "core", "coll_xml_feeds"599 SELECT blog_ID, "Sidebar", 9, "widget", "coll_xml_feeds"
600 FROM T_blogs' );600 FROM T_blogs' );
601601
602 // All blog Sidebar 2:602 // All blog Sidebar 2:
603 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )603 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
604 SELECT blog_ID, "Sidebar 2", 1, "core", "coll_post_list"604 SELECT blog_ID, "Sidebar 2", 1, "widget", "coll_post_list"
605 FROM T_blogs' );605 FROM T_blogs' );
606606
607 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )607 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code )
608 SELECT blog_ID, "Sidebar 2", 2, "core", "coll_comment_list"608 SELECT blog_ID, "Sidebar 2", 2, "widget", "coll_comment_list"
609 FROM T_blogs' );609 FROM T_blogs' );
610610
611 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )611 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )
612 SELECT blog_ID, "Sidebar 2", 3, "core", "coll_media_index", \'a:11:{s:5:"title";s:13:"Recent photos";s:10:"thumb_size";s:10:"crop-80x80";s:12:"thumb_layout";s:4:"grid";s:12:"grid_nb_cols";s:1:"3";s:5:"limit";s:1:"9";s:8:"order_by";s:9:"datestart";s:9:"order_dir";s:4:"DESC";s:7:"blog_ID";s:1:"4";s:11:"widget_name";s:11:"Photo index";s:16:"widget_css_class";s:0:"";s:9:"widget_ID";s:0:"";}\'612 SELECT blog_ID, "Sidebar 2", 3, "widget", "coll_media_index", \'a:11:{s:5:"title";s:13:"Recent photos";s:10:"thumb_size";s:10:"crop-80x80";s:12:"thumb_layout";s:4:"grid";s:12:"grid_nb_cols";s:1:"3";s:5:"limit";s:1:"9";s:8:"order_by";s:9:"datestart";s:9:"order_dir";s:4:"DESC";s:7:"blog_ID";s:1:"4";s:11:"widget_name";s:11:"Photo index";s:16:"widget_css_class";s:0:"";s:9:"widget_ID";s:0:"";}\'
613 FROM T_blogs' );613 FROM T_blogs' );
614614
615 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )615 $DB->query( 'INSERT INTO T_widget( wi_coll_ID, wi_sco_name, wi_order, wi_type, wi_code, wi_params )
616 SELECT blog_ID, "Sidebar 2", 4, "core", "free_html", \'a:5:{s:5:"title";s:9:"Sidebar 2";s:7:"content";s:162:"This is the "Sidebar 2" container. You can place any widget you like in here. In the evo toolbar at the top of this page, select "Customize", then "Blog Widgets".";s:11:"widget_name";s:9:"Free HTML";s:16:"widget_css_class";s:0:"";s:9:"widget_ID";s:0:"";}\'616 SELECT blog_ID, "Sidebar 2", 4, "widget", "free_html", \'a:5:{s:5:"title";s:9:"Sidebar 2";s:7:"content";s:162:"This is the "Sidebar 2" container. You can place any widget you like in here. In the evo toolbar at the top of this page, select "Customize", then "Blog Widgets".";s:11:"widget_name";s:9:"Free HTML";s:16:"widget_css_class";s:0:"";s:9:"widget_ID";s:0:"";}\'
617 FROM T_blogs' );617 FROM T_blogs' );
618618
619 echo "OK.<br />\n";619 echo "OK.<br />\n";
620620
=== added directory 'blogs/plugins/coll_category_list_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_category_list.widget.php' => 'blogs/plugins/coll_category_list_widget/_coll_category_list.widget.php'
--- blogs/inc/widgets/widgets/_coll_category_list.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_category_list_widget/_coll_category_list.widget.php 2009-12-21 15:13:16 +0000
@@ -41,18 +41,13 @@
41 */41 */
42 function coll_category_list_Widget( $db_row = NULL )42 function coll_category_list_Widget( $db_row = NULL )
43 {43 {
44 $this->widget_name = $this->T_('Category list');
45 $this->widget_title = $this->T_('Categories');
46
44 // Call parent constructor:47 // Call parent constructor:
45 parent::ComponentWidget( $db_row, 'core', 'coll_category_list' );48 parent::ComponentWidget( $db_row, 'widget', 'coll_category_list' );
46 }49 }
4750
48
49 /**
50 * Get name of widget
51 */
52 function get_name()
53 {
54 return T_('Category list');
55 }
5651
5752
58 /**53 /**
@@ -60,7 +55,7 @@
60 */55 */
61 function get_short_desc()56 function get_short_desc()
62 {57 {
63 return format_to_output($this->disp_params['title']);58 return format_to_output($this->disp_params['widget_title']);
64 }59 }
6560
6661
@@ -69,7 +64,7 @@
69 */64 */
70 function get_desc()65 function get_desc()
71 {66 {
72 return T_('List of all categories; click filters blog on selected category.');67 return $this->T_('List of all categories; click filters blog on selected category.');
73 }68 }
7469
7570
@@ -87,30 +82,24 @@
87 function get_param_definitions( $params )82 function get_param_definitions( $params )
88 {83 {
89 $r = array_merge( array(84 $r = array_merge( array(
90 'title' => array(
91 'type' => 'text',
92 'label' => T_('Block title'),
93 'defaultvalue' => T_('Categories'),
94 'maxlength' => 100,
95 ),
96 'option_all' => array(85 'option_all' => array(
97 'type' => 'text',86 'type' => 'text',
98 'label' => T_('Option "All"'),87 'label' => $this->T_('Option "All"'),
99 'defaultvalue' => T_('All'),88 'defaultvalue' => $this->T_('All'),
100 'maxlength' => 100,89 'maxlength' => 100,
101 'note' => T_('The "All categories" link allows to reset the filter. Leave blank if you want no such option.'),90 'note' => $this->T_('The "All categories" link allows to reset the filter. Leave blank if you want no such option.'),
102 ),91 ),
103 'use_form' => array(92 'use_form' => array(
104 'type' => 'checkbox',93 'type' => 'checkbox',
105 'label' => T_('Use form'),94 'label' => $this->T_('Use form'),
106 'defaultvalue' => 0,95 'defaultvalue' => 0,
107 'note' => T_('Add checkboxes to allow selection of multiple categories.'),96 'note' => $this->T_('Add checkboxes to allow selection of multiple categories.'),
108 ),97 ),
109 'disp_names_for_coll_list' => array(98 'disp_names_for_coll_list' => array(
110 'type' => 'checkbox',99 'type' => 'checkbox',
111 'label' => T_('Display blog names'),100 'label' => $this->T_('Display blog names'),
112 'defaultvalue' => 1, /* previous behaviour */101 'defaultvalue' => 1, /* previous behaviour */
113 'note' => T_('Display blog names, if this is an aggregated blog.'),102 'note' => $this->T_('Display blog names, if this is an aggregated blog.'),
114 ),103 ),
115104
116 // Hidden, used by the item list sidebar in the backoffice.105 // Hidden, used by the item list sidebar in the backoffice.
@@ -254,22 +243,22 @@
254 ?>243 ?>
255 <div class="tile">244 <div class="tile">
256 <input type="radio" name="cat" value="" id="catANY" class="radio" <?php if( $cat_modifier != '-' && $cat_modifier != '*' ) echo 'checked="checked" '?> />245 <input type="radio" name="cat" value="" id="catANY" class="radio" <?php if( $cat_modifier != '-' && $cat_modifier != '*' ) echo 'checked="checked" '?> />
257 <label for="catANY"><?php echo T_('ANY') ?></label>246 <label for="catANY"><?php echo $this->T_('ANY') ?></label>
258 </div>247 </div>
259 <div class="tile">248 <div class="tile">
260 <input type="radio" name="cat" value="-" id="catANYBUT" class="radio" <?php if( $cat_modifier == '-' ) echo 'checked="checked" '?> />249 <input type="radio" name="cat" value="-" id="catANYBUT" class="radio" <?php if( $cat_modifier == '-' ) echo 'checked="checked" '?> />
261 <label for="catANYBUT"><?php echo T_('ANY BUT') ?></label>250 <label for="catANYBUT"><?php echo $this->T_('ANY BUT') ?></label>
262 </div>251 </div>
263 <div class="tile">252 <div class="tile">
264 <input type="radio" name="cat" value="*" id="catALL" class="radio" <?php if( $cat_modifier == '*' ) echo 'checked="checked" '?> />253 <input type="radio" name="cat" value="*" id="catALL" class="radio" <?php if( $cat_modifier == '*' ) echo 'checked="checked" '?> />
265 <label for="catALL"><?php echo T_('ALL') ?></label>254 <label for="catALL"><?php echo $this->T_('ALL') ?></label>
266 </div>255 </div>
267 <?php256 <?php
268 if( $this->disp_params['use_form'] )257 if( $this->disp_params['use_form'] )
269 { // We want a complete form:258 { // We want a complete form:
270 ?>259 ?>
271 <div class="tile">260 <div class="tile">
272 <input type="submit" value="<?php echo T_( 'Filter categories' ); ?>" />261 <input type="submit" value="<?php echo $this->T_( 'Filter categories' ); ?>" />
273 </div>262 </div>
274 </form>263 </form>
275 <?php264 <?php
276265
=== added directory 'blogs/plugins/coll_comment_list_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_comment_list.widget.php' => 'blogs/plugins/coll_comment_list_widget/_coll_comment_list.widget.php'
--- blogs/inc/widgets/widgets/_coll_comment_list.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_comment_list_widget/_coll_comment_list.widget.php 2009-12-21 15:13:16 +0000
@@ -40,8 +40,10 @@
40 */40 */
41 function coll_comment_list_Widget( $db_row = NULL )41 function coll_comment_list_Widget( $db_row = NULL )
42 {42 {
43 $this->widget_name = $this->T_('Comment list');
44 $this->widget_title = $this->T_('Recent comments');
43 // Call parent constructor:45 // Call parent constructor:
44 parent::ComponentWidget( $db_row, 'core', 'coll_comment_list' );46 parent::ComponentWidget( $db_row, 'widget', 'coll_comment_list' );
45 }47 }
4648
4749
@@ -54,41 +56,35 @@
54 function get_param_definitions( $params )56 function get_param_definitions( $params )
55 {57 {
56 $r = array_merge( array(58 $r = array_merge( array(
57 'title' => array(
58 'label' => T_('Block title'),
59 'note' => T_( 'Title to display in your skin.' ),
60 'size' => 40,
61 'defaultvalue' => T_('Recent comments'),
62 ),
63 'disp_order' => array(59 'disp_order' => array(
64 'label' => T_('Order'),60 'label' => $this->T_('Order'),
65 'note' => T_('Order to display items'),61 'note' => $this->T_('Order to display items'),
66 'type' => 'select',62 'type' => 'select',
67 'options' => array( 'DESC' => T_( 'Newest to oldest' ), 'ASC' => T_( 'Oldest to newest' ), 'RAND' => T_( 'Random selection' ) ),63 'options' => array( 'DESC' => $this->T_( 'Newest to oldest' ), 'ASC' => $this->T_( 'Oldest to newest' ), 'RAND' => $this->T_( 'Random selection' ) ),
68 'defaultvalue' => 'DESC',64 'defaultvalue' => 'DESC',
69 ),65 ),
70 'limit' => array(66 'limit' => array(
71 'label' => T_( 'Max items' ),67 'label' => $this->T_( 'Max items' ),
72 'note' => T_( 'Maximum number of items to display.' ),68 'note' => $this->T_( 'Maximum number of items to display.' ),
73 'size' => 4,69 'size' => 4,
74 'defaultvalue' => 20,70 'defaultvalue' => 20,
75 ),71 ),
76 'author_links' => array(72 'author_links' => array(
77 'label' => T_( 'Link to author'),73 'label' => $this->T_( 'Link to author'),
78 'note' => T_( 'Link the author to their url' ),74 'note' => $this->T_( 'Link the author to their url' ),
79 'defaultvalue' => true,75 'defaultvalue' => true,
80 'type' => 'checkbox',76 'type' => 'checkbox',
81 ),77 ),
82 'hover_text' => array(78 'hover_text' => array(
83 'label' => T_( 'Hover text'),79 'label' => $this->T_( 'Hover text'),
84 'note' => T_( 'Text to show when hovering over the link' ),80 'note' => $this->T_( 'Text to show when hovering over the link' ),
85 'size' => 40,81 'size' => 40,
86 'defaultvalue' => T_( 'Read the full comment' ),82 'defaultvalue' => $this->T_( 'Read the full comment' ),
87 'type' => 'text',83 'type' => 'text',
88 ),84 ),
89 'blog_ID' => array(85 'blog_ID' => array(
90 'label' => T_( 'Blog' ),86 'label' => $this->T_( 'Blog' ),
91 'note' => T_( 'ID of the blog to use, leave empty for the current blog.' ),87 'note' => $this->T_( 'ID of the blog to use, leave empty for the current blog.' ),
92 'size' => 4,88 'size' => 4,
93 ),89 ),
94 ), parent::get_param_definitions( $params ) );90 ), parent::get_param_definitions( $params ) );
@@ -98,20 +94,11 @@
9894
9995
100 /**96 /**
101 * Get name of widget
102 */
103 function get_name()
104 {
105 return T_('Comment list');
106 }
107
108
109 /**
110 * Get a very short desc. Used in the widget list.97 * Get a very short desc. Used in the widget list.
111 */98 */
112 function get_short_desc()99 function get_short_desc()
113 {100 {
114 return format_to_output($this->disp_params['title']);101 return format_to_output($this->disp_params['widget_title']);
115 }102 }
116103
117104
@@ -120,7 +107,7 @@
120 */107 */
121 function get_desc()108 function get_desc()
122 {109 {
123 return T_('List of comments; click goes to comment.');110 return $this->T_('List of comments; click goes to comment.');
124 }111 }
125112
126113
@@ -161,7 +148,7 @@
161 $Comment->get_Item();148 $Comment->get_Item();
162 echo $this->disp_params[ 'item_start' ];149 echo $this->disp_params[ 'item_start' ];
163 $Comment->author( '', ' ', '', ' ', 'htmlbody', $this->disp_params[ 'author_links' ] );150 $Comment->author( '', ' ', '', ' ', 'htmlbody', $this->disp_params[ 'author_links' ] );
164 echo T_( 'on ' );151 echo $this->T_( 'on ' );
165 $Comment->permanent_link( array(152 $Comment->permanent_link( array(
166 'text' => $Comment->Item->title,153 'text' => $Comment->Item->title,
167 'title' => $this->disp_params[ 'hover_text' ],154 'title' => $this->disp_params[ 'hover_text' ],
168155
=== added directory 'blogs/plugins/coll_common_links_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_common_links.widget.php' => 'blogs/plugins/coll_common_links_widget/_coll_common_links.widget.php'
--- blogs/inc/widgets/widgets/_coll_common_links.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_common_links_widget/_coll_common_links.widget.php 2009-12-21 15:13:16 +0000
@@ -43,17 +43,10 @@
43 */43 */
44 function coll_common_links_Widget( $db_row = NULL )44 function coll_common_links_Widget( $db_row = NULL )
45 {45 {
46 $this->widget_name = $this->T_('Common Navigation Links');
47 $this->widget_title = '';
46 // Call parent constructor:48 // Call parent constructor:
47 parent::ComponentWidget( $db_row, 'core', 'coll_common_links' );49 parent::ComponentWidget( $db_row, 'widget', 'coll_common_links' );
48 }
49
50
51 /**
52 * Get name of widget
53 */
54 function get_name()
55 {
56 return T_('Common Navigation Links');
57 }50 }
5851
5952
@@ -62,7 +55,7 @@
62 */55 */
63 function get_short_desc()56 function get_short_desc()
64 {57 {
65 return format_to_output($this->disp_params['title']);58 return format_to_output($this->disp_params['widget_title']);
66 }59 }
6760
6861
@@ -71,7 +64,7 @@
71 */64 */
72 function get_desc()65 function get_desc()
73 {66 {
74 return T_('Display these links: Recently, Archives, Categories, Latest Comments');67 return $this->T_('Display these links: Recently, Archives, Categories, Latest Comments');
75 }68 }
7669
7770
@@ -84,34 +77,28 @@
84 function get_param_definitions( $params )77 function get_param_definitions( $params )
85 {78 {
86 $r = array_merge( array(79 $r = array_merge( array(
87 'title' => array(
88 'label' => T_('Block title'),
89 'note' => T_( 'Title to display in your skin.' ),
90 'size' => 40,
91 'defaultvalue' => '',
92 ),
93 'show_recently' => array(80 'show_recently' => array(
94 'type' => 'checkbox',81 'type' => 'checkbox',
95 'label' => T_('Show "Recently"'),82 'label' => $this->T_('Show "Recently"'),
96 'note' => T_('Go to the most recent posts / the blog\'s home.'),83 'note' => $this->T_('Go to the most recent posts / the blog\'s home.'),
97 'defaultvalue' => '1',84 'defaultvalue' => '1',
98 ),85 ),
99 'show_archives' => array(86 'show_archives' => array(
100 'type' => 'checkbox',87 'type' => 'checkbox',
101 'label' => T_('Show "Archives"'),88 'label' => $this->T_('Show "Archives"'),
102 'note' => T_('Go to the monthly/weekly/daily archive list.'),89 'note' => $this->T_('Go to the monthly/weekly/daily archive list.'),
103 'defaultvalue' => '1',90 'defaultvalue' => '1',
104 ),91 ),
105 'show_categories' => array(92 'show_categories' => array(
106 'type' => 'checkbox',93 'type' => 'checkbox',
107 'label' => T_('Show "Categories"'),94 'label' => $this->T_('Show "Categories"'),
108 'note' => T_('Go to the category tree.'),95 'note' => $this->T_('Go to the category tree.'),
109 'defaultvalue' => '1',96 'defaultvalue' => '1',
110 ),97 ),
111 'show_latestcomments' => array(98 'show_latestcomments' => array(
112 'type' => 'checkbox',99 'type' => 'checkbox',
113 'label' => T_('Show "Latest comments"'),100 'label' => $this->T_('Show "Latest comments"'),
114 'note' => T_('Go to the latest comments.'),101 'note' => $this->T_('Go to the latest comments.'),
115 'defaultvalue' => '1',102 'defaultvalue' => '1',
116 ),103 ),
117 ), parent::get_param_definitions( $params ) );104 ), parent::get_param_definitions( $params ) );
@@ -143,7 +130,7 @@
143 if( $this->disp_params['show_recently'] )130 if( $this->disp_params['show_recently'] )
144 {131 {
145 echo $this->disp_params['item_start'];132 echo $this->disp_params['item_start'];
146 echo '<strong><a href="'.$Blog->get('url').'">'.T_('Recently').'</a></strong>';133 echo '<strong><a href="'.$Blog->get('url').'">'.$this->T_('Recently').'</a></strong>';
147 echo $this->disp_params['item_end'];134 echo $this->disp_params['item_end'];
148 }135 }
149136
@@ -151,7 +138,7 @@
151 {138 {
152 // fp> TODO: don't display this if archives plugin not installed... or depluginize archives (I'm not sure)139 // fp> TODO: don't display this if archives plugin not installed... or depluginize archives (I'm not sure)
153 echo $this->disp_params['item_start'];140 echo $this->disp_params['item_start'];
154 echo '<strong><a href="'.$Blog->get('arcdirurl').'">'.T_('Archives').'</a></strong>';141 echo '<strong><a href="'.$Blog->get('arcdirurl').'">'.$this->T_('Archives').'</a></strong>';
155 echo $this->disp_params['item_end'];142 echo $this->disp_params['item_end'];
156 }143 }
157144
@@ -159,14 +146,14 @@
159 {146 {
160 // fp> TODO: don't display this if categories plugin not installed... or depluginize categories (I'm not sure)147 // fp> TODO: don't display this if categories plugin not installed... or depluginize categories (I'm not sure)
161 echo $this->disp_params['item_start'];148 echo $this->disp_params['item_start'];
162 echo '<strong><a href="'.$Blog->get('catdirurl').'">'.T_('Categories').'</a></strong>';149 echo '<strong><a href="'.$Blog->get('catdirurl').'">'.$this->T_('Categories').'</a></strong>';
163 echo $this->disp_params['item_end'];150 echo $this->disp_params['item_end'];
164 }151 }
165152
166 if( $this->disp_params['show_latestcomments'] )153 if( $this->disp_params['show_latestcomments'] )
167 {154 {
168 echo $this->disp_params['item_start'];155 echo $this->disp_params['item_start'];
169 echo '<strong><a href="'.$Blog->get('lastcommentsurl').'">'.T_('Latest comments').'</a></strong>';156 echo '<strong><a href="'.$Blog->get('lastcommentsurl').'">'.$this->T_('Latest comments').'</a></strong>';
170 echo $this->disp_params['item_end'];157 echo $this->disp_params['item_end'];
171 }158 }
172159
173160
=== added directory 'blogs/plugins/coll_item_list_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_item_list.widget.php' => 'blogs/plugins/coll_item_list_widget/_coll_item_list.widget.php'
--- blogs/inc/widgets/widgets/_coll_item_list.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_item_list_widget/_coll_item_list.widget.php 2009-12-21 15:13:16 +0000
@@ -39,8 +39,14 @@
39 */39 */
40 function coll_item_list_Widget( $db_row = NULL )40 function coll_item_list_Widget( $db_row = NULL )
41 {41 {
42 if( empty( $this->widget_name ) && empty( $this->widget_title ) )
43 { // this widget gets extended by others :-S
44 $this->widget_name = $this->T_('Universal Item list');
45 $this->widget_title = $this->T_('Items');
46 }
47
42 // Call parent constructor:48 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_item_list' );49 parent::ComponentWidget( $db_row, 'widget', 'coll_item_list' );
44 }50 }
4551
4652
@@ -58,98 +64,92 @@
58 $ItemTypeCache = & get_Cache( 'ItemTypeCache' );64 $ItemTypeCache = & get_Cache( 'ItemTypeCache' );
5965
60 $item_type_options = array(66 $item_type_options = array(
61 '#' => T_('Default'),67 '#' => $this->T_('Default'),
62 '' => T_('All'),68 '' => $this->T_('All'),
63 ) + $ItemTypeCache->get_option_array();69 ) + $ItemTypeCache->get_option_array();
6470
65 $r = array_merge( array(71 $r = array_merge( array(
66 'title' => array(
67 'label' => T_('Block title'),
68 'note' => T_('Title to display in your skin.'),
69 'size' => 60,
70 'defaultvalue' => T_('Items'),
71 ),
72 'title_link' => array(72 'title_link' => array(
73 'label' => T_('Link to blog'),73 'label' => $this->T_('Link to blog'),
74 'note' => T_('Link the block title to the blog?'),74 'note' => $this->T_('Link the block title to the blog?'),
75 'type' => 'checkbox',75 'type' => 'checkbox',
76 'defaultvalue' => false,76 'defaultvalue' => false,
77 ),77 ),
78 'item_type' => array(78 'item_type' => array(
79 'label' => T_('Item type'),79 'label' => $this->T_('Item type'),
80 'note' => T_('What kind of items do you want to list?'),80 'note' => $this->T_('What kind of items do you want to list?'),
81 'type' => 'select',81 'type' => 'select',
82 'options' => $item_type_options,82 'options' => $item_type_options,
83 'defaultvalue' => '#',83 'defaultvalue' => '#',
84 ),84 ),
85 'follow_mainlist' => array(85 'follow_mainlist' => array(
86 'label' => T_('Follow Main List'),86 'label' => $this->T_('Follow Main List'),
87 'note' => T_('Do you want to restrict to contents related to what is displayed in the main area?'),87 'note' => $this->T_('Do you want to restrict to contents related to what is displayed in the main area?'),
88 'type' => 'select', // should be a radio button set88 'type' => 'select', // should be a radio button set
89 'options' => array( 'no' => T_('No'), 'tags' => T_('By tags') ), // may be extended89 'options' => array( 'no' => $this->T_('No'), 'tags' => $this->T_('By tags') ), // may be extended
90 'defaultvalue' => 'none',90 'defaultvalue' => 'none',
91 ),91 ),
92 'blog_ID' => array(92 'blog_ID' => array(
93 'label' => T_( 'Blog' ),93 'label' => $this->T_( 'Blog' ),
94 'note' => T_( 'ID of the blog to use, leave empty for the current blog.' ),94 'note' => $this->T_( 'ID of the blog to use, leave empty for the current blog.' ),
95 'size' => 4,95 'size' => 4,
96 ),96 ),
97 'item_group_by' => array(97 'item_group_by' => array(
98 'label' => T_('Group by'),98 'label' => $this->T_('Group by'),
99 'note' => T_('Do you want to group the Items?'),99 'note' => $this->T_('Do you want to group the Items?'),
100 'type' => 'select', // should be a radio button set100 'type' => 'select', // should be a radio button set
101 'options' => array( 'none' => T_('None'), 'chapter' => T_('By category/chapter') ),101 'options' => array( 'none' => $this->T_('None'), 'chapter' => $this->T_('By category/chapter') ),
102 'defaultvalue' => 'none',102 'defaultvalue' => 'none',
103 ),103 ),
104 'order_by' => array(104 'order_by' => array(
105 'label' => T_('Order by'),105 'label' => $this->T_('Order by'),
106 'note' => T_('How to sort the items'),106 'note' => $this->T_('How to sort the items'),
107 'type' => 'select',107 'type' => 'select',
108 'options' => get_available_sort_options(),108 'options' => get_available_sort_options(),
109 'defaultvalue' => 'datestart',109 'defaultvalue' => 'datestart',
110 ),110 ),
111 'order_dir' => array(111 'order_dir' => array(
112 'label' => T_('Direction'),112 'label' => $this->T_('Direction'),
113 'note' => T_('How to sort the items'),113 'note' => $this->T_('How to sort the items'),
114 'type' => 'select', // should be a radio button set114 'type' => 'select', // should be a radio button set
115 'options' => array( 'ASC' => T_('Ascending'), 'DESC' => T_('Descending') ),115 'options' => array( 'ASC' => $this->T_('Ascending'), 'DESC' => $this->T_('Descending') ),
116 'defaultvalue' => 'DESC',116 'defaultvalue' => 'DESC',
117 ),117 ),
118 'limit' => array(118 'limit' => array(
119 'label' => T_( 'Max items' ),119 'label' => $this->T_( 'Max items' ),
120 'note' => T_( 'Maximum number of items to display.' ),120 'note' => $this->T_( 'Maximum number of items to display.' ),
121 'size' => 4,121 'size' => 4,
122 'defaultvalue' => 20,122 'defaultvalue' => 20,
123 ),123 ),
124 'item_title_link_type' => array(124 'item_title_link_type' => array(
125 'label' => T_('Link titles'),125 'label' => $this->T_('Link titles'),
126 'note' => T_('Where should titles be linked to?'),126 'note' => $this->T_('Where should titles be linked to?'),
127 'type' => 'select',127 'type' => 'select',
128 'options' => array(128 'options' => array(
129 'auto' => T_('Automatic'),129 'auto' => $this->T_('Automatic'),
130 'permalink' => T_('Item permalink'),130 'permalink' => $this->T_('Item permalink'),
131 'linkto_url' => T_('Item URL'),131 'linkto_url' => $this->T_('Item URL'),
132 'none' => T_('Nowhere'),132 'none' => $this->T_('Nowhere'),
133 ),133 ),
134 'defaultvalue' => 'auto',134 'defaultvalue' => 'auto',
135 ),135 ),
136 'disp_excerpt' => array(136 'disp_excerpt' => array(
137 'label' => T_( 'Excerpt' ),137 'label' => $this->T_( 'Excerpt' ),
138 'note' => T_( 'Display excerpt for each item.' ),138 'note' => $this->T_( 'Display excerpt for each item.' ),
139 'type' => 'checkbox',139 'type' => 'checkbox',
140 'defaultvalue' => false,140 'defaultvalue' => false,
141 ),141 ),
142 'disp_teaser' => array(142 'disp_teaser' => array(
143 'label' => T_( 'Content teaser' ),143 'label' => $this->T_( 'Content teaser' ),
144 'type' => 'checkbox',144 'type' => 'checkbox',
145 'defaultvalue' => false,145 'defaultvalue' => false,
146 'note' => T_( 'Display content teaser for each item.' ),146 'note' => $this->T_( 'Display content teaser for each item.' ),
147 ),147 ),
148 'disp_teaser_maxwords' => array(148 'disp_teaser_maxwords' => array(
149 'label' => T_( 'Max Words' ),149 'label' => $this->T_( 'Max Words' ),
150 'type' => 'integer',150 'type' => 'integer',
151 'defaultvalue' => 20,151 'defaultvalue' => 20,
152 'note' => T_( 'Max number of words for the teasers.' ),152 'note' => $this->T_( 'Max number of words for the teasers.' ),
153 ),153 ),
154 ), parent::get_param_definitions( $params ) );154 ), parent::get_param_definitions( $params ) );
155155
@@ -160,20 +160,11 @@
160160
161161
162 /**162 /**
163 * Get name of widget
164 */
165 function get_name()
166 {
167 return T_('Universal Item list');
168 }
169
170
171 /**
172 * Get a very short desc. Used in the widget list.163 * Get a very short desc. Used in the widget list.
173 */164 */
174 function get_short_desc()165 function get_short_desc()
175 {166 {
176 return format_to_output($this->disp_params['title']);167 return format_to_output($this->disp_params['widget_title']);
177 }168 }
178169
179170
@@ -182,7 +173,7 @@
182 */173 */
183 function get_desc()174 function get_desc()
184 {175 {
185 return T_('Can list Items (Posts/Pages/Links...) in a variety of ways.');176 return $this->T_('Can list Items (Posts/Pages/Links...) in a variety of ways.');
186 }177 }
187178
188179
@@ -207,7 +198,7 @@
207 if( empty($listBlog) )198 if( empty($listBlog) )
208 {199 {
209 echo $this->disp_params['block_start'];200 echo $this->disp_params['block_start'];
210 echo T_('The requested Blog doesn\'t exist any more!');201 echo $this->T_('The requested Blog doesn\'t exist any more!');
211 echo $this->disp_params['block_end'];202 echo $this->disp_params['block_end'];
212 return;203 return;
213 }204 }
@@ -294,7 +285,7 @@
294285
295 echo $this->disp_params['block_start'];286 echo $this->disp_params['block_start'];
296287
297 $title = sprintf( ( $this->disp_params[ 'title_link' ] ? '<a href="'.$listBlog->gen_blogurl().'" rel="nofollow">%s</a>' : '%s' ), $this->disp_params[ 'title' ] );288 $title = sprintf( ( $this->disp_params[ 'title_link' ] ? '<a href="'.$listBlog->gen_blogurl().'" rel="nofollow">%s</a>' : '%s' ), $this->disp_params[ 'widget_title' ] );
298 $this->disp_title( $title );289 $this->disp_title( $title );
299290
300 echo $this->disp_params['list_start'];291 echo $this->disp_params['list_start'];
@@ -378,7 +369,7 @@
378 $Item->more_link( array(369 $Item->more_link( array(
379 'before' => '',370 'before' => '',
380 'after' => '',371 'after' => '',
381 'link_text' => T_('more').' &raquo;',372 'link_text' => $this->T_('more').' &raquo;',
382 ) );373 ) );
383 */374 */
384 }375 }
385376
=== added directory 'blogs/plugins/coll_link_list_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_link_list.widget.php' => 'blogs/plugins/coll_link_list_widget/_coll_link_list.widget.php'
--- blogs/inc/widgets/widgets/_coll_link_list.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_link_list_widget/_coll_link_list.widget.php 2009-12-21 15:13:16 +0000
@@ -23,7 +23,8 @@
23 */23 */
24if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );24if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );
2525
26load_class( 'widgets/widgets/_coll_item_list.widget.php' );26$wiCache = get_Cache('WidgetCache');
27$wiCache->load_widget( 'coll_item_list' );
2728
28/**29/**
29 * links_widget class30 * links_widget class
@@ -39,8 +40,11 @@
39 */40 */
40 function coll_link_list_Widget( $db_row = NULL )41 function coll_link_list_Widget( $db_row = NULL )
41 {42 {
43 $this->widget_name = $this->T_('Simple Sidebar Links list');
44 $this->widget_title = $this->T_('Links');
45
42 // Call parent constructor:46 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_link_list' );47 parent::ComponentWidget( $db_row, 'widget', 'coll_link_list' );
44 }48 }
4549
4650
@@ -55,7 +59,6 @@
55 // This is derived from coll_post_list_Widget, so we DO NOT ADD ANY param here!59 // This is derived from coll_post_list_Widget, so we DO NOT ADD ANY param here!
56 $r = parent::get_param_definitions( $params );60 $r = parent::get_param_definitions( $params );
57 // We only change the defaults and hide some params.61 // We only change the defaults and hide some params.
58 $r['title']['defaultvalue'] = T_('Links');
59 $r['title_link']['no_edit'] = true;62 $r['title_link']['no_edit'] = true;
60 $r['item_type']['no_edit'] = true;63 $r['item_type']['no_edit'] = true;
61 $r['follow_mainlist']['no_edit'] = true;64 $r['follow_mainlist']['no_edit'] = true;
@@ -71,13 +74,6 @@
71 }74 }
7275
7376
74 /**
75 * Get name of widget
76 */
77 function get_name()
78 {
79 return T_('Simple Sidebar Links list');
80 }
8177
8278
83 /**79 /**
@@ -85,7 +81,7 @@
85 */81 */
86 function get_short_desc()82 function get_short_desc()
87 {83 {
88 return format_to_output($this->disp_params['title']);84 return format_to_output($this->disp_params['widget_title']);
89 }85 }
9086
9187
@@ -94,7 +90,7 @@
94 */90 */
95 function get_desc()91 function get_desc()
96 {92 {
97 return T_('Simplified Item list for listing Sidebar links.');93 return $this->T_('Simplified Item list for listing Sidebar links.');
98 }94 }
9995
10096
10197
=== added directory 'blogs/plugins/coll_logo_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_logo.widget.php' => 'blogs/plugins/coll_logo_widget/_coll_logo.widget.php'
--- blogs/inc/widgets/widgets/_coll_logo.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_logo_widget/_coll_logo.widget.php 2009-12-21 15:13:16 +0000
@@ -39,17 +39,9 @@
39 */39 */
40 function coll_logo_Widget( $db_row = NULL )40 function coll_logo_Widget( $db_row = NULL )
41 {41 {
42 $this->widget_name = $this->T_('Image / Blog logo');
42 // Call parent constructor:43 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_logo' );44 parent::ComponentWidget( $db_row, 'widget', 'coll_logo' );
44 }
45
46
47 /**
48 * Get name of widget
49 */
50 function get_name()
51 {
52 return T_('Image / Blog logo');
53 }45 }
5446
5547
@@ -77,7 +69,7 @@
77 */69 */
78 function get_desc()70 function get_desc()
79 {71 {
80 return T_('Include an image/logo from the blog\'s file root.');72 return $this->T_('Include an image/logo from the blog\'s file root.');
81 }73 }
8274
8375
@@ -91,8 +83,8 @@
91 {83 {
92 $r = array_merge( array(84 $r = array_merge( array(
93 'logo_file' => array(85 'logo_file' => array(
94 'label' => T_('Image filename'),86 'label' => $this->T_('Image filename'),
95 'note' => T_('The image/logo file must be uploaded to the root of the Blog\'s media dir'),87 'note' => $this->T_('The image/logo file must be uploaded to the root of the Blog\'s media dir'),
96 'defaultvalue' => 'logo.png',88 'defaultvalue' => 'logo.png',
97 'valid_pattern' => array( 'pattern'=>'¤^[a-z0-9_\-][a-z0-9_.\-]*$¤i',89 'valid_pattern' => array( 'pattern'=>'¤^[a-z0-9_\-][a-z0-9_.\-]*$¤i',
98 'error'=>T_('Invalid filename.') ),90 'error'=>T_('Invalid filename.') ),
9991
=== added directory 'blogs/plugins/coll_longdesc_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_longdesc.widget.php' => 'blogs/plugins/coll_longdesc_widget/_coll_longdesc.widget.php'
--- blogs/inc/widgets/widgets/_coll_longdesc.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_longdesc_widget/_coll_longdesc.widget.php 2009-12-21 15:13:16 +0000
@@ -39,17 +39,10 @@
39 */39 */
40 function coll_longdesc_Widget( $db_row = NULL )40 function coll_longdesc_Widget( $db_row = NULL )
41 {41 {
42 $this->widget_name = $this->T_('Long Description of this Blog');
43 $this->widget_title = '';
42 // Call parent constructor:44 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_longdesc' );45 parent::ComponentWidget( $db_row, 'widget', 'coll_longdesc' );
44 }
45
46
47 /**
48 * Get name of widget
49 */
50 function get_name()
51 {
52 return T_('Long Description of this Blog');
53 }46 }
5447
5548
@@ -58,7 +51,7 @@
58 */51 */
59 function get_short_desc()52 function get_short_desc()
60 {53 {
61 return format_to_output($this->disp_params['title']);54 return format_to_output($this->disp_params['widget_title']);
62 }55 }
6356
6457
@@ -68,33 +61,11 @@
68 function get_desc()61 function get_desc()
69 {62 {
70 global $Blog;63 global $Blog;
71 return sprintf( T_('Long description from the blog\'s <a %s>general settings</a>.'),64 return sprintf( $this->T_('Long description from the blog\'s <a %s>general settings</a>.'),
72 'href="?ctrl=coll_settings&tab=general&blog='.$Blog->ID.'"' );65 'href="?ctrl=coll_settings&tab=general&blog='.$Blog->ID.'"' );
73 }66 }
7467
7568
76 /**
77 * Get definitions for editable params
78 *
79 * @see Plugin::GetDefaultSettings()
80 * @param local params like 'for_editing' => true
81 */
82 function get_param_definitions( $params )
83 {
84 $r = array_merge( array(
85 'title' => array(
86 'label' => T_('Block title'),
87 'note' => T_( 'Title to display in your skin.' ),
88 'size' => 40,
89 'defaultvalue' => '',
90 ),
91
92 ), parent::get_param_definitions( $params ) );
93
94 return $r;
95 }
96
97
98 /**69 /**
99 * Display the widget!70 * Display the widget!
100 *71 *
@@ -119,6 +90,4 @@
119 return true;90 return true;
120 }91 }
121}92}
122
123
124?>93?>
125\ No newline at end of file94\ No newline at end of file
12695
=== added directory 'blogs/plugins/coll_media_index_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_media_index.widget.php' => 'blogs/plugins/coll_media_index_widget/_coll_media_index.widget.php'
--- blogs/inc/widgets/widgets/_coll_media_index.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_media_index_widget/_coll_media_index.widget.php 2009-12-21 15:13:16 +0000
@@ -40,8 +40,10 @@
40 */40 */
41 function coll_media_index_Widget( $db_row = NULL )41 function coll_media_index_Widget( $db_row = NULL )
42 {42 {
43 $this->widget_name = $this->T_('Photo index');
44 $this->widget_title = $this->T_('Recent photos');
43 // Call parent constructor:45 // Call parent constructor:
44 parent::ComponentWidget( $db_row, 'core', 'coll_media_index' );46 parent::ComponentWidget( $db_row, 'widget', 'coll_media_index' );
45 }47 }
4648
4749
@@ -56,55 +58,49 @@
56 load_funcs( 'files/model/_image.funcs.php' );58 load_funcs( 'files/model/_image.funcs.php' );
5759
58 $r = array_merge( array(60 $r = array_merge( array(
59 'title' => array(
60 'label' => T_('Block title'),
61 'note' => T_( 'Title to display in your skin.' ),
62 'size' => 40,
63 'defaultvalue' => T_('Recent photos'),
64 ),
65 'thumb_size' => array(61 'thumb_size' => array(
66 'label' => T_('Thumbnail size'),62 'label' => $this->T_('Thumbnail size'),
67 'note' => T_('Cropping and sizing of thumbnails'),63 'note' => $this->T_('Cropping and sizing of thumbnails'),
68 'type' => 'select',64 'type' => 'select',
69 'options' => get_available_thumb_sizes(),65 'options' => get_available_thumb_sizes(),
70 'defaultvalue' => 'crop-80x80',66 'defaultvalue' => 'crop-80x80',
71 ),67 ),
72 'thumb_layout' => array(68 'thumb_layout' => array(
73 'label' => T_('Layout'),69 'label' => $this->T_('Layout'),
74 'note' => T_('How to lay out the thumbnails'),70 'note' => $this->T_('How to lay out the thumbnails'),
75 'type' => 'select',71 'type' => 'select',
76 'options' => array( 'grid' => T_( 'Grid' ), 'list' => T_( 'List' ) ),72 'options' => array( 'grid' => $this->T_( 'Grid' ), 'list' => $this->T_( 'List' ) ),
77 'defaultvalue' => 'grid',73 'defaultvalue' => 'grid',
78 ),74 ),
79 'grid_nb_cols' => array(75 'grid_nb_cols' => array(
80 'label' => T_( 'Columns' ),76 'label' => $this->T_( 'Columns' ),
81 'note' => T_( 'Number of columns in grid mode.' ),77 'note' => $this->T_( 'Number of columns in grid mode.' ),
82 'size' => 4,78 'size' => 4,
83 'defaultvalue' => 2,79 'defaultvalue' => 2,
84 ),80 ),
85 'limit' => array(81 'limit' => array(
86 'label' => T_( 'Max items' ),82 'label' => $this->T_( 'Max items' ),
87 'note' => T_( 'Maximum number of items to display.' ),83 'note' => $this->T_( 'Maximum number of items to display.' ),
88 'size' => 4,84 'size' => 4,
89 'defaultvalue' => 3,85 'defaultvalue' => 3,
90 ),86 ),
91 'order_by' => array(87 'order_by' => array(
92 'label' => T_('Order by'),88 'label' => $this->T_('Order by'),
93 'note' => T_('How to sort the items'),89 'note' => $this->T_('How to sort the items'),
94 'type' => 'select',90 'type' => 'select',
95 'options' => get_available_sort_options(),91 'options' => get_available_sort_options(),
96 'defaultvalue' => 'datestart',92 'defaultvalue' => 'datestart',
97 ),93 ),
98 'order_dir' => array(94 'order_dir' => array(
99 'label' => T_('Direction'),95 'label' => $this->T_('Direction'),
100 'note' => T_('How to sort the items'),96 'note' => $this->T_('How to sort the items'),
101 'type' => 'select',97 'type' => 'select',
102 'options' => array( 'ASC' => T_('Ascending'), 'DESC' => T_('Descending') ),98 'options' => array( 'ASC' => $this->T_('Ascending'), 'DESC' => $this->T_('Descending') ),
103 'defaultvalue' => 'DESC',99 'defaultvalue' => 'DESC',
104 ),100 ),
105 'blog_ID' => array(101 'blog_ID' => array(
106 'label' => T_( 'Blogs' ),102 'label' => $this->T_( 'Blogs' ),
107 'note' => T_( 'IDs of the blogs to use, leave empty for the current blog. Separate multiple blogs by commas.' ),103 'note' => $this->T_( 'IDs of the blogs to use, leave empty for the current blog. Separate multiple blogs by commas.' ),
108 'size' => 4,104 'size' => 4,
109 ),105 ),
110 ), parent::get_param_definitions( $params ) );106 ), parent::get_param_definitions( $params ) );
@@ -114,20 +110,11 @@
114110
115111
116 /**112 /**
117 * Get name of widget
118 */
119 function get_name()
120 {
121 return T_('Photo index');
122 }
123
124
125 /**
126 * Get a very short desc. Used in the widget list.113 * Get a very short desc. Used in the widget list.
127 */114 */
128 function get_short_desc()115 function get_short_desc()
129 {116 {
130 return format_to_output($this->disp_params['title']);117 return format_to_output($this->disp_params['widget_title']);
131 }118 }
132119
133120
@@ -136,7 +123,7 @@
136 */123 */
137 function get_desc()124 function get_desc()
138 {125 {
139 return T_('Index of photos; click goes to original image post.');126 return $this->T_('Index of photos; click goes to original image post.');
140 }127 }
141128
142129
143130
=== added directory 'blogs/plugins/coll_page_list_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_page_list.widget.php' => 'blogs/plugins/coll_page_list_widget/_coll_page_list.widget.php'
--- blogs/inc/widgets/widgets/_coll_page_list.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_page_list_widget/_coll_page_list.widget.php 2009-12-21 15:13:16 +0000
@@ -23,7 +23,8 @@
23 */23 */
24if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );24if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );
2525
26load_class( 'widgets/widgets/_coll_item_list.widget.php' );26$wiCache = get_Cache('WidgetCache');
27$wiCache->load_widget( 'coll_item_list' );
2728
28/**29/**
29 * ComponentWidget Class30 * ComponentWidget Class
@@ -39,8 +40,10 @@
39 */40 */
40 function coll_page_list_Widget( $db_row = NULL )41 function coll_page_list_Widget( $db_row = NULL )
41 {42 {
43 $this->widget_name = $this->T_('Simple Page list');
44 $this->widget_title = $this->T_('Pages');
42 // Call parent constructor:45 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_page_list' );46 parent::ComponentWidget( $db_row, 'widget', 'coll_page_list' );
44 }47 }
4548
4649
@@ -55,7 +58,6 @@
55 // This is derived from coll_post_list_Widget, so we DO NOT ADD ANY param here!58 // This is derived from coll_post_list_Widget, so we DO NOT ADD ANY param here!
56 $r = parent::get_param_definitions( $params );59 $r = parent::get_param_definitions( $params );
57 // We only change the defaults and hide some params.60 // We only change the defaults and hide some params.
58 $r['title']['defaultvalue'] = T_('Pages');
59 $r['title_link']['no_edit'] = true;61 $r['title_link']['no_edit'] = true;
60 $r['item_type']['no_edit'] = true;62 $r['item_type']['no_edit'] = true;
61 $r['follow_mainlist']['no_edit'] = true;63 $r['follow_mainlist']['no_edit'] = true;
@@ -72,20 +74,11 @@
7274
7375
74 /**76 /**
75 * Get name of widget
76 */
77 function get_name()
78 {
79 return T_('Simple Page list');
80 }
81
82
83 /**
84 * Get a very short desc. Used in the widget list.77 * Get a very short desc. Used in the widget list.
85 */78 */
86 function get_short_desc()79 function get_short_desc()
87 {80 {
88 return format_to_output($this->disp_params['title']);81 return format_to_output($this->disp_params['widget_title']);
89 }82 }
9083
9184
@@ -94,7 +87,7 @@
94 */87 */
95 function get_desc()88 function get_desc()
96 {89 {
97 return T_('Simplified Item list for listing pages.');90 return $this->T_('Simplified Item list for listing pages.');
98 }91 }
9992
10093
10194
=== added directory 'blogs/plugins/coll_post_list_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_post_list.widget.php' => 'blogs/plugins/coll_post_list_widget/_coll_post_list.widget.php'
--- blogs/inc/widgets/widgets/_coll_post_list.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_post_list_widget/_coll_post_list.widget.php 2009-12-21 15:13:16 +0000
@@ -23,7 +23,8 @@
23 */23 */
24if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );24if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );
2525
26load_class( 'widgets/widgets/_coll_item_list.widget.php' );26$wiCache = get_Cache('WidgetCache');
27$wiCache->load_widget( 'coll_item_list' );
2728
28/**29/**
29 * ComponentWidget Class30 * ComponentWidget Class
@@ -39,8 +40,10 @@
39 */40 */
40 function coll_post_list_Widget( $db_row = NULL )41 function coll_post_list_Widget( $db_row = NULL )
41 {42 {
43 $this->widget_name = $this->T_('Simple Post list');
44 $this->widget_title = $this->T_('Contents');
42 // Call parent constructor:45 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_post_list' );46 parent::ComponentWidget( $db_row, 'widget', 'coll_post_list' );
44 }47 }
4548
4649
@@ -55,7 +58,6 @@
55 // This is derived from coll_post_list_Widget, so we DO NOT ADD ANY param here!58 // This is derived from coll_post_list_Widget, so we DO NOT ADD ANY param here!
56 $r = parent::get_param_definitions( $params );59 $r = parent::get_param_definitions( $params );
57 // We only change the defaults and hide some params.60 // We only change the defaults and hide some params.
58 $r['title']['defaultvalue'] = T_('Contents');
59 $r['title_link']['no_edit'] = true;61 $r['title_link']['no_edit'] = true;
60 $r['item_type']['no_edit'] = true;62 $r['item_type']['no_edit'] = true;
61 $r['follow_mainlist']['no_edit'] = true;63 $r['follow_mainlist']['no_edit'] = true;
@@ -72,20 +74,11 @@
7274
7375
74 /**76 /**
75 * Get name of widget
76 */
77 function get_name()
78 {
79 return T_('Simple Post list');
80 }
81
82
83 /**
84 * Get a very short desc. Used in the widget list.77 * Get a very short desc. Used in the widget list.
85 */78 */
86 function get_short_desc()79 function get_short_desc()
87 {80 {
88 return format_to_output($this->disp_params['title']);81 return format_to_output($this->disp_params['widget_title']);
89 }82 }
9083
9184
@@ -94,7 +87,7 @@
94 */87 */
95 function get_desc()88 function get_desc()
96 {89 {
97 return T_('Simplified Item list for listing posts.');90 return $this->T_('Simplified Item list for listing posts.');
98 }91 }
9992
10093
10194
=== added directory 'blogs/plugins/coll_related_post_list_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_related_post_list.widget.php' => 'blogs/plugins/coll_related_post_list_widget/_coll_related_post_list.widget.php'
--- blogs/inc/widgets/widgets/_coll_related_post_list.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_related_post_list_widget/_coll_related_post_list.widget.php 2009-12-21 15:13:16 +0000
@@ -23,7 +23,8 @@
23 */23 */
24if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );24if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );
2525
26load_class( 'widgets/widgets/_coll_item_list.widget.php' );26$wiCache = get_Cache('WidgetCache');
27$wiCache->load_widget( 'coll_item_list' );
2728
28/**29/**
29 * ComponentWidget Class30 * ComponentWidget Class
@@ -39,8 +40,10 @@
39 */40 */
40 function coll_related_post_list_Widget( $db_row = NULL )41 function coll_related_post_list_Widget( $db_row = NULL )
41 {42 {
43 $this->widget_name = $this->T_('Simple Related Posts list');
44 $this->widget_title = $this->T_('Related posts');
42 // Call parent constructor:45 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_related_post_list' );46 parent::ComponentWidget( $db_row, 'widget', 'coll_related_post_list' );
44 }47 }
4548
4649
@@ -55,7 +58,6 @@
55 // This is derived from coll_post_list_Widget, so we DO NOT ADD ANY param here!58 // This is derived from coll_post_list_Widget, so we DO NOT ADD ANY param here!
56 $r = parent::get_param_definitions( $params );59 $r = parent::get_param_definitions( $params );
57 // We only change the defaults and hide some params.60 // We only change the defaults and hide some params.
58 $r['title']['defaultvalue'] = T_('Related posts');
59 $r['title_link']['no_edit'] = true;61 $r['title_link']['no_edit'] = true;
60 $r['item_type']['no_edit'] = true;62 $r['item_type']['no_edit'] = true;
61 $r['follow_mainlist']['no_edit'] = true;63 $r['follow_mainlist']['no_edit'] = true;
@@ -72,20 +74,11 @@
7274
7375
74 /**76 /**
75 * Get name of widget
76 */
77 function get_name()
78 {
79 return T_('Simple Related Posts list');
80 }
81
82
83 /**
84 * Get a very short desc. Used in the widget list.77 * Get a very short desc. Used in the widget list.
85 */78 */
86 function get_short_desc()79 function get_short_desc()
87 {80 {
88 return format_to_output($this->disp_params['title']);81 return format_to_output($this->disp_params['widget_title']);
89 }82 }
9083
9184
@@ -94,7 +87,7 @@
94 */87 */
95 function get_desc()88 function get_desc()
96 {89 {
97 return T_('Simplified Item list for listing posts related to the Main list.');90 return $this->T_('Simplified Item list for listing posts related to the Main list.');
98 }91 }
9992
10093
10194
=== added directory 'blogs/plugins/coll_search_form_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_search_form.widget.php' => 'blogs/plugins/coll_search_form_widget/_coll_search_form.widget.php'
--- blogs/inc/widgets/widgets/_coll_search_form.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_search_form_widget/_coll_search_form.widget.php 2009-12-21 15:13:16 +0000
@@ -39,17 +39,10 @@
39 */39 */
40 function coll_search_form_Widget( $db_row = NULL )40 function coll_search_form_Widget( $db_row = NULL )
41 {41 {
42 $this->widget_name = $this->T_('Search Form');
43 $this->widget_title = $this->T_('Search');
42 // Call parent constructor:44 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_search_form' );45 parent::ComponentWidget( $db_row, 'widget', 'coll_search_form' );
44 }
45
46
47 /**
48 * Get name of widget
49 */
50 function get_name()
51 {
52 return T_('Search Form');
53 }46 }
5447
5548
@@ -58,7 +51,7 @@
58 */51 */
59 function get_short_desc()52 function get_short_desc()
60 {53 {
61 return format_to_output($this->disp_params['title']);54 return format_to_output($this->disp_params['widget_title']);
62 }55 }
6356
6457
@@ -67,7 +60,7 @@
67 */60 */
68 function get_desc()61 function get_desc()
69 {62 {
70 return T_('Display search form');63 return $this->T_('Display search form');
71 }64 }
7265
7366
@@ -80,15 +73,9 @@
80 function get_param_definitions( $params )73 function get_param_definitions( $params )
81 {74 {
82 $r = array_merge( array(75 $r = array_merge( array(
83 'title' => array(
84 'label' => T_('Block title'),
85 'note' => T_( 'Title to display in your skin.' ),
86 'size' => 40,
87 'defaultvalue' => T_('Search'),
88 ),
89 'disp_search_options' => array(76 'disp_search_options' => array(
90 'label' => T_( 'Search options' ),77 'label' => $this->T_( 'Search options' ),
91 'note' => T_( 'Display radio buttons for "All Words", "Some Word" and "Entire Phrase"' ),78 'note' => $this->T_( 'Display radio buttons for "All Words", "Some Word" and "Entire Phrase"' ),
92 'type' => 'checkbox',79 'type' => 'checkbox',
93 'defaultvalue' => true,80 'defaultvalue' => true,
94 ),81 ),
@@ -124,12 +111,12 @@
124 {111 {
125 $sentence = get_param( 'sentence' );112 $sentence = get_param( 'sentence' );
126 echo '<div class="search_options">';113 echo '<div class="search_options">';
127 echo '<div class="search_option"><input type="radio" name="sentence" value="AND" id="sentAND" '.( $sentence=='AND' ? 'checked="checked" ' : '' ).'/><label for="sentAND">'.T_('All Words').'</label></div>';114 echo '<div class="search_option"><input type="radio" name="sentence" value="AND" id="sentAND" '.( $sentence=='AND' ? 'checked="checked" ' : '' ).'/><label for="sentAND">'.$this->T_('All Words').'</label></div>';
128 echo '<div class="search_option"><input type="radio" name="sentence" value="OR" id="sentOR" '.( $sentence=='OR' ? 'checked="checked" ' : '' ).'/><label for="sentOR">'.T_('Some Word').'</label></div>';115 echo '<div class="search_option"><input type="radio" name="sentence" value="OR" id="sentOR" '.( $sentence=='OR' ? 'checked="checked" ' : '' ).'/><label for="sentOR">'.$this->T_('Some Word').'</label></div>';
129 echo '<div class="search_option"><input type="radio" name="sentence" value="sentence" id="sentence" '.( $sentence=='sentence' ? 'checked="checked" ' : '' ).'/><label for="sentence">'.T_('Entire phrase').'</label></div>';116 echo '<div class="search_option"><input type="radio" name="sentence" value="sentence" id="sentence" '.( $sentence=='sentence' ? 'checked="checked" ' : '' ).'/><label for="sentence">'.$this->T_('Entire phrase').'</label></div>';
130 echo '</div>';117 echo '</div>';
131 }118 }
132 echo '<input type="submit" name="submit" class="submit" value="'.T_('Search').'" />';119 echo '<input type="submit" name="submit" class="submit" value="'.$this->T_('Search').'" />';
133 echo '</form>';120 echo '</form>';
134121
135 echo $this->disp_params['block_end'];122 echo $this->disp_params['block_end'];
136123
=== added directory 'blogs/plugins/coll_tag_cloud_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_tag_cloud.widget.php' => 'blogs/plugins/coll_tag_cloud_widget/_coll_tag_cloud.widget.php'
--- blogs/inc/widgets/widgets/_coll_tag_cloud.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_tag_cloud_widget/_coll_tag_cloud.widget.php 2009-12-21 15:13:16 +0000
@@ -39,8 +39,10 @@
39 */39 */
40 function coll_tag_cloud_Widget( $db_row = NULL )40 function coll_tag_cloud_Widget( $db_row = NULL )
41 {41 {
42 $this->widget_name = $this->T_('Tag cloud');
43 $this->widget_title = $this->T_('Tag cloud');
42 // Call parent constructor:44 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_tag_cloud' );45 parent::ComponentWidget( $db_row, 'widget', 'coll_tag_cloud' );
44 }46 }
4547
4648
@@ -60,20 +62,11 @@
6062
6163
62 /**64 /**
63 * Get name of widget
64 */
65 function get_name()
66 {
67 return T_('Tag cloud');
68 }
69
70
71 /**
72 * Get a very short desc. Used in the widget list.65 * Get a very short desc. Used in the widget list.
73 */66 */
74 function get_short_desc()67 function get_short_desc()
75 {68 {
76 return format_to_output($this->disp_params['title']);69 return format_to_output($this->disp_params['widget_title']);
77 }70 }
7871
7972
@@ -82,7 +75,7 @@
82 */75 */
83 function get_desc()76 function get_desc()
84 {77 {
85 return T_('Cloud of all tags; click filters blog on selected tag.');78 return $this->T_('Cloud of all tags; click filters blog on selected tag.');
86 }79 }
8780
8881
@@ -95,33 +88,27 @@
95 function get_param_definitions( $params )88 function get_param_definitions( $params )
96 {89 {
97 $r = array_merge( array(90 $r = array_merge( array(
98 'title' => array(
99 'type' => 'text',
100 'label' => T_('Block title'),
101 'defaultvalue' => T_('Tag cloud'),
102 'maxlength' => 100,
103 ),
104 'max_tags' => array(91 'max_tags' => array(
105 'type' => 'integer',92 'type' => 'integer',
106 'label' => T_('Max # of tags'),93 'label' => $this->T_('Max # of tags'),
107 'size' => 4,94 'size' => 4,
108 'defaultvalue' => 50,95 'defaultvalue' => 50,
109 ),96 ),
110 'tag_separator' => array(97 'tag_separator' => array(
111 'type' => 'text',98 'type' => 'text',
112 'label' => T_('Tag separator'),99 'label' => $this->T_('Tag separator'),
113 'defaultvalue' => ' ',100 'defaultvalue' => ' ',
114 'maxlength' => 100,101 'maxlength' => 100,
115 ),102 ),
116 'tag_min_size' => array(103 'tag_min_size' => array(
117 'type' => 'integer',104 'type' => 'integer',
118 'label' => T_('Min size'),105 'label' => $this->T_('Min size'),
119 'size' => 3,106 'size' => 3,
120 'defaultvalue' => 8,107 'defaultvalue' => 8,
121 ),108 ),
122 'tag_max_size' => array(109 'tag_max_size' => array(
123 'type' => 'integer',110 'type' => 'integer',
124 'label' => T_('Max size'),111 'label' => $this->T_('Max size'),
125 'size' => 3,112 'size' => 3,
126 'defaultvalue' => 22,113 'defaultvalue' => 22,
127 ),114 ),
@@ -202,7 +189,7 @@
202189
203 echo $Blog->get_tag_link( $row->tag_name, $tag_name_disp, array(190 echo $Blog->get_tag_link( $row->tag_name, $tag_name_disp, array(
204 'style' => 'font-size: '.$size.'pt;',191 'style' => 'font-size: '.$size.'pt;',
205 'title' => sprintf( T_('%d posts'), $row->tag_count ) ) );192 'title' => sprintf( $this->T_('%d posts'), $row->tag_count ) ) );
206 $count++;193 $count++;
207 }194 }
208 echo $this->disp_params['tag_cloud_end'];195 echo $this->disp_params['tag_cloud_end'];
209196
=== added directory 'blogs/plugins/coll_tagline_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_tagline.widget.php' => 'blogs/plugins/coll_tagline_widget/_coll_tagline.widget.php'
--- blogs/inc/widgets/widgets/_coll_tagline.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_tagline_widget/_coll_tagline.widget.php 2009-12-21 15:13:16 +0000
@@ -39,17 +39,10 @@
39 */39 */
40 function coll_tagline_Widget( $db_row = NULL )40 function coll_tagline_Widget( $db_row = NULL )
41 {41 {
42 $this->widget_name = $this->T_('Blog tagline');
43 $this->widget_title = '';
42 // Call parent constructor:44 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_tagline' );45 parent::ComponentWidget( $db_row, 'widget', 'coll_tagline' );
44 }
45
46
47 /**
48 * Get name of widget
49 */
50 function get_name()
51 {
52 return T_('Blog tagline');
53 }46 }
5447
5548
@@ -70,7 +63,7 @@
70 function get_desc()63 function get_desc()
71 {64 {
72 global $Blog;65 global $Blog;
73 return sprintf( T_('&laquo;%s&raquo; from the blog\'s <a %s>general settings</a>.'),66 return sprintf( $this->T_('&laquo;%s&raquo; from the blog\'s <a %s>general settings</a>.'),
74 '<strong>'.$Blog->dget('tagline').'</strong>', 'href="?ctrl=coll_settings&tab=general&blog='.$Blog->ID.'"' );67 '<strong>'.$Blog->dget('tagline').'</strong>', 'href="?ctrl=coll_settings&tab=general&blog='.$Blog->ID.'"' );
75 }68 }
7669
@@ -88,6 +81,8 @@
8881
89 // Collection tagline:82 // Collection tagline:
90 echo $this->disp_params['block_start'];83 echo $this->disp_params['block_start'];
84 $this->disp_title();
85
91 // TODO: there appears to be no possibility to wrap the tagline in e.g. "<h2>%s</h2>"86 // TODO: there appears to be no possibility to wrap the tagline in e.g. "<h2>%s</h2>"
92 // Should there be a widget param for this? fp> probably yes87 // Should there be a widget param for this? fp> probably yes
93 $Blog->disp( 'tagline', 'htmlbody' );88 $Blog->disp( 'tagline', 'htmlbody' );
@@ -96,6 +91,4 @@
96 return true;91 return true;
97 }92 }
98}93}
99
100
101?>94?>
10295
=== added directory 'blogs/plugins/coll_title_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_title.widget.php' => 'blogs/plugins/coll_title_widget/_coll_title.widget.php'
--- blogs/inc/widgets/widgets/_coll_title.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_title_widget/_coll_title.widget.php 2009-12-21 15:13:16 +0000
@@ -39,17 +39,10 @@
39 */39 */
40 function coll_title_Widget( $db_row = NULL )40 function coll_title_Widget( $db_row = NULL )
41 {41 {
42 $this->widget_name = $this->T_('Blog title');
43 $this->widget_title = '';
42 // Call parent constructor:44 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_title' );45 parent::ComponentWidget( $db_row, 'widget', 'coll_title' );
44 }
45
46
47 /**
48 * Get name of widget
49 */
50 function get_name()
51 {
52 return T_('Blog title');
53 }46 }
5447
5548
@@ -70,7 +63,7 @@
70 function get_desc()63 function get_desc()
71 {64 {
72 global $Blog;65 global $Blog;
73 return sprintf( T_('&laquo;%s&raquo; from the blog\'s <a %s>general settings</a>.'),66 return sprintf( $this->T_('&laquo;%s&raquo; from the blog\'s <a %s>general settings</a>.'),
74 '<strong>'.$Blog->dget('name').'</strong>', 'href="?ctrl=coll_settings&tab=general&blog='.$Blog->ID.'"' );67 '<strong>'.$Blog->dget('name').'</strong>', 'href="?ctrl=coll_settings&tab=general&blog='.$Blog->ID.'"' );
75 }68 }
7669
7770
=== added directory 'blogs/plugins/coll_xml_feeds_widget'
=== renamed file 'blogs/inc/widgets/widgets/_coll_xml_feeds.widget.php' => 'blogs/plugins/coll_xml_feeds_widget/_coll_xml_feeds.widget.php'
--- blogs/inc/widgets/widgets/_coll_xml_feeds.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/coll_xml_feeds_widget/_coll_xml_feeds.widget.php 2009-12-21 15:13:16 +0000
@@ -39,17 +39,10 @@
39 */39 */
40 function coll_xml_feeds_Widget( $db_row = NULL )40 function coll_xml_feeds_Widget( $db_row = NULL )
41 {41 {
42 $this->widget_name = $this->T_('XML Feeds (RSS / Atom)');
43 $this->widget_title = '$icon$ '.$this->T_('XML Feeds');
42 // Call parent constructor:44 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'coll_xml_feeds' );45 parent::ComponentWidget( $db_row, 'widget', 'coll_xml_feeds' );
44 }
45
46
47 /**
48 * Get name of widget
49 */
50 function get_name()
51 {
52 return T_('XML Feeds (RSS / Atom)');
53 }46 }
5447
5548
@@ -67,7 +60,7 @@
67 */60 */
68 function get_desc()61 function get_desc()
69 {62 {
70 return T_('List of all available XML feeds.');63 return $this->T_('List of all available XML feeds.');
71 }64 }
7265
7366
@@ -81,22 +74,16 @@
81 {74 {
82 global $use_strict;75 global $use_strict;
83 $r = array_merge( array(76 $r = array_merge( array(
84 'title' => array(
85 'label' => T_( 'Title' ),
86 'size' => 40,
87 'note' => T_( 'This is the title to display, $icon$ will be replaced by the feed icon' ),
88 'defaultvalue' => '$icon$ '.T_('XML Feeds'),
89 ),
90 'disp_info_link' => array(77 'disp_info_link' => array(
91 'label' => T_( 'Help link' ),78 'label' => $this->T_( 'Help link' ),
92 'type' => 'checkbox',79 'type' => 'checkbox',
93 'note' => T_( 'Check this to display "What is RSS?" link' ),80 'note' => $this->T_( 'Check this to display "What is RSS?" link' ),
94 'defaultvalue' => 1,81 'defaultvalue' => 1,
95 ),82 ),
96 'info_link' => array(83 'info_link' => array(
97 'label' => T_( 'New Window' ),84 'label' => $this->T_( 'New Window' ),
98 'type' => 'checkbox',85 'type' => 'checkbox',
99 'note' => T_( 'Check this to add target="_blank" to the "What is RSS?" link' ),86 'note' => $this->T_( 'Check this to add target="_blank" to the "What is RSS?" link' ),
100 'defaultvalue' => !$use_strict,87 'defaultvalue' => !$use_strict,
101 ),88 ),
102 ), parent::get_param_definitions( $params ) );89 ), parent::get_param_definitions( $params ) );
@@ -109,7 +96,7 @@
109 {96 {
110 global $rsc_url;97 global $rsc_url;
11198
112 $title = str_replace( '$icon$', '<img src="'.$rsc_url.'icons/feed-icon-16x16.gif" width="16" height="16" class="top" alt="" /> ', $this->disp_params['title']);99 $title = str_replace( '$icon$', '<img src="'.$rsc_url.'icons/feed-icon-16x16.gif" width="16" height="16" class="top" alt="" /> ', $this->disp_params['widget_title']);
113 // fp> TODO: support for different icon sizes and backgrounds (at least black and white; mid grey would be cool also)100 // fp> TODO: support for different icon sizes and backgrounds (at least black and white; mid grey would be cool also)
114101
115 return $title;102 return $title;
@@ -147,10 +134,10 @@
147134
148 echo $this->disp_params['item_start'];135 echo $this->disp_params['item_start'];
149 echo $Skin->name.': ';136 echo $Skin->name.': ';
150 echo '<a href="'.$Blog->get_item_feed_url( $Skin->folder ).'">'.T_('Posts').'</a>';137 echo '<a href="'.$Blog->get_item_feed_url( $Skin->folder ).'">'.$this->T_('Posts').'</a>';
151 if ( $Blog->allowcomments != 'never' )138 if ( $Blog->allowcomments != 'never' )
152 {139 {
153 echo ', <a href="'.$Blog->get_comment_feed_url( $Skin->folder ).'">'.T_('Comments').'</a>';140 echo ', <a href="'.$Blog->get_comment_feed_url( $Skin->folder ).'">'.$this->T_('Comments').'</a>';
154 }141 }
155142
156 echo $this->disp_params['item_end'];143 echo $this->disp_params['item_end'];
157144
=== added directory 'blogs/plugins/colls_list_owner_widget'
=== renamed file 'blogs/inc/widgets/widgets/_colls_list_owner.widget.php' => 'blogs/plugins/colls_list_owner_widget/_colls_list_owner.widget.php'
--- blogs/inc/widgets/widgets/_colls_list_owner.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/colls_list_owner_widget/_colls_list_owner.widget.php 2009-12-21 15:13:16 +0000
@@ -25,40 +25,29 @@
2525
26load_class( 'widgets/model/_widget.class.php' );26load_class( 'widgets/model/_widget.class.php' );
2727
28$wiCache = get_Cache('WidgetCache');
29$wiCache->load_widget( 'colls_list' );
30
28/**31/**
29 * ComponentWidget Class32 * ComponentWidget Class
30 *33 *
31 * A ComponentWidget is a displayable entity that can be placed into a Container on a web page.34 * A ComponentWidget is a displayable entity that can be placed into a Container on a web page.
32 *35 *
36 * @deprecated replaced with coll_list_Widget
37 *
33 * @package widgets38 * @package widgets
34 */39 */
35class colls_list_owner_Widget extends ComponentWidget40class colls_list_owner_Widget extends colls_list_Widget
36{41{
37 /**42 /**
38 * Constructor43 * Constructor
39 */44 */
40 function colls_list_owner_Widget( $db_row = NULL )45 function colls_list_owner_Widget( $db_row = NULL )
41 {46 {
47 $this->widget_name = $this->T_('Same owner\'s blog list');
48 $this->widget_title = '';
42 // Call parent constructor:49 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'colls_list_owner' );50 parent::ComponentWidget( $db_row, 'widget', 'colls_list_owner' );
44 }
45
46
47 /**
48 * Get name of widget
49 */
50 function get_name()
51 {
52 return T_('Same owner\'s blog list');
53 }
54
55
56 /**
57 * Get a very short desc. Used in the widget list.
58 */
59 function get_short_desc()
60 {
61 return format_to_output($this->disp_params['title']);
62 }51 }
6352
6453
@@ -67,7 +56,7 @@
67 */56 */
68 function get_desc()57 function get_desc()
69 {58 {
70 return T_('Display list of all blogs owned by the same user.');59 return $this->T_('Display list of all blogs owned by the same user.');
71 }60 }
7261
7362
@@ -79,34 +68,12 @@
79 */68 */
80 function get_param_definitions( $params )69 function get_param_definitions( $params )
81 {70 {
82 global $use_strict;71 $r = parent::get_param_definitions( $params );
83 $r = array_merge( array(
84 'title' => array(
85 'label' => T_( 'Title' ),
86 'size' => 40,
87 'note' => T_( 'This is the title to display, $icon$ will be replaced by the feed icon' ),
88 'defaultvalue' => T_('My blogs'),
89 ),
90 ), parent::get_param_definitions( $params ) );
9172
73 $r['coll_list_type']['type'] = 'text';
74 $r['coll_list_type']['defaultvalue'] = 'owner';
75 $r['coll_list_type']['no_edit'] = true;
92 return $r;76 return $r;
93 }77 }
94
95
96 /**
97 * Display the widget!
98 *
99 * @param array MUST contain at least the basic display params
100 */
101 function display( $params )
102 {
103 $this->init_display( $params );
104
105 $this->disp_coll_list( 'owner' );
106
107 return true;
108 }
109}78}
110
111
112?>79?>
113\ No newline at end of file80\ No newline at end of file
11481
=== added directory 'blogs/plugins/colls_list_public_widget'
=== renamed file 'blogs/inc/widgets/widgets/_colls_list_public.widget.php' => 'blogs/plugins/colls_list_public_widget/_colls_list_public.widget.php'
--- blogs/inc/widgets/widgets/_colls_list_public.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/colls_list_public_widget/_colls_list_public.widget.php 2009-12-21 15:13:16 +0000
@@ -25,40 +25,29 @@
2525
26load_class( 'widgets/model/_widget.class.php' );26load_class( 'widgets/model/_widget.class.php' );
2727
28$wiCache = get_Cache('WidgetCache');
29$wiCache->load_widget( 'colls_list' );
30
28/**31/**
29 * ComponentWidget Class32 * ComponentWidget Class
30 *33 *
31 * A ComponentWidget is a displayable entity that can be placed into a Container on a web page.34 * A ComponentWidget is a displayable entity that can be placed into a Container on a web page.
32 *35 *
36 * @deprecated replaced with coll_list_Widget
37 *
33 * @package widgets38 * @package widgets
34 */39 */
35class colls_list_public_Widget extends ComponentWidget40class colls_list_public_Widget extends colls_list_Widget
36{41{
37 /**42 /**
38 * Constructor43 * Constructor
39 */44 */
40 function colls_list_public_Widget( $db_row = NULL )45 function colls_list_public_Widget( $db_row = NULL )
41 {46 {
47 $this->widget_name = $this->T_('Public blog list');
48 $this->widget_title = '';
42 // Call parent constructor:49 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'colls_list_public' );50 parent::ComponentWidget( $db_row, 'widget', 'colls_list_public' );
44 }
45
46
47 /**
48 * Get name of widget
49 */
50 function get_name()
51 {
52 return T_('Public blog list');
53 }
54
55
56 /**
57 * Get a very short desc. Used in the widget list.
58 */
59 function get_short_desc()
60 {
61 return format_to_output($this->disp_params['title']);
62 }51 }
6352
6453
@@ -67,7 +56,7 @@
67 */56 */
68 function get_desc()57 function get_desc()
69 {58 {
70 return T_('Display list of all blogs marked as public.');59 return $this->T_('Display list of all blogs marked as public.');
71 }60 }
7261
7362
@@ -79,34 +68,12 @@
79 */68 */
80 function get_param_definitions( $params )69 function get_param_definitions( $params )
81 {70 {
82 global $use_strict;71 $r = parent::get_param_definitions( $params );
83 $r = array_merge( array(
84 'title' => array(
85 'label' => T_( 'Title' ),
86 'size' => 40,
87 'note' => T_( 'This is the title to display, $icon$ will be replaced by the feed icon' ),
88 'defaultvalue' => T_('All blogs'),
89 ),
90 ), parent::get_param_definitions( $params ) );
9172
73 $r['coll_list_type']['type'] = 'text';
74 $r['coll_list_type']['defaultvalue'] = 'public';
75 $r['coll_list_type']['no_edit'] = true;
92 return $r;76 return $r;
93 }77 }
94
95
96 /**
97 * Display the widget!
98 *
99 * @param array MUST contain at least the basic display params
100 */
101 function display( $params )
102 {
103 $this->init_display( $params );
104
105 $this->disp_coll_list( 'public' );
106
107 return true;
108 }
109}78}
110
111
112?>
113\ No newline at end of file79\ No newline at end of file
80?>
11481
=== added directory 'blogs/plugins/colls_list_widget'
=== added file 'blogs/plugins/colls_list_widget/_colls_list.widget.php'
--- blogs/plugins/colls_list_widget/_colls_list.widget.php 1970-01-01 00:00:00 +0000
+++ blogs/plugins/colls_list_widget/_colls_list.widget.php 2009-12-21 15:13:16 +0000
@@ -0,0 +1,171 @@
1<?php
2/**
3 * This file implements the Colls List Widget class.
4 *
5 * This file is part of the QuamPlures framework - {@link http://quamplures.net/}
6 *
7 * @copyright (c)2009 by QuamPlures - {@link http://quamplures.net/}
8 *
9 * {@internal License choice
10 * - If you have received this file as part of a package, please find the license.txt file in
11 * the same folder or the closest folder above for complete license terms.
12 * - If you have received this file individually
13 * then you must choose one of the following licenses before using the file:
14 * - GNU General Public License 2 (GPL) - http://www.opensource.org/licenses/gpl-license.php
15 * - Mozilla Public License 1.1 (MPL) - http://www.opensource.org/licenses/mozilla1.1.php
16 * }}
17 *
18 * {@internal Below is a list of authors who have contributed to design/coding of this file: }}
19 * @author yabs.
20 *
21 * @package widgets
22 */
23if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );
24
25// dependency
26load_class( 'widgets/model/_widget.class.php' );
27
28/**
29 * Colls List Class
30 *
31 * Displays a list of public or same owner blogs
32 *
33 * @package widgets
34 */
35class colls_list_Widget extends ComponentWidget
36{
37 /**
38 * Constructor
39 */
40 function colls_list_Widget( $db_row = NULL )
41 {
42 $this->widget_name = $this->T_('Blog List');
43 $this->widget_title = '';
44 // Call parent constructor:
45 parent::ComponentWidget( $db_row, 'widget', 'colls_list' );
46 }
47
48
49 /**
50 * Get a very short desc. Used in the widget list.
51 */
52 function get_short_desc()
53 {
54 return format_to_output($this->disp_params['widget_title']);
55 }
56
57
58 /**
59 * Get short description
60 */
61 function get_desc()
62 {
63 return $this->T_('Display chosen list of blogs.');
64 }
65
66
67 /**
68 * Get definitions for editable params
69 *
70 * @see Plugin::GetDefaultSettings()
71 * @param local params like 'for_editing' => true
72 */
73 function get_param_definitions( $params )
74 {
75 $r = array_merge( array(
76 'coll_list_type' => array(
77 'label' => $this->T_( 'List' ),
78 'type' => 'select',
79 'options' => array(
80 'owner' => $this->T_('Same owner'),
81 'public' => $this->T_('Public' ),
82 ),
83 'note' => $this->T_( 'Blogs to list' ),
84 'defaultvalue' => 'public',
85 ),
86 ), parent::get_param_definitions( $params ) );
87
88 return $r;
89 }
90
91
92 /**
93 * Display the widget!
94 *
95 * @param array MUST contain at least the basic display params
96 */
97 function display( $params )
98 {
99 $this->init_display( $params );
100
101 /**
102 * @var Blog
103 */
104 global $Blog, $baseurl;
105
106 echo $this->disp_params['block_start'];
107
108 $this->disp_title();
109
110 /**
111 * @var BlogCache
112 */
113 $BlogCache = & get_Cache( 'BlogCache' );
114
115 if( $this->disp_params['coll_list_type'] == 'owner' )
116 { // Load blogs of same owner
117 $blog_array = $BlogCache->load_owner_blogs( $Blog->owner_user_ID, 'ID' );
118 }
119 else
120 { // Load all public blogs
121 $blog_array = $BlogCache->load_public( 'ID' );
122 }
123
124 if( !empty( $blog_array ) )
125 {
126 echo $this->disp_params['list_start'];
127
128 foreach( $blog_array as $l_blog_ID )
129 { // Loop through all blogs:
130
131 $l_Blog = & $BlogCache->get_by_ID( $l_blog_ID );
132
133 if( $Blog && $l_blog_ID == $Blog->ID )
134 { // This is the blog being displayed on this page:
135 echo $this->disp_params['item_selected_start'];
136 $link_class = $this->disp_params['link_selected_class'];
137 }
138 else
139 {
140 echo $this->disp_params['item_start'];
141 $link_class = $this->disp_params['link_default_class'];;
142 }
143
144 echo '<a href="'.$l_Blog->gen_blogurl().'" class="'.$link_class.'" title="'
145 .$l_Blog->dget( 'name', 'htmlattr' ).'">';
146
147 if( $Blog && $l_blog_ID == $Blog->ID )
148 { // This is the blog being displayed on this page:
149 echo $this->disp_params['item_selected_text_start'];
150 printf( $this->disp_params['item_selected_text'], $l_Blog->dget( 'shortname', 'htmlbody' ) );
151 echo $this->disp_params['item_selected_text_end'];
152 echo '</a>';
153 echo $this->disp_params['item_selected_end'];
154 }
155 else
156 {
157 echo $this->disp_params['item_text_start'];
158 printf( $this->disp_params['item_text'], $l_Blog->dget( 'shortname', 'htmlbody' ) );
159 echo $this->disp_params['item_text_end'];
160 echo '</a>';
161 echo $this->disp_params['item_end'];
162 }
163 }
164
165 echo $this->disp_params['list_end'];
166 }
167
168 echo $this->disp_params['block_end'];
169 }
170}
171?>
0\ No newline at end of file172\ No newline at end of file
1173
=== added directory 'blogs/plugins/free_html_widget'
=== renamed file 'blogs/inc/widgets/widgets/_free_html.widget.php' => 'blogs/plugins/free_html_widget/_free_html.widget.php'
--- blogs/inc/widgets/widgets/_free_html.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/free_html_widget/_free_html.widget.php 2009-12-21 15:13:16 +0000
@@ -39,18 +39,10 @@
39 */39 */
40 function free_html_Widget( $db_row = NULL )40 function free_html_Widget( $db_row = NULL )
41 {41 {
42 $this->widget_name = $this->T_( 'Free HTML' );
43 $this->widget_title = '';
42 // Call parent constructor:44 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'free_html' );45 parent::ComponentWidget( $db_row, 'widget', 'free_html' );
44 }
45
46
47 /**
48 * Get name of widget
49 */
50 function get_name()
51 {
52 $title = T_( 'Free HTML' );
53 return $title;
54 }46 }
5547
5648
@@ -62,12 +54,12 @@
62 */54 */
63 function get_short_desc()55 function get_short_desc()
64 {56 {
65 if( empty( $this->disp_params['title'] ) )57 if( empty( $this->disp_params['widget_title'] ) )
66 {58 {
67 return strmaxlen( htmlspecialchars( $this->disp_params['content'] ), 60 );59 return strmaxlen( htmlspecialchars( $this->disp_params['content'] ), 60 );
68 }60 }
6961
70 return format_to_output( $this->disp_params['title'] );62 return format_to_output( $this->disp_params['widget_title'] );
71 }63 }
7264
7365
@@ -76,7 +68,7 @@
76 */68 */
77 function get_desc()69 function get_desc()
78 {70 {
79 return T_('Custom text/HTML of your choice.');71 return $this->T_('Custom text/HTML of your choice.');
80 }72 }
8173
8274
@@ -90,13 +82,9 @@
90 {82 {
91 // Demo data:83 // Demo data:
92 $r = array_merge( array(84 $r = array_merge( array(
93 'title' => array(
94 'label' => T_('Block title'),
95 'size' => 60,
96 ),
97 'content' => array(85 'content' => array(
98 'type' => 'html_textarea',86 'type' => 'html_textarea',
99 'label' => T_('Block content'),87 'label' => $this->T_('Block content'),
100 'rows' => 10,88 'rows' => 10,
101 ),89 ),
102 ), parent::get_param_definitions( $params ) );90 ), parent::get_param_definitions( $params ) );
@@ -120,7 +108,7 @@
120 // Collection common links:108 // Collection common links:
121 echo $this->disp_params['block_start'];109 echo $this->disp_params['block_start'];
122110
123 $this->disp_title( $this->disp_params['title'] );111 $this->disp_title();
124112
125 echo format_to_output( $this->disp_params['content'] );113 echo format_to_output( $this->disp_params['content'] );
126114
127115
=== added directory 'blogs/plugins/linkblog_widget'
=== renamed file 'blogs/inc/widgets/widgets/_linkblog.widget.php' => 'blogs/plugins/linkblog_widget/_linkblog.widget.php'
--- blogs/inc/widgets/widgets/_linkblog.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/linkblog_widget/_linkblog.widget.php 2009-12-21 15:13:16 +0000
@@ -23,7 +23,8 @@
23 */23 */
24if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );24if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );
2525
26load_class( 'widgets/widgets/_coll_item_list.widget.php' );26$wiCache = get_Cache('WidgetCache');
27$wiCache->load_widget( 'coll_item_list' );
2728
28/**29/**
29 * linkblog_widget class30 * linkblog_widget class
@@ -39,8 +40,10 @@
39 */40 */
40 function linkblog_Widget( $db_row = NULL )41 function linkblog_Widget( $db_row = NULL )
41 {42 {
43 $this->widget_name = $this->T_('Simple Linkblog Links list');
44 $this->widget_title = $this->T_('Linkblog');
42 // Call parent constructor:45 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'linkblog' );46 parent::ComponentWidget( $db_row, 'widget', 'linkblog' );
44 }47 }
4548
4649
@@ -55,7 +58,6 @@
55 // This is derived from coll_post_list_Widget, so we DO NOT ADD ANY param here!58 // This is derived from coll_post_list_Widget, so we DO NOT ADD ANY param here!
56 $r = parent::get_param_definitions( $params );59 $r = parent::get_param_definitions( $params );
57 // We only change the defaults and hide some params.60 // We only change the defaults and hide some params.
58 $r['title']['defaultvalue'] = T_('Linkblog');
59 $r['title_link']['no_edit'] = true;61 $r['title_link']['no_edit'] = true;
60 $r['follow_mainlist']['no_edit'] = true;62 $r['follow_mainlist']['no_edit'] = true;
61 $r['blog_ID']['defaultvalue'] = 0; // zero is a magic number that we'll use to try and use defaults used in previous versions of B2evo63 $r['blog_ID']['defaultvalue'] = 0; // zero is a magic number that we'll use to try and use defaults used in previous versions of B2evo
@@ -72,20 +74,11 @@
7274
7375
74 /**76 /**
75 * Get name of widget
76 */
77 function get_name()
78 {
79 return T_('Simple Linkblog Links list');
80 }
81
82
83 /**
84 * Get a very short desc. Used in the widget list.77 * Get a very short desc. Used in the widget list.
85 */78 */
86 function get_short_desc()79 function get_short_desc()
87 {80 {
88 return format_to_output($this->disp_params['title']);81 return format_to_output($this->disp_params['widget_title']);
89 }82 }
9083
9184
@@ -94,7 +87,7 @@
94 */87 */
95 function get_desc()88 function get_desc()
96 {89 {
97 return T_('Simplified Item list for listing links from another blog.');90 return $this->T_('Simplified Item list for listing links from another blog.');
98 }91 }
9992
10093
10194
=== added directory 'blogs/plugins/menu_link_widget'
=== renamed file 'blogs/inc/widgets/widgets/_menu_link.widget.php' => 'blogs/plugins/menu_link_widget/_menu_link.widget.php'
--- blogs/inc/widgets/widgets/_menu_link.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/menu_link_widget/_menu_link.widget.php 2009-12-21 15:13:16 +0000
@@ -25,15 +25,6 @@
2525
26load_class( 'widgets/model/_widget.class.php' );26load_class( 'widgets/model/_widget.class.php' );
2727
28global $menu_link_widget_link_types;
29$menu_link_widget_link_types = array(
30 'home' => T_('Blog home'),
31 'arcdir' => T_('Archive directory'),
32 'catdir' => T_('Category directory'),
33 'latestcomments' => T_('Latest comments'),
34 'ownercontact' => T_('Blog owner contact form'),
35 'login' => T_('Log in form')
36 );
3728
38/**29/**
39 * ComponentWidget Class30 * ComponentWidget Class
@@ -44,22 +35,26 @@
44 */35 */
45class menu_link_Widget extends ComponentWidget36class menu_link_Widget extends ComponentWidget
46{37{
38
39 var $menu_link_widget_link_types = array();
40
47 /**41 /**
48 * Constructor42 * Constructor
49 */43 */
50 function menu_link_Widget( $db_row = NULL )44 function menu_link_Widget( $db_row = NULL )
51 {45 {
46 $this->widget_name = $this->T_('Menu link');
47 $this->widget_title = '';
48 $this->menu_link_widget_link_types = array(
49 'home' => $this->T_('Blog home'),
50 'arcdir' => $this->T_('Archive directory'),
51 'catdir' => $this->T_('Category directory'),
52 'latestcomments' => $this->T_('Latest comments'),
53 'ownercontact' => $this->T_('Blog owner contact form'),
54 'login' => $this->T_('Log in form')
55 );
52 // Call parent constructor:56 // Call parent constructor:
53 parent::ComponentWidget( $db_row, 'core', 'menu_link' );57 parent::ComponentWidget( $db_row, 'widget', 'menu_link' );
54 }
55
56
57 /**
58 * Get name of widget
59 */
60 function get_name()
61 {
62 return T_('Menu link');
63 }58 }
6459
6560
@@ -68,14 +63,12 @@
68 */63 */
69 function get_short_desc()64 function get_short_desc()
70 {65 {
71 global $menu_link_widget_link_types;
72
73 $this->load_param_array();66 $this->load_param_array();
7467
75 if( !empty($this->param_array['link_type']) )68 if( !empty($this->param_array['link_type']) )
76 {69 {
77 // TRANS: %s is the link type, e. g. "Blog home" or "Log in form"70 // TRANS: %s is the link type, e. g. "Blog home" or "Log in form"
78 return sprintf( T_( '%s link' ), $menu_link_widget_link_types[$this->param_array['link_type']] );71 return sprintf( $this->T_( '%s link' ), $this->menu_link_widget_link_types[$this->param_array['link_type']] );
79 }72 }
80 else73 else
81 {74 {
@@ -90,7 +83,7 @@
90 */83 */
91 function get_desc()84 function get_desc()
92 {85 {
93 return T_('Display a configurable menu entry/link');86 return $this->T_('Display a configurable menu entry/link');
94 }87 }
9588
9689
@@ -102,14 +95,13 @@
102 */95 */
103 function get_param_definitions( $params )96 function get_param_definitions( $params )
104 {97 {
105 global $menu_link_widget_link_types;
10698
107 $r = array_merge( array(99 $r = array_merge( array(
108 'link_type' => array(100 'link_type' => array(
109 'label' => T_( 'Link Type' ),101 'label' => $this->T_( 'Link Type' ),
110 'note' => T_('What do you want to link to?'),102 'note' => $this->T_('What do you want to link to?'),
111 'type' => 'select',103 'type' => 'select',
112 'options' => $menu_link_widget_link_types,104 'options' => $this->menu_link_widget_link_types,
113 'defaultvalue' => 'home',105 'defaultvalue' => 'home',
114 ),106 ),
115 ), parent::get_param_definitions( $params ) );107 ), parent::get_param_definitions( $params ) );
@@ -133,43 +125,44 @@
133 {125 {
134 case 'arcdir':126 case 'arcdir':
135 $url = $Blog->get('arcdirurl');127 $url = $Blog->get('arcdirurl');
136 $text = T_('Archives');128 $text = $this->T_('Archives');
137 break;129 break;
138130
139 case 'catdir':131 case 'catdir':
140 $url = $Blog->get('catdirurl');132 $url = $Blog->get('catdirurl');
141 $text = T_('Categories');133 $text = $this->T_('Categories');
142 break;134 break;
143135
144 case 'latestcomments':136 case 'latestcomments':
145 $url = $Blog->get('lastcommentsurl');137 $url = $Blog->get('lastcommentsurl');
146 $text = T_('Latest comments');138 $text = $this->T_('Latest comments');
147 break;139 break;
148140
149 case 'ownercontact':141 case 'ownercontact':
150 $Blog->get_owner_User();142 $Blog->get_owner_User();
151 // fp> TODO: move this test into $Blog->get_contact_url( true ); 143 // fp> TODO: move this test into $Blog->get_contact_url( true );
152 if( ! $Blog->owner_User->allow_msgform )144 if( ! $Blog->owner_User->allow_msgform )
153 { // user does not allow contact form145 { // user does not allow contact form
154 return;146 return;
155 }147 }
156 $url = $Blog->get_contact_url( true );148 $url = $Blog->get_contact_url( true );
157 $text = T_('Contact');149 $text = $this->T_('Contact');
158 break;150 break;
159151
160 case 'login':152 case 'login':
161 if( is_logged_in() ) return false;153 if( is_logged_in() ) return false;
162 $url = get_login_url();154 $url = get_login_url();
163 $text = T_('Log in');155 $text = $this->T_('Log in');
164 break;156 break;
165157
166 case 'home':158 case 'home':
167 default:159 default:
168 $url = $Blog->get('url');160 $url = $Blog->get('url');
169 $text = T_('Home');161 $text = $this->T_('Home');
170 }162 }
171163
172 echo $this->disp_params['block_start'];164 echo $this->disp_params['block_start'];
165 $this->disp_title();
173 echo $this->disp_params['list_start'];166 echo $this->disp_params['list_start'];
174167
175 echo $this->disp_params['item_start'];168 echo $this->disp_params['item_start'];
@@ -182,6 +175,4 @@
182 return true;175 return true;
183 }176 }
184}177}
185
186
187?>178?>
188179
=== added directory 'blogs/plugins/user_tools_widget'
=== renamed file 'blogs/inc/widgets/widgets/_user_tools.widget.php' => 'blogs/plugins/user_tools_widget/_user_tools.widget.php'
--- blogs/inc/widgets/widgets/_user_tools.widget.php 2009-12-06 09:37:19 +0000
+++ blogs/plugins/user_tools_widget/_user_tools.widget.php 2009-12-21 15:13:16 +0000
@@ -39,8 +39,10 @@
39 */39 */
40 function user_tools_Widget( $db_row = NULL )40 function user_tools_Widget( $db_row = NULL )
41 {41 {
42 $this->widget_name = $this->T_('User Tools');
43 $this->widget_title = $this->T_('User tools');
42 // Call parent constructor:44 // Call parent constructor:
43 parent::ComponentWidget( $db_row, 'core', 'user_tools' );45 parent::ComponentWidget( $db_row, 'widget', 'user_tools' );
44 }46 }
4547
4648
@@ -53,74 +55,60 @@
53 function get_param_definitions( $params )55 function get_param_definitions( $params )
54 {56 {
55 $r = array_merge( array(57 $r = array_merge( array(
56 'title' => array(
57 'label' => T_('Block title'),
58 'note' => T_( 'Title to display in your skin.' ),
59 'size' => 40,
60 'defaultvalue' => T_('User tools'),
61 ),
62 'user_login_link' => array(58 'user_login_link' => array(
63 'label' => T_( 'Login link'),59 'label' => $this->T_( 'Login link'),
64 'size' => 40,60 'size' => 40,
65 'note' => T_( 'Link text to display' ),61 'note' => $this->T_( 'Link text to display' ),
66 'type' => 'text',62 'type' => 'text',
67 'defaultvalue' => T_( 'Login' ),63 'defaultvalue' => $this->T_( 'Login' ),
68 ),64 ),
69 'user_logout_link' => array(65 'user_logout_link' => array(
70 'label' => T_( 'Logout link'),66 'label' => $this->T_( 'Logout link'),
71 'size' => 40,67 'size' => 40,
72 'note' => T_( 'Link text to display' ),68 'note' => $this->T_( 'Link text to display' ),
73 'type' => 'text',69 'type' => 'text',
74 'defaultvalue' => T_( 'Logout' ),70 'defaultvalue' => $this->T_( 'Logout' ),
75 ),71 ),
76 'user_profile_link' => array(72 'user_profile_link' => array(
77 'label' => T_( 'Profile link'),73 'label' => $this->T_( 'Profile link'),
78 'size' => 40,74 'size' => 40,
79 'note' => T_( 'Link text to display' ),75 'note' => $this->T_( 'Link text to display' ),
80 'type' => 'text',76 'type' => 'text',
81 'defaultvalue' => T_( 'Profile' ),77 'defaultvalue' => $this->T_( 'Profile' ),
82 ),78 ),
83 'user_subs_link' => array(79 'user_subs_link' => array(
84 'label' => T_( 'Subscriptions link'),80 'label' => $this->T_( 'Subscriptions link'),
85 'size' => 40,81 'size' => 40,
86 'note' => T_( 'Link text to display' ),82 'note' => $this->T_( 'Link text to display' ),
87 'type' => 'text',83 'type' => 'text',
88 'defaultvalue' => T_( 'Subscriptions' ),84 'defaultvalue' => $this->T_( 'Subscriptions' ),
89 ),85 ),
90 'user_admin_link' => array(86 'user_admin_link' => array(
91 'label' => T_( 'Admin link'),87 'label' => $this->T_( 'Admin link'),
92 'size' => 40,88 'size' => 40,
93 'note' => T_( 'Link text to display' ),89 'note' => $this->T_( 'Link text to display' ),
94 'type' => 'text',90 'type' => 'text',
95 'defaultvalue' => T_( 'Admin' ),91 'defaultvalue' => $this->T_( 'Admin' ),
96 ),92 ),
97 'user_register_link' => array(93 'user_register_link' => array(
98 'label' => T_( 'Register link'),94 'label' => $this->T_( 'Register link'),
99 'size' => 40,95 'size' => 40,
100 'note' => T_( 'Link text to display' ),96 'note' => $this->T_( 'Link text to display' ),
101 'type' => 'text',97 'type' => 'text',
102 'defaultvalue' => T_( 'Register' ),98 'defaultvalue' => $this->T_( 'Register' ),
103 ),99 ),
104 ), parent::get_param_definitions( $params ) );100 ), parent::get_param_definitions( $params ) );
105101
106 return $r;102 return $r;
107 }103 }
108104
109 /**
110 * Get name of widget
111 */
112 function get_name()
113 {
114 return T_('User Tools');
115 }
116
117105
118 /**106 /**
119 * Get a very short desc. Used in the widget list.107 * Get a very short desc. Used in the widget list.
120 */108 */
121 function get_short_desc()109 function get_short_desc()
122 {110 {
123 return format_to_output($this->disp_params['title']);111 return format_to_output($this->disp_params['widget_title']);
124 }112 }
125113
126114
@@ -129,7 +117,7 @@
129 */117 */
130 function get_desc()118 function get_desc()
131 {119 {
132 return T_('Display user tools: Log in, Admin, Profile, Subscriptions, Log out');120 return $this->T_('Display user tools: Log in, Admin, Profile, Subscriptions, Log out');
133 }121 }
134122
135123
@@ -145,9 +133,7 @@
145 // User tools:133 // User tools:
146 echo $this->disp_params['block_start'];134 echo $this->disp_params['block_start'];
147135
148 echo $this->disp_params['block_title_start'];136 $this->disp_title();
149 echo $this->disp_params['title'];
150 echo $this->disp_params['block_title_end'];
151137
152 echo $this->disp_params['list_start'];138 echo $this->disp_params['list_start'];
153 user_login_link( $this->disp_params['item_start'], $this->disp_params['item_end'], $this->disp_params[ 'user_login_link' ] );139 user_login_link( $this->disp_params['item_start'], $this->disp_params['item_end'], $this->disp_params[ 'user_login_link' ] );
154140
=== modified file 'blogs/skins/asevo/style.css'
--- blogs/skins/asevo/style.css 2009-07-21 22:11:10 +0000
+++ blogs/skins/asevo/style.css 2009-12-21 15:13:19 +0000
@@ -151,7 +151,7 @@
151 margin: 2em 0 0 0;151 margin: 2em 0 0 0;
152 padding: 0;152 padding: 0;
153}153}
154div.evo_title_area div.widget_core_coll_tagline {154div.evo_title_area div.widget_widget_coll_tagline {
155 letter-spacing: 4px;155 letter-spacing: 4px;
156 margin: 1ex 0;156 margin: 1ex 0;
157}157}
@@ -284,12 +284,12 @@
284 * Special SideItems:284 * Special SideItems:
285 */285 */
286.widget_plugin_evo_Calr,286.widget_plugin_evo_Calr,
287.widget_core_coll_title,287.widget_widget_coll_title,
288.widget_core_coll_longdesc {288.widget_widget_coll_longdesc {
289 padding: 0;289 padding: 0;
290}290}
291.widget_core_coll_title,291.widget_widget_coll_title,
292.widget_core_coll_longdesc {292.widget_widget_coll_longdesc {
293 border-bottom: none;293 border-bottom: none;
294}294}
295295
296296
=== modified file 'blogs/skins/custom/style.css'
--- blogs/skins/custom/style.css 2009-07-21 22:11:10 +0000
+++ blogs/skins/custom/style.css 2009-12-21 15:13:19 +0000
@@ -164,7 +164,7 @@
164 color: #9ae;164 color: #9ae;
165}165}
166166
167.widget_core_coll_tagline {167.widget_widget_coll_tagline {
168 color: #fff;168 color: #fff;
169 letter-spacing: 4px;169 letter-spacing: 4px;
170 text-align: center;170 text-align: center;
@@ -303,13 +303,13 @@
303303
304/* Special SideItems: */304/* Special SideItems: */
305.widget_plugin_evo_Calr,305.widget_plugin_evo_Calr,
306.widget_core_coll_title,306.widget_widget_coll_title,
307.widget_core_coll_longdesc {307.widget_widget_coll_longdesc {
308 /* background-color: #fee; */308 /* background-color: #fee; */
309 padding: 0;309 padding: 0;
310 border-bottom: 0;310 border-bottom: 0;
311}311}
312.widget_core_coll_title a {312.widget_widget_coll_title a {
313 text-decoration: none;313 text-decoration: none;
314 color: #78a;314 color: #78a;
315}315}
316316
=== modified file 'blogs/skins/evocamp/style.css'
--- blogs/skins/evocamp/style.css 2009-07-21 22:11:10 +0000
+++ blogs/skins/evocamp/style.css 2009-12-21 15:13:19 +0000
@@ -355,7 +355,7 @@
355355
356/* -------------------[ Misc Tags and Classes ]------------------- */356/* -------------------[ Misc Tags and Classes ]------------------- */
357357
358#header .widget_core_coll_tagline {358#header .widget_widget_coll_tagline {
359color:#FAF7E8;359color:#FAF7E8;
360font-size: 12pt;360font-size: 12pt;
361padding: 0 100px;361padding: 0 100px;
@@ -599,6 +599,6 @@
599text-decoration: underline;599text-decoration: underline;
600}600}
601601
602div.widget_core_coll_title {602div.widget_widget_coll_title {
603 padding-top: 45px;603 padding-top: 45px;
604}604}
605605
=== modified file 'blogs/skins/evopress/style.css'
--- blogs/skins/evopress/style.css 2009-07-21 22:11:10 +0000
+++ blogs/skins/evopress/style.css 2009-12-21 15:13:19 +0000
@@ -483,7 +483,7 @@
483}483}
484484
485485
486div.widget_core_coll_title {486div.widget_widget_coll_title {
487 padding-top: 70px;487 padding-top: 70px;
488}488}
489489
490490
=== modified file 'blogs/skins/glossyblue/style.css'
--- blogs/skins/glossyblue/style.css 2009-07-21 22:11:10 +0000
+++ blogs/skins/glossyblue/style.css 2009-12-21 15:13:19 +0000
@@ -112,7 +112,7 @@
112 height: 60px;112 height: 60px;
113}113}
114114
115#header .widget_core_coll_tagline{115#header .widget_widget_coll_tagline{
116 position: absolute;116 position: absolute;
117 left: 110px;117 left: 110px;
118 bottom: 3px;118 bottom: 3px;
@@ -420,13 +420,13 @@
420}420}
421/*blogroll */421/*blogroll */
422ul.list-blogroll li,422ul.list-blogroll li,
423li.widget_core_linkblog ul li ul li{423li.widget_widget_linkblog ul li ul li{
424 background: url(img/mini-blogroll.gif) no-repeat !important;424 background: url(img/mini-blogroll.gif) no-repeat !important;
425 padding-left: 16px !important;425 padding-left: 16px !important;
426}426}
427/*category widget */427/*category widget */
428ul.list-cat li, li.widget_categories li,428ul.list-cat li, li.widget_categories li,
429li.widget_core_coll_category_list ul li{429li.widget_widget_coll_category_list ul li{
430 background: url(img/mini-category.gif) no-repeat !important;430 background: url(img/mini-category.gif) no-repeat !important;
431 padding-left: 20px !important;431 padding-left: 20px !important;
432}432}
@@ -439,7 +439,7 @@
439/*pages widget */439/*pages widget */
440ul.list-page li, li.widget_pages li,440ul.list-page li, li.widget_pages li,
441li.widget_recent_entries li,441li.widget_recent_entries li,
442li.widget_core_coll_page_list ul li{442li.widget_widget_coll_page_list ul li{
443 background: url(img/mini-page.gif) no-repeat !important;443 background: url(img/mini-page.gif) no-repeat !important;
444 padding-left: 20px !important;444 padding-left: 20px !important;
445}445}
@@ -528,25 +528,25 @@
528}528}
529529
530530
531#footer div.widget_core_coll_comment_list ul {531#footer div.widget_widget_coll_comment_list ul {
532 list-style: none;532 list-style: none;
533 padding: 0px;533 padding: 0px;
534}534}
535535
536#footer div.widget_core_coll_comment_list ul li {536#footer div.widget_widget_coll_comment_list ul li {
537 background: url(img/mini-footer-comments.gif) no-repeat;537 background: url(img/mini-footer-comments.gif) no-repeat;
538 padding: 0px 0px 10px 20px;538 padding: 0px 0px 10px 20px;
539}539}
540540
541#footer div.widget_core_coll_page_list ul,541#footer div.widget_widget_coll_page_list ul,
542#footer div.widget_core_coll_post_list ul {542#footer div.widget_widget_coll_post_list ul {
543 list-style: none;543 list-style: none;
544 padding: 0px;544 padding: 0px;
545 font-size: 92%;545 font-size: 92%;
546 line-height: 110%;546 line-height: 110%;
547}547}
548#footer div.widget_core_coll_page_list ul li,548#footer div.widget_widget_coll_page_list ul li,
549#footer div.widget_core_coll_post_list ul li {549#footer div.widget_widget_coll_post_list ul li {
550 background: url(img/mini-footer-post.gif) no-repeat;550 background: url(img/mini-footer-post.gif) no-repeat;
551 padding: 0px 0px 10px 20px;551 padding: 0px 0px 10px 20px;
552 font-size: 107%;552 font-size: 107%;
553553
=== modified file 'blogs/skins/miami_blue/style.css'
--- blogs/skins/miami_blue/style.css 2009-07-21 22:11:10 +0000
+++ blogs/skins/miami_blue/style.css 2009-12-21 15:13:19 +0000
@@ -117,7 +117,7 @@
117 color: #fff;117 color: #fff;
118 text-decoration: none;118 text-decoration: none;
119}119}
120div.pageHeader div.widget_core_coll_tagline {120div.pageHeader div.widget_widget_coll_tagline {
121 color: #fff;121 color: #fff;
122 letter-spacing: 2px;122 letter-spacing: 2px;
123 margin: 3px 0 0 13px;123 margin: 3px 0 0 13px;
124124
=== modified file 'blogs/skins/natural_pink/style.css'
--- blogs/skins/natural_pink/style.css 2009-07-21 22:11:10 +0000
+++ blogs/skins/natural_pink/style.css 2009-12-21 15:13:19 +0000
@@ -155,7 +155,7 @@
155div.pageHeader h1 a:hover {155div.pageHeader h1 a:hover {
156 color: #c0c;156 color: #c0c;
157}157}
158div.pageHeader div.widget_core_coll_tagline {158div.pageHeader div.widget_widget_coll_tagline {
159 letter-spacing: 4px;159 letter-spacing: 4px;
160 margin: 1ex 0;160 margin: 1ex 0;
161 font-size: 109%;161 font-size: 109%;
@@ -254,11 +254,11 @@
254254
255/* Special SideItems: */255/* Special SideItems: */
256.widget_plugin_evo_Calr,256.widget_plugin_evo_Calr,
257.widget_core_coll_title,257.widget_widget_coll_title,
258.widget_core_coll_longdesc {258.widget_widget_coll_longdesc {
259 padding: 0;259 padding: 0;
260}260}
261.widget_core_coll_title a {261.widget_widget_coll_title a {
262 color: #f09;262 color: #f09;
263}263}
264264
265265
=== modified file 'blogs/skins/nifty_corners/style.css'
--- blogs/skins/nifty_corners/style.css 2009-07-21 22:11:10 +0000
+++ blogs/skins/nifty_corners/style.css 2009-12-21 15:13:19 +0000
@@ -165,7 +165,7 @@
165div.pageHeader h1 a:hover {165div.pageHeader h1 a:hover {
166 color: #c0c;166 color: #c0c;
167}167}
168div.pageHeader div.widget_core_coll_tagline {168div.pageHeader div.widget_widget_coll_tagline {
169 letter-spacing: 4px;169 letter-spacing: 4px;
170 padding: 0 0 3px 0;170 padding: 0 0 3px 0;
171 font-size: 109%;171 font-size: 109%;
@@ -268,11 +268,11 @@
268268
269/* Special SideItems: */269/* Special SideItems: */
270.widget_plugin_evo_Calr,270.widget_plugin_evo_Calr,
271.widget_core_coll_title,271.widget_widget_coll_title,
272.widget_core_coll_longdesc {272.widget_widget_coll_longdesc {
273 padding: 0;273 padding: 0;
274}274}
275.widget_core_coll_title a {275.widget_widget_coll_title a {
276 color: #06a3c4;276 color: #06a3c4;
277}277}
278278
279279
=== modified file 'blogs/skins/pixelgreen/style.css'
--- blogs/skins/pixelgreen/style.css 2009-07-21 22:11:10 +0000
+++ blogs/skins/pixelgreen/style.css 2009-12-21 15:13:19 +0000
@@ -153,7 +153,7 @@
153 margin: 0 auto; padding: 0;153 margin: 0 auto; padding: 0;
154 position: relative;154 position: relative;
155}155}
156#header-content .widget_core_coll_title h1 a {156#header-content .widget_widget_coll_title h1 a {
157 font: bold 40px 'Trebuchet MS', Sans-serif;157 font: bold 40px 'Trebuchet MS', Sans-serif;
158 letter-spacing: -2px;158 letter-spacing: -2px;
159 color: #FFF;159 color: #FFF;
@@ -162,7 +162,7 @@
162162
163}163}
164164
165#header-content .widget_core_coll_tagline {165#header-content .widget_widget_coll_tagline {
166 font: bold 12px 'Trebuchet Ms', Sans-serif;166 font: bold 12px 'Trebuchet Ms', Sans-serif;
167 text-transform: none;167 text-transform: none;
168 color: #FFF;168 color: #FFF;
@@ -382,7 +382,7 @@
382.clear { clear: both; }382.clear { clear: both; }
383.gray { color: #BFBFBF; }383.gray { color: #BFBFBF; }
384384
385#sidebar .widget_core_coll_xml_feeds ul.sidemenu li a {385#sidebar .widget_widget_coll_xml_feeds ul.sidemenu li a {
386 display: inline;386 display: inline;
387}387}
388388
389389
=== modified file 'blogs/skins/terrafirma/style.css'
--- blogs/skins/terrafirma/style.css 2009-12-05 14:46:02 +0000
+++ blogs/skins/terrafirma/style.css 2009-12-21 15:13:19 +0000
@@ -152,7 +152,7 @@
152 text-decoration:none;152 text-decoration:none;
153 border:none;153 border:none;
154}154}
155.widget_core_coll_tagline155.widget_widget_coll_tagline
156{156{
157 font-size: 100%;157 font-size: 100%;
158 font-weight: normal;158 font-weight: normal;
159159
=== modified file 'blogs/skins/vastitude/style.css'
--- blogs/skins/vastitude/style.css 2009-12-05 14:46:02 +0000
+++ blogs/skins/vastitude/style.css 2009-12-21 15:13:19 +0000
@@ -9,17 +9,17 @@
9 font:86% Tahoma, "Lucida Sans", Arial, Verdana, Sans-Serif;9 font:86% Tahoma, "Lucida Sans", Arial, Verdana, Sans-Serif;
10 background:#4c4c4e;}10 background:#4c4c4e;}
1111
12li.widget_core_coll_title, li.widget_core_coll_longdesc, li.widget_plugin_evo_Calr, li.widget_core_coll_search_form, li.widget_core_linkblog, li.widget_core_coll_category_list, li.widget_core_coll_common_links, li.widget_core_coll_xml_feeds, li.widget_core_user_tools, li.widget_core_coll_xml_feeds ul li, li.prevnext {list-style:none;}12li.widget_widget_coll_title, li.widget_widget_coll_longdesc, li.widget_plugin_evo_Calr, li.widget_widget_coll_search_form, li.widget_widget_linkblog, li.widget_widget_coll_category_list, li.widget_widget_coll_common_links, li.widget_widget_coll_xml_feeds, li.widget_widget_user_tools, li.widget_widget_coll_xml_feeds ul li, li.prevnext {list-style:none;}
13table.prevnext_post {margin: 20px 0;}13table.prevnext_post {margin: 20px 0;}
14div#sidebar {margin-left:-10px;}14div#sidebar {margin-left:-10px;}
15div#sidebar h2 {font: 1.4em Tahoma, "Lucida Sans", Arial, Verdana, Sans-Serif;color:#4b3528;}15div#sidebar h2 {font: 1.4em Tahoma, "Lucida Sans", Arial, Verdana, Sans-Serif;color:#4b3528;}
16li.widget_core_coll_title h2 a {font-size: 1.1em; text-decoration:none;}16li.widget_widget_coll_title h2 a {font-size: 1.1em; text-decoration:none;}
17li.widget_core_coll_search_form h2 {}17li.widget_widget_coll_search_form h2 {}
1818
19li.widget_core_coll_xml_feeds h2 img {display:none;}19li.widget_widget_coll_xml_feeds h2 img {display:none;}
20li.widget_core_coll_xml_feeds {background:url(img/vast_rss.gif) top left no-repeat; margin-top:28px;padding-top:50px;}20li.widget_widget_coll_xml_feeds {background:url(img/vast_rss.gif) top left no-repeat; margin-top:28px;padding-top:50px;}
2121
22li.widget_core_coll_longdesc, li.widget_core_coll_search_form, li.widget_core_coll_category_list, li.widget_core_coll_common_links, li.widget_core_coll_xml_feeds {margin-bottom:20px;}22li.widget_widget_coll_longdesc, li.widget_widget_coll_search_form, li.widget_widget_coll_category_list, li.widget_widget_coll_common_links, li.widget_widget_coll_xml_feeds {margin-bottom:20px;}
2323
24/* COLOR MANAGEMENT */24/* COLOR MANAGEMENT */
2525

Subscribers

People subscribed via source and target branches