Changeset 2400
- Timestamp:
- 06/27/10 02:26:01 (13 years ago)
- Location:
- plugins/shareOn
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
plugins/shareOn/_admin.php
r2206 r2400 20 20 'plugin.php?p=shareOn','index.php?pf=shareOn/icon.png', 21 21 preg_match('/plugin.php\?p=shareOn(&.*)?$/',$_SERVER['REQUEST_URI']), 22 $core->auth->check('content',$core->blog->id)); 22 $core->auth->check('admin',$core->blog->id) 23 ); 23 24 ?> -
plugins/shareOn/_define.php
r2261 r2400 17 17 /* Description*/ "Add some buttons to your posts to share them", 18 18 /* Author */ "JC Denis", 19 /* Version */ '0. 4.3',20 /* Permissions */ ' content'19 /* Version */ '0.5', 20 /* Permissions */ 'admin' 21 21 ); 22 /* date */ #20100 52522 /* date */ #20100626 23 23 ?> -
plugins/shareOn/_install.php
r2217 r2400 18 18 if (version_compare($old_version,$new_version,'>=')) return; 19 19 20 try { 21 # Check DC version (dev on) 22 if (!version_compare(DC_VERSION,'2.1.6','>=')) 20 try 21 { 22 # Check DC version 23 if (version_compare(DC_VERSION,'2.2-alpha','<')) 23 24 { 24 throw new Exception('Plugin called shareOn requires Dotclear 2.1.6or higher.');25 throw new Exception('Plugin called rateIt requires Dotclear 2.2 or higher.'); 25 26 } 26 27 27 28 # Setting 28 29 $css = … … 31 32 "#sidebar .shareonwidget ul { list-style: none; margin: 4px; padding: 0; border: none; } \n". 32 33 "#sidebar .shareonwidget ul li { margin: 4px; padding: 0; border: none; } \n"; 33 34 $s = shareOnSettings($core);34 35 $s = $core->blog->settings->shareOn; 35 36 $s->put('shareOn_active',false,'boolean','Enable shareOn',false,true); 36 37 $s->put('shareOn_style',$css,'string','Special ShareOn css',false,true); … … 40 41 $s->put('shareOn_tag_place','after','string','Where to place ShareOn bar on tag page',false,true); 41 42 $s->put('shareOn_post_place','after','string','Where to place ShareOn bar on post page',false,true); 42 43 43 44 # Version 44 45 $core->setVersion('shareOn',$new_version); 45 46 46 47 return true; 47 48 } 48 catch (Exception $e) { 49 catch (Exception $e) 50 { 49 51 $core->error->add($e->getMessage()); 50 52 } -
plugins/shareOn/_prepend.php
r2261 r2400 12 12 13 13 if (!defined('DC_RC_PATH')) return; 14 if (version_compare(DC_VERSION,'2.2-alpha','<')){return;} 14 15 15 global $core; 16 17 function shareOnSettings($core,$ns='shareOn') { 18 if (!version_compare(DC_VERSION,'2.1.7','<=')) { 19 $core->blog->settings->addNamespace($ns); 20 return $core->blog->settings->{$ns}; 21 } else { 22 $core->blog->settings->setNamespace($ns); 23 return $core->blog->settings; 24 } 25 } 16 global $core, $__autoload; 17 $core->blog->settings->addNamespace('shareOn'); 26 18 27 19 if (!isset($core->shareOnButtons)) { $core->shareOnButtons = array(); } 20 21 $__autoload['shareOn'] = dirname(__FILE__).'/inc/class.shareon.php'; 22 23 $__autoload['flattrButton'] = dirname(__FILE__).'/inc/class.shareon.php'; 24 $__autoload['tweetmemeButton'] = dirname(__FILE__).'/inc/class.shareon.php'; 25 $__autoload['fbshareButton'] = dirname(__FILE__).'/inc/class.shareon.php'; 26 $__autoload['fbloveButton'] = dirname(__FILE__).'/inc/class.shareon.php'; 27 $__autoload['diggButton'] = dirname(__FILE__).'/inc/class.shareon.php'; 28 $__autoload['redditButton'] = dirname(__FILE__).'/inc/class.shareon.php'; 29 $__autoload['dzoneButton'] = dirname(__FILE__).'/inc/class.shareon.php'; 30 $__autoload['ybuzzButton'] = dirname(__FILE__).'/inc/class.shareon.php'; 31 $__autoload['gbuzzButton'] = dirname(__FILE__).'/inc/class.shareon.php'; 28 32 29 33 $core->shareOnButtons['flattr'] = 'flattrButton'; -
plugins/shareOn/_public.php
r2217 r2400 25 25 ); 26 26 27 if (! shareOnSettings($core)->shareOn_active)27 if (!$core->blog->settings->shareOn->shareOn_active) 28 28 { 29 29 $core->tpl->addValue('shareOnButton',array('tplShareOn','disable')); … … 38 38 public static function publicHeadContent($core) 39 39 { 40 $s = shareOnSettings($core)->shareOn_style;40 $s = $core->blog->settings->shareOn->shareOn_style; 41 41 if (!$s) return; 42 42 … … 60 60 protected static function publicEntryContent($core,$_ctx,$place) 61 61 { 62 $s = shareOnSettings($core);62 $s = $core->blog->settings->shareOn; 63 63 if (!$s->shareOn_active || empty($core->shareOnButtons)) return; 64 64 … … 115 115 return 116 116 "<?php \n". 117 "if ( shareOnSettings(\$core)->shareOn_active ".117 "if (\$core->blog->settings->shareOn->shareOn_active ". 118 118 " && !empty(\$core->shareOnButtons) ". 119 119 " && isset(\$core->shareOnButtons['".$attr['button']."']) ". -
plugins/shareOn/_widgets.php
r2217 r2400 20 20 { 21 21 global $core; 22 23 require_once dirname(__FILE__).'/inc/class.shareon.php'; 24 22 25 23 $w->create('shareon', 26 24 __('Share on'),array('shareOnWidget','publicShareOn') … … 35 33 { 36 34 $o = new $button($core); 37 35 38 36 $w->shareon->setting('use_'.$button_id, 39 37 sprintf(__('Add %s'),$o->name),1,'check' … … 41 39 } 42 40 } 43 41 44 42 public static function publicShareOn($w) 45 43 { 46 44 global $core, $_ctx; 47 45 48 46 # Disable 49 if (! shareOnSettings($core)->shareOn_active) return;47 if (!$core->blog->settings->shareOn->shareOn_active) return; 50 48 # No button 51 49 if (empty($core->shareOnButtons)) return; 52 50 # Not in post context 53 51 if ('post.html' != $_ctx->current_tpl) return; 54 55 require_once dirname(__FILE__).'/inc/class.shareon.php'; 56 52 57 53 $li = ''; 58 54 foreach($core->shareOnButtons as $button_id => $button) … … 68 64 if (!empty($res)) $li .= '<li>'.$res.'</li>'; 69 65 } 70 66 71 67 if (empty($li)) return; 72 68 73 69 return 74 70 '<div class="shareonwidget">'. -
plugins/shareOn/inc/class.shareon.php
r2261 r2400 17 17 public $core; 18 18 public $s; 19 19 20 20 public $id = 'undefined'; 21 21 public $name = 'undefined'; 22 22 public $home = ''; 23 23 public $base = ''; 24 24 25 25 public $_active = false; // enable button 26 26 public $_small = false; // button size … … 30 30 ); 31 31 public $encode = true; 32 32 33 33 public function __construct($core) 34 34 { 35 35 $this->core = $core; 36 $this->s = shareOnSettings($core);36 $this->s = $core->blog->settings->shareOn; 37 37 $this->loadSettings(); 38 38 } 39 39 40 40 public function loadSettings() 41 41 { … … 45 45 $this->_small = (boolean) $this->s->{$s}; 46 46 } 47 47 48 48 public function saveSettings($active,$small) 49 49 { … … 51 51 $this->s->put('shareOn_button'.$this->id.'_small',$small,'boolean'); 52 52 } 53 53 54 54 public function moreSettingsForm() 55 55 { 56 56 return ; 57 57 } 58 58 59 59 public function moreSettingsSave() 60 60 { 61 61 62 62 } 63 63 64 64 public function generateHTMLButton($url,$title) 65 65 { 66 66 if (!$this->_active) return ''; 67 67 68 68 if ($this->encode) 69 69 { … … 74 74 $width = $this->size[(integer) $this->_small]['width']; 75 75 $height = $this->size[(integer) $this->_small]['height']; 76 76 77 77 $base = str_replace( 78 78 array('%URL%','%TITLE%','%STYLE%','%WIDTH%','%HEIGHT%'), … … 83 83 return $this->completeHTMLButton($base); 84 84 } 85 85 86 86 public function completeHTMLButton($base) 87 87 { … … 102 102 public $_rt = ''; // retweet special name 103 103 public $encode = false; 104 105 public function __construct($core) 106 { 107 parent::__construct($core); 108 $this->_rt = (string) $this->s->shareOn_button_tweetmeme_rt; 109 } 110 104 105 public function __construct($core) 106 { 107 parent::__construct($core); 108 109 $rt = (string) $this->s->shareOn_button_tweetmeme_rt; 110 111 if ($rt) 112 { 113 $this->_rt = $rt; 114 } 115 } 116 111 117 public function moreSettingsForm() 112 118 { 113 119 return 114 '<p class="field"><label>'.115 __('Retweet name:'). 120 '<p><label>'. 121 __('Retweet name:').'<br />'. 116 122 form::field(array('tweetmeme_rt'),50,255,$this->_rt). 117 123 '</label></p>'. 118 124 '<p class="form-note">'.__("Change the RT source of the button from RT @tweetmeme to RT @yourname. Please use the format of 'yourname', not 'RT @yourname'.").'</p>'; 119 125 } 120 126 121 127 public function moreSettingsSave() 122 128 { 123 if (isset($_POST['tweetmeme_rt'])) { 129 if (isset($_POST['tweetmeme_rt'])) 130 { 124 131 $this->s->put('shareOn_button_tweetmeme_rt',$_POST['tweetmeme_rt'],'string'); 125 132 } 126 133 } 127 134 128 135 public function completeHTMLButton($base) 129 136 { … … 144 151 ); 145 152 public $encode = false; 146 153 147 154 public function __construct($core) 148 155 { … … 161 168 1 => array('style'=>'button_count','width'=>90,'height'=>22) 162 169 ); 163 170 164 171 public $_hover = ''; 165 172 public $_showfaces = 'false'; 166 173 public $_colorscheme = 'light'; 167 174 public $_action = 'like'; 168 169 public function __construct($core) 170 { 171 parent::__construct($core); 172 $this->_hover = (string) $this->s->shareOn_button_fblove_hover; 173 $this->_showfaces = (string) $this->s->shareOn_button_fblove_showfaces; 174 $this->_colorscheme = (string) $this->s->shareOn_button_fblove_colorscheme; 175 $this->_action = (string) $this->s->shareOn_button_fblove_action; 176 } 177 175 176 public function __construct($core) 177 { 178 parent::__construct($core); 179 180 $hover = (string) $this->s->shareOn_button_fblove_hover; 181 $showfaces = (string) $this->s->shareOn_button_fblove_showfaces; 182 $colorscheme = (string) $this->s->shareOn_button_fblove_colorscheme; 183 $action = (string) $this->s->shareOn_button_fblove_action; 184 185 if ($hover) 186 { 187 $this->_hover = $hover; 188 } 189 if ($showfaces) 190 { 191 $this->_showfaces = $showfaces; 192 } 193 if ($colorscheme) 194 { 195 $this->_colorscheme = $colorscheme; 196 } 197 if ($action) 198 { 199 $this->_action = $action; 200 } 201 } 202 178 203 public function moreSettingsForm() 179 204 { 180 205 return 181 '<p class="field"><label>'.182 __('Button title:'). 206 '<p><label>'. 207 __('Button title:').'<br />'. 183 208 form::field(array('fblove_hover'),50,7,$this->_hover). 184 209 '</label></p>'. 185 '<p class="field"><label>'.186 __('Show faces:'). 210 '<p><label>'. 211 __('Show faces:').'<br />'. 187 212 form::combo(array('fblove_showfaces'),array(__('yes')=>'true',__('no')=>'false'),$this->_showfaces). 188 213 '</label></p>'. 189 '<p class="field"><label>'.190 __('Colors scheme:'). 214 '<p><label>'. 215 __('Colors scheme:').'<br />'. 191 216 form::combo(array('fblove_colorscheme'),array(__('light')=>'light',__('dark')=>'dark'),$this->_colorscheme). 192 217 '</label></p>'. 193 '<p class="field"><label>'.194 __('Type:'). 218 '<p><label>'. 219 __('Type:').'<br />'. 195 220 form::combo(array('fblove_action'),array(__('I like')=>'like',__('I recommend')=>'recommend'),$this->_action). 196 221 '</label></p>'; 197 222 } 198 223 199 224 public function moreSettingsSave() 200 225 { 201 if (isset($_POST['fblove_hover'])) { 226 if (isset($_POST['fblove_hover'])) 227 { 202 228 $this->s->put('shareOn_button_fblove_hover',$_POST['fblove_hover'],'string'); 203 229 } 204 if (isset($_POST['fblove_showfaces'])) { 230 if (isset($_POST['fblove_showfaces'])) 231 { 205 232 $this->s->put('shareOn_button_fblove_showfaces',$_POST['fblove_showfaces'],'string'); 206 233 } 207 if (isset($_POST['fblove_colorscheme'])) { 234 if (isset($_POST['fblove_colorscheme'])) 235 { 208 236 $this->s->put('shareOn_button_fblove_colorscheme',$_POST['fblove_colorscheme'],'string'); 209 237 } 210 if (isset($_POST['fblove_action'])) { 238 if (isset($_POST['fblove_action'])) 239 { 211 240 $this->s->put('shareOn_button_fblove_action',$_POST['fblove_action'],'string'); 212 241 } 213 242 } 214 243 215 244 public function completeHTMLButton($base) 216 245 { … … 238 267 public $name = 'Digg'; 239 268 public $home = 'http://digg.com'; 240 public $base = '<script type="text/javascript">digg_url = \'%URL%\';digg_title = \'%TITLE%\';digg_skin = \'%STYLE%\';digg_bgcolor = \'%BGCOLOR%\';digg_window = \'new\';</script><script src="http://digg.com/tools/diggthis.js" type="text/javascript"></script>';269 public $base = '<script type="text/javascript">digg_url = "%URL%";digg_title = "%TITLE%";digg_skin = "%STYLE%";digg_bgcolor = "%BGCOLOR%";digg_window = "new";</script><script src="http://digg.com/tools/diggthis.js" type="text/javascript"></script>'; 241 270 public $size = array( 242 271 0 => array('style'=>'normal','width'=>52,'height'=>80), … … 244 273 ); 245 274 public $_bgcolor = '#FFFFFF'; // special background-color; 246 247 public function __construct($core) 248 { 249 parent::__construct($core); 250 $this->_bgcolor = (string) $this->s->shareOn_button_digg_bgcolor; 251 } 252 275 276 public function __construct($core) 277 { 278 parent::__construct($core); 279 280 $bgcolor = (string) $this->s->shareOn_button_digg_bgcolor; 281 282 if ($bgcolor) 283 { 284 $this->_bgcolor = $bgcolor; 285 } 286 } 287 253 288 public function moreSettingsForm() 254 289 { 255 290 return 256 '<p class="field"><label>'.257 __('Background color:'). 291 '<p><label>'. 292 __('Background color:').'<br />'. 258 293 form::field(array('digg_bgcolor'),50,7,$this->_bgcolor). 259 294 '</label></p>'. 260 295 '<p class="form-note">'.__("Use color code like '#CC00FF'.").'</p>'; 261 296 } 262 297 263 298 public function moreSettingsSave() 264 299 { 265 if (isset($_POST['digg_bgcolor'])) { 300 if (isset($_POST['digg_bgcolor'])) 301 { 266 302 $this->s->put('shareOn_button_digg_bgcolor',$_POST['digg_bgcolor'],'string'); 267 303 } 268 304 } 269 305 270 306 public function completeHTMLButton($base) 271 307 { … … 284 320 1 => array('style'=>'1','width'=>120,'height'=>22) 285 321 ); 286 322 287 323 public function __construct($core) 288 324 { … … 301 337 1 => array('style'=>'2','width'=>120,'height'=>22) 302 338 ); 303 339 304 340 public function __construct($core) 305 341 { … … 318 354 1 => array('style'=>'small-votes','width'=>159,'height'=>22) 319 355 ); 320 356 321 357 public function __construct($core) 322 358 { … … 330 366 public $name = 'Flattr'; 331 367 public $home = 'http://flattr.com'; 332 public $base = "<script type=\"text/javascript\">var flattr_uid = '%UID%'; var flattr_cat = 'text'; var flattr_tle = '%TITLE%'; var flattr_dsc = '%DESC%'; var flattr_btn = '%STYLE%'; var flattr_tag = '%TAG%'; var flattr_url = '%URL%'; var flattr_lng = '%LANG%'; </script><script src=\"http://api.flattr.com/button/load.js\" type=\"text/javascript\"></script>";368 public $base = '<script type="text/javascript">var flattr_uid = "%UID%"; var flattr_cat = "text"; var flattr_tle = "%TITLE%"; var flattr_dsc = "%DESC%"; var flattr_btn = "%STYLE%"; var flattr_tag = "%TAG%"; var flattr_url = "%URL%"; var flattr_lng = "%LANG%"; </script><script src="http://api.flattr.com/button/load.js" type="text/javascript"></script>'; 333 369 public $size = array( 334 370 0 => array('style'=>'','width'=>53,'height'=>69), … … 341 377 { 342 378 parent::__construct($core); 379 343 380 $this->_uid = (string) $this->s->shareOn_button_flattr_uid; 344 381 } 345 382 346 383 public function moreSettingsForm() 347 384 { 348 385 return 349 '<p class="field"><label>'.350 __('Your Flattr UID:'). 386 '<p><label>'. 387 __('Your Flattr UID:').'<br />'. 351 388 form::field(array('flattr_uid'),50,7,$this->_uid). 352 389 '</label></p>'; 353 390 } 354 391 355 392 public function moreSettingsSave() 356 393 { 357 if (isset($_POST['flattr_uid'])) { 394 if (isset($_POST['flattr_uid'])) 395 { 358 396 $this->s->put('shareOn_button_flattr_uid',$_POST['flattr_uid'],'string'); 359 397 } 360 398 } 361 399 362 400 public function completeHTMLButton($base) 363 401 { 364 402 global $core, $_ctx; 365 403 404 if (!$this->_uid) { return; } 405 366 406 $lang = 'en_GB'; 367 if ($_ctx->posts->post_lang != '') { 407 if ($_ctx->posts->post_lang != '') 408 { 368 409 $lang = $_ctx->posts->post_lang; 369 410 $lang = self::flattrLangCode($lang); … … 371 412 372 413 $desc = ''; 373 if ($_ctx->posts->post_content != '') { 374 if ($_ctx->posts->post_excerpt != '') { 414 if ($_ctx->posts->post_content != '') 415 { 416 if ($_ctx->posts->post_excerpt != '') 417 { 375 418 $desc = self::flattrClean($_ctx->posts->post_excerpt); 376 419 } … … 378 421 379 422 $desc = text::cutString($desc,180); 423 $desc = html::escapeJS($desc); 380 424 } 381 425 382 426 $tag = ''; 383 if ($_ctx->exists('posts')) { 427 if ($_ctx->exists('posts')) 428 { 384 429 $obj = new dcMeta($core); 385 430 $metas = $obj->getMeta('tag',null,null,$_ctx->posts->post_id); 386 431 $tags = array(); 387 while ($metas->fetch()) { 432 while ($metas->fetch()) 433 { 388 434 $tags[] = $metas->meta_id; 389 435 } 390 436 $tag = implode(', ',$tags); 391 437 $tag = self::flattrClean($tag); 438 $tag = html::escapeJS($tag); 392 439 } 393 440 … … 398 445 ); 399 446 } 400 447 401 448 protected static function flattrClean($str) 402 449 { … … 463 510 'vi' => 'vi_VN' 464 511 ); 465 if (!isset($langs[$code])) { 512 if (!isset($langs[$code])) 513 { 466 514 return 'en_GB'; 467 515 } 468 else { 516 else 517 { 469 518 return $langs[$code]; 470 519 } … … 484 533 public $encode = false; 485 534 public $_showdesc = false; 486 487 public function __construct($core) 488 { 489 parent::__construct($core); 490 $this->_showdesc = ( string) $this->s->shareOn_button_gbuzz_showdesc;491 } 492 535 536 public function __construct($core) 537 { 538 parent::__construct($core); 539 $this->_showdesc = (boolean) $this->s->shareOn_button_gbuzz_showdesc; 540 } 541 493 542 public function moreSettingsForm() 494 543 { 495 544 return 496 '<p class="field"><label>'. 545 '<p><label class="classic">'. 546 form::checkbox(array('gbuzz_showdesc'),1,$this->_showdesc). 497 547 __('Add post description to message'). 498 form::checkbox(array('gbuzz_showdesc'),1,$this->_showdesc).499 548 '</label></p>'; 500 549 } 501 550 502 551 public function moreSettingsSave() 503 552 { 504 if (isset($_POST['gbuzz_showdesc'])) { 553 if (isset($_POST['gbuzz_showdesc'])) 554 { 505 555 $this->s->put('shareOn_button_gbuzz_showdesc',$_POST['gbuzz_showdesc'],'boolean'); 506 556 } 507 557 } 508 558 509 559 public function completeHTMLButton($base) 510 560 { 511 if (!$this->_showdesc) { 561 if (!$this->_showdesc) 562 { 512 563 return str_replace('%DESC%','',$base); 513 564 } 514 565 515 566 global $core, $_ctx; 516 567 517 568 $desc = ''; 518 if ($_ctx->posts->post_excerpt != '') { 569 if ($_ctx->posts->post_excerpt != '') 570 { 519 571 $desc = self::gbuzzClean($_ctx->posts->post_excerpt); 520 572 } 521 elseif ($_ctx->posts->post_content != '') { 573 elseif ($_ctx->posts->post_content != '') 574 { 522 575 $desc .= self::gbuzzClean($_ctx->posts->post_content,500); 523 576 } 524 577 525 578 return str_replace('%DESC%',' - '.$desc,$base); 526 579 } 527 580 528 581 protected static function gbuzzClean($str,$len=null) 529 582 { … … 537 590 ))))); 538 591 539 if ($len) { 592 if ($len) 593 { 540 594 return text::cutString($str,$len); 541 595 } 542 else { 596 else 597 { 543 598 return $str; 544 599 } -
plugins/shareOn/index.php
r2217 r2400 13 13 if (!defined('DC_CONTEXT_ADMIN')){return;} 14 14 15 if (!isset($core->shareOnButtons)) $core->shareOnButtons = array(); 16 17 require_once dirname(__FILE__).'/inc/class.shareon.php'; 18 15 dcPage::check('admin'); 19 16 20 17 # Vars 21 $s = shareOnSettings($core); 22 18 $s = $core->blog->settings->shareOn; 19 20 # Settings 23 21 $_active = (boolean) $s->shareOn_active; 24 22 $_style = (string) $s->shareOn_style; … … 29 27 $_post_place = (string) $s->shareOn_post_place; 30 28 29 # Combos 31 30 $combo_place = array( 32 31 __('hide') => '', … … 45 44 'savebuttons' => __('Buttons successfully updated') 46 45 ); 47 if (isset($msg_list[$msg])) { 46 if (isset($msg_list[$msg])) 47 { 48 48 $msg = sprintf('<p class="message">%s</p>',$msg_list[$msg]); 49 49 } … … 65 65 $_tag_place = isset($_POST['_tag_place']) ? $_POST['_tag_place'] : ''; 66 66 $_post_place = isset($_POST['_post_place']) ? $_POST['_post_place'] : ''; 67 68 $s->put('shareOn_active',$_active );69 $s->put('shareOn_style',$_style );70 $s->put('shareOn_title',$_title );71 $s->put('shareOn_home_place',$_home_place );72 $s->put('shareOn_cat_place',$_cat_place );73 $s->put('shareOn_tag_place',$_tag_place );74 $s->put('shareOn_post_place',$_post_place );75 67 68 $s->put('shareOn_active',$_active,'boolean'); 69 $s->put('shareOn_style',$_style,'string'); 70 $s->put('shareOn_title',$_title,'string'); 71 $s->put('shareOn_home_place',$_home_place,'string'); 72 $s->put('shareOn_cat_place',$_cat_place,'string'); 73 $s->put('shareOn_tag_place',$_tag_place,'string'); 74 $s->put('shareOn_post_place',$_post_place,'string'); 75 76 76 $core->blog->triggerBlog(); 77 77 http::redirect($p_url.'&part=setting&msg='.$action.'§ion='.$section); … … 125 125 '</h2>'.$msg.' 126 126 <form method="post" action="'.$p_url.'" id="buttons-form">'; 127 127 128 128 foreach($core->shareOnButtons as $button_id => $button) 129 129 { … … 136 136 } 137 137 echo 138 '<p class="field"><label>'. 139 __('Enable this button'). 138 '<p><label class="classic">'. 140 139 form::checkbox(array($button_id.'_active'),'1',$o->_active). 140 __('Enable this button on post content'). 141 141 '</label></p>'. 142 '<p class="field"><label>'. 143 __('Use small button'). 142 '<p><label class="classic">'. 144 143 form::checkbox(array($button_id.'_small'),'1',$o->_small). 144 __('Use small button on post content'). 145 145 '</label></p>'. 146 146 $o->moreSettingsForm(). … … 167 167 '</h2>'.$msg.' 168 168 <form method="post" action="'.$p_url.'" id="setting-form"> 169 169 170 170 <fieldset id="plugin"><legend>'. __('Plugin activation').'</legend> 171 171 <p><label class="classic">'. … … 174 174 </label></p> 175 175 </fieldset> 176 176 177 177 <fieldset id="sstyle"><legend>'.__('Style').'</legend> 178 178 <p>'.__('You can add here special cascading style sheet. Share on bar has class "shareonentry" and widget has class "shareonwidget".').'</p> … … 181 181 </p> 182 182 </fieldset> 183 183 184 184 <fieldset id="scontent"><legend>'.__('Content').'</legend> 185 <p>'.__('To use this option you must have behavior "publicEntryBeforeContent", "publicEntryAfterContent" and "publicHeadContent" in your theme.').'</p> 185 <p>'. 186 __('To use this option you must have behavior "publicEntryBeforeContent", "publicEntryAfterContent" and "publicHeadContent" in your theme.').'<br />'. 187 __('A widget is also available to add buttons to your blog.').'</p> 186 188 <p><label class="classic">'. 187 189 __('Title:').'<br />'. … … 206 208 </label></p> 207 209 </fieldset> 208 210 209 211 <p> 210 212 <input type="submit" name="settings" value="'.__('save').'" />'. -
plugins/shareOn/locales/fr/main.lang.php
r2217 r2400 1 1 <?php 2 // Language: français3 // Module: shareOn - 0. 44 // Date: 2010-0 5-05 16:05:575 // Translated with dcTranslater - 1. 32 // Language: Français 3 // Module: shareOn - 0.5 4 // Date: 2010-06-27 00:24:33 5 // Translated with dcTranslater - 1.4.1 6 6 7 #_widgets.php:32 7 #_admin.php:19 8 #_widgets.php:24 9 #_widgets.php:27 10 #index.php:109 11 #index.php:124 12 #index.php:165 13 $GLOBALS['__l10n']['Share on'] = 'Partager sur'; 14 15 #_widgets.php:30 8 16 $GLOBALS['__l10n']['Use small buttons'] = 'Utiliser les petits boutons'; 9 17 10 #_widgets.php:3 918 #_widgets.php:37 11 19 $GLOBALS['__l10n']['Add %s'] = 'Ajouter %s'; 12 20 13 #inc/class.shareon.php:1 1521 #inc/class.shareon.php:121 14 22 $GLOBALS['__l10n']['Retweet name:'] = 'Nom de retweet :'; 15 23 16 #inc/class.shareon.php:1 1824 #inc/class.shareon.php:124 17 25 $GLOBALS['__l10n']['Change the RT source of the button from RT @tweetmeme to RT @yourname. Please use the format of \'yourname\', not \'RT @yourname\'.'] = 'Changer la source du RT de RT @tweetmeme vers RT @votrenom. Utiliser le format \'votrenom\', pas \'RT @votrenom\'.'; 18 26 19 #inc/class.shareon.php: 18127 #inc/class.shareon.php:207 20 28 $GLOBALS['__l10n']['Button title:'] = 'Titre du bouton :'; 21 29 22 #inc/class.shareon.php: 18530 #inc/class.shareon.php:211 23 31 $GLOBALS['__l10n']['Show faces:'] = 'Afficher les têtes :'; 24 32 25 #inc/class.shareon.php: 18933 #inc/class.shareon.php:215 26 34 $GLOBALS['__l10n']['Colors scheme:'] = 'Schema de couleurs :'; 27 35 28 #inc/class.shareon.php: 19036 #inc/class.shareon.php:216 29 37 $GLOBALS['__l10n']['light'] = 'clair'; 30 38 31 #inc/class.shareon.php: 19039 #inc/class.shareon.php:216 32 40 $GLOBALS['__l10n']['dark'] = 'foncé'; 33 41 34 #inc/class.shareon.php: 19442 #inc/class.shareon.php:220 35 43 $GLOBALS['__l10n']['I like'] = 'J\'aime'; 36 44 37 #inc/class.shareon.php: 19445 #inc/class.shareon.php:220 38 46 $GLOBALS['__l10n']['I recommend'] = 'Je recommande'; 39 47 40 #inc/class.shareon.php:2 5948 #inc/class.shareon.php:295 41 49 $GLOBALS['__l10n']['Use color code like \'#CC00FF\'.'] = 'Utiliser le code de couleur comme \'#CC00FF\'.'; 42 50 43 #inc/class.shareon.php:3 4951 #inc/class.shareon.php:387 44 52 $GLOBALS['__l10n']['Your Flattr UID:'] = 'Votre UID Flattr :'; 45 53 46 #index.php:33 54 #inc/class.shareon.php:547 55 $GLOBALS['__l10n']['Add post description to message'] = 'Ajouter la description du billet au message'; 56 57 #index.php:32 47 58 $GLOBALS['__l10n']['before content'] = 'Avant le contenu'; 48 59 49 #index.php:3 460 #index.php:33 50 61 $GLOBALS['__l10n']['after content'] = 'Après le contenu'; 51 62 52 #index.php:4 463 #index.php:43 53 64 $GLOBALS['__l10n']['Configuration successfully saved'] = 'Configuration sauvegardée avec succès'; 54 65 55 #index.php:4 566 #index.php:44 56 67 $GLOBALS['__l10n']['Buttons successfully updated'] = 'Boutons mis à jour avec succès'; 57 68 … … 65 76 $GLOBALS['__l10n']['Learn more about %s.'] = 'En savoir plus à propos de %s.'; 66 77 67 #index.php:1 3968 $GLOBALS['__l10n']['Enable this button '] = 'Activer ce bouton';78 #index.php:140 79 $GLOBALS['__l10n']['Enable this button on post content'] = 'Activer ce bouton sur le contenu des billets'; 69 80 70 #index.php:14 371 $GLOBALS['__l10n']['Use small button '] = 'Utiliser le petit bouton';81 #index.php:144 82 $GLOBALS['__l10n']['Use small button on post content'] = 'Utiliser le petit bouton sur le contenu des billets'; 72 83 73 84 #index.php:166 74 #index.php:22 385 #index.php:225 75 86 $GLOBALS['__l10n']['Settings'] = 'Paramètres'; 76 87 … … 93 104 $GLOBALS['__l10n']['Content'] = 'Contenu'; 94 105 95 #index.php:18 5106 #index.php:186 96 107 $GLOBALS['__l10n']['To use this option you must have behavior "publicEntryBeforeContent", "publicEntryAfterContent" and "publicHeadContent" in your theme.'] = 'Pour utiliser cette option vous devez avoir les behavior "publicEntryBeforeContent", "publicEntryAfterContent" et "publicHeadContent" dans votre thème.'; 97 108 98 #index.php:190 109 #index.php:187 110 $GLOBALS['__l10n']['A widget is also available to add buttons to your blog.'] = 'Un widget est également disponible pour ajouter les boutons sur votre blog.'; 111 112 #index.php:192 99 113 $GLOBALS['__l10n']['Title of group of buttons could be empty.'] = 'Le titre du groupe de boutons peut être vide.'; 100 114 101 #index.php:19 2115 #index.php:194 102 116 $GLOBALS['__l10n']['Show buttons on each posts on home page:'] = 'Afficher les boutons sur chaques billets de la page d\'accueil :'; 103 117 104 #index.php:19 6118 #index.php:198 105 119 $GLOBALS['__l10n']['Show buttons on each posts on categorie page:'] = 'Afficher les boutons sur chaques billets de la page de catégorie :'; 106 120 107 #index.php:20 0121 #index.php:202 108 122 $GLOBALS['__l10n']['Show buttons on each posts on tag page:'] = 'Afficher les boutons sur chaques pages de tag :'; 109 123 110 #index.php:20 4124 #index.php:206 111 125 $GLOBALS['__l10n']['Show buttons on a post page:'] = 'Afficher les boutons sur la page d\'un billet :'; 112 126 -
plugins/shareOn/locales/fr/main.po
r2217 r2400 1 # Language: français2 # Module: shareOn - 0. 43 # Date: 2010-0 5-05 16:05:574 # Translated with translater 1. 31 # Language: Français 2 # Module: shareOn - 0.5 3 # Date: 2010-06-27 00:24:33 4 # Translated with translater 1.4.1 5 5 6 6 msgid "" 7 7 msgstr "" 8 8 "Content-Type: text/plain; charset=UTF-8\n" 9 "Project-Id-Version: shareOn 0. 4\n"9 "Project-Id-Version: shareOn 0.5\n" 10 10 "POT-Creation-Date: \n" 11 "PO-Revision-Date: 2010-0 5-05T16:05:57+00:00\n"11 "PO-Revision-Date: 2010-06-27T00:24:33+00:00\n" 12 12 "Last-Translator: JC Denis\n" 13 13 "Language-Team: \n" … … 15 15 "Content-Transfer-Encoding: 8bit\n" 16 16 17 #: _widgets.php:32 17 #: _admin.php:19 18 #: _widgets.php:24 19 #: _widgets.php:27 20 #: index.php:109 21 #: index.php:124 22 #: index.php:165 23 msgid "Share on" 24 msgstr "Partager sur" 25 26 #: _widgets.php:30 18 27 msgid "Use small buttons" 19 28 msgstr "Utiliser les petits boutons" 20 29 21 #: _widgets.php:3 930 #: _widgets.php:37 22 31 msgid "Add %s" 23 32 msgstr "Ajouter %s" 24 33 25 #: inc/class.shareon.php:1 1534 #: inc/class.shareon.php:121 26 35 msgid "Retweet name:" 27 36 msgstr "Nom de retweet :" 28 37 29 #: inc/class.shareon.php:1 1838 #: inc/class.shareon.php:124 30 39 msgid "Change the RT source of the button from RT @tweetmeme to RT @yourname. Please use the format of 'yourname', not 'RT @yourname'." 31 40 msgstr "Changer la source du RT de RT @tweetmeme vers RT @votrenom. Utiliser le format 'votrenom', pas 'RT @votrenom'." 32 41 33 #: inc/class.shareon.php: 18142 #: inc/class.shareon.php:207 34 43 msgid "Button title:" 35 44 msgstr "Titre du bouton :" 36 45 37 #: inc/class.shareon.php: 18546 #: inc/class.shareon.php:211 38 47 msgid "Show faces:" 39 48 msgstr "Afficher les têtes :" 40 49 41 #: inc/class.shareon.php: 18950 #: inc/class.shareon.php:215 42 51 msgid "Colors scheme:" 43 52 msgstr "Schema de couleurs :" 44 53 45 #: inc/class.shareon.php: 19054 #: inc/class.shareon.php:216 46 55 msgid "light" 47 56 msgstr "clair" 48 57 49 #: inc/class.shareon.php: 19058 #: inc/class.shareon.php:216 50 59 msgid "dark" 51 60 msgstr "foncé" 52 61 53 #: inc/class.shareon.php: 19462 #: inc/class.shareon.php:220 54 63 msgid "I like" 55 64 msgstr "J'aime" 56 65 57 #: inc/class.shareon.php: 19466 #: inc/class.shareon.php:220 58 67 msgid "I recommend" 59 68 msgstr "Je recommande" 60 69 61 #: inc/class.shareon.php:2 5970 #: inc/class.shareon.php:295 62 71 msgid "Use color code like '#CC00FF'." 63 72 msgstr "Utiliser le code de couleur comme '#CC00FF'." 64 73 65 #: inc/class.shareon.php:3 4974 #: inc/class.shareon.php:387 66 75 msgid "Your Flattr UID:" 67 76 msgstr "Votre UID Flattr :" 68 77 69 #: index.php:33 78 #: inc/class.shareon.php:547 79 msgid "Add post description to message" 80 msgstr "Ajouter la description du billet au message" 81 82 #: index.php:32 70 83 msgid "before content" 71 84 msgstr "Avant le contenu" 72 85 73 #: index.php:3 486 #: index.php:33 74 87 msgid "after content" 75 88 msgstr "Après le contenu" 76 89 77 #: index.php:4 490 #: index.php:43 78 91 msgid "Configuration successfully saved" 79 92 msgstr "Configuration sauvegardée avec succès" 80 93 81 #: index.php:4 594 #: index.php:44 82 95 msgid "Buttons successfully updated" 83 96 msgstr "Boutons mis à jour avec succès" … … 95 108 msgstr "En savoir plus à propos de %s." 96 109 97 #: index.php:1 3998 msgid "Enable this button "99 msgstr "Activer ce bouton "110 #: index.php:140 111 msgid "Enable this button on post content" 112 msgstr "Activer ce bouton sur le contenu des billets" 100 113 101 #: index.php:14 3102 msgid "Use small button "103 msgstr "Utiliser le petit bouton "114 #: index.php:144 115 msgid "Use small button on post content" 116 msgstr "Utiliser le petit bouton sur le contenu des billets" 104 117 105 118 #: index.php:166 106 #: index.php:22 3119 #: index.php:225 107 120 msgid "Settings" 108 121 msgstr "Paramètres" … … 132 145 msgstr "Contenu" 133 146 134 #: index.php:18 5147 #: index.php:186 135 148 msgid "To use this option you must have behavior \"publicEntryBeforeContent\", \"publicEntryAfterContent\" and \"publicHeadContent\" in your theme." 136 149 msgstr "Pour utiliser cette option vous devez avoir les behavior \"publicEntryBeforeContent\", \"publicEntryAfterContent\" et \"publicHeadContent\" dans votre thème." 137 150 138 #: index.php:190 151 #: index.php:187 152 msgid "A widget is also available to add buttons to your blog." 153 msgstr "Un widget est également disponible pour ajouter les boutons sur votre blog." 154 155 #: index.php:192 139 156 msgid "Title of group of buttons could be empty." 140 157 msgstr "Le titre du groupe de boutons peut être vide." 141 158 142 #: index.php:19 2159 #: index.php:194 143 160 msgid "Show buttons on each posts on home page:" 144 161 msgstr "Afficher les boutons sur chaques billets de la page d'accueil :" 145 162 146 #: index.php:19 6163 #: index.php:198 147 164 msgid "Show buttons on each posts on categorie page:" 148 165 msgstr "Afficher les boutons sur chaques billets de la page de catégorie :" 149 166 150 #: index.php:20 0167 #: index.php:202 151 168 msgid "Show buttons on each posts on tag page:" 152 169 msgstr "Afficher les boutons sur chaques pages de tag :" 153 170 154 #: index.php:20 4171 #: index.php:206 155 172 msgid "Show buttons on a post page:" 156 173 msgstr "Afficher les boutons sur la page d'un billet :" -
plugins/shareOn/release.txt
r2261 r2400 2 2 * Added CSS class to buttons box 3 3 * Fixed buttons default size 4 5 0.5 20100626 6 * Switched to DC 2.2 7 * Fixed rights (limit to admin) 8 * Fixed default buttons settings 4 9 5 10 0.4.2 20100506
Note: See TracChangeset
for help on using the changeset viewer.