Ticket #1943: meta-1943.patch
File meta-1943.patch, 9.5 KB (added by , 8 years ago) |
---|
-
sites/trunk/profiles.wordpress.org/public_html/wp-content/plugins/wporg-profiles-activity-handler/wporg-profiles-activity-handler.php
290 290 // Action message for topic creation. 291 291 if ( 'forum_topic_create' === $type ) { 292 292 $action = sprintf( 293 __( 'Created a topic, <i><a href="%s">%s</a></i>, on the site %s', 'wporg' ), 294 esc_url( $_POST['url'] ), 295 esc_html( $_POST['title'] ), 293 /* translators: 1: link to the topic, 2: site title */ 294 __( 'Created a topic, %1$s, on the site %2$s', 'wporg' ), 295 sprintf( '<i><a href="%s">%s</a></i>', 296 esc_url( $_POST['url'] ), 297 esc_html( $_POST['title'] ) 298 ), 296 299 esc_html( $_POST['site'] ) 297 300 ); 298 301 } … … 299 302 // Action message for reply creation. 300 303 else { 301 304 $action = sprintf( 302 __( 'Posted a <a href="%s">reply</a> to <i>%s</i>, on the site %s', 'wporg' ), 305 /* translators: 1: reply URL, 2: topic title, 3: site title */ 306 __( 'Posted a <a href="%1$s">reply</a> to %2$s, on the site %3$s', 'wporg' ), 303 307 esc_url( $_POST['url'] ), 304 esc_html( $_POST['title'] ),308 '<i>' . esc_html( $_POST['title'] ) . '</i>', 305 309 esc_html( $_POST['site'] ) 306 310 ); 307 311 } … … 349 353 $args = array( 350 354 'user_id' => $user->ID, 351 355 'action' => sprintf( 352 __( 'Released a new plugin, <a href="%s">%s</a>', 'wporg' ), 353 esc_url( $_POST['url'] ), 354 $_POST['title'] 356 /* translators: %s: link to the plugin */ 357 __( 'Released a new plugin, %s', 'wporg' ), 358 sprintf( '<a href="%s">%s</a>', 359 esc_url( $_POST['url'] ), 360 $_POST['title'] 361 ) 355 362 ), 356 363 'content' => '', 357 364 'primary_link' => $_POST['url'], … … 381 388 $args = array( 382 389 'user_id' => $user->ID, 383 390 'action' => sprintf( 384 __( 'Released a new theme, <a href="%s">%s</a>', 'wporg' ), 385 esc_url( $_POST['url'] ), 386 $_POST['title'] 391 /* translators: %s: link to the theme */ 392 __( 'Released a new theme, %s', 'wporg' ), 393 sprintf( '<a href="%s">%s</a>', 394 esc_url( $_POST['url'] ), 395 $_POST['title'] 396 ) 387 397 ), 388 398 'content' => '', 389 399 'primary_link' => $_POST['url'], … … 419 429 420 430 $args = array( 421 431 'user_id' => $user->ID, 422 'action' => sprintf( __( 'Created a new ticket in %s Trac', 'wporg' ), $_POST['trac'] ), 432 'action' => sprintf( 433 /* translators: %s: Trac title */ 434 __( 'Created a new ticket in %s Trac', 'wporg' ), 435 $_POST['trac'] 436 ), 423 437 'content' => $_POST['title'], 424 438 'component' => 'tracs', 425 439 'type' => 'trac_ticket_create', … … 434 448 435 449 $args = array( 436 450 'user_id' => $user->ID, 437 'action' => sprintf( __( 'Posted a reply to %s in %s Trac', 'wporg' ), $_POST['title'], $_POST['trac'] ), 451 'action' => sprintf( 452 /* translators: 1: ticket title, 2: Trac title */ 453 __( 'Posted a reply to %1$s in %2$s Trac', 'wporg' ), 454 $_POST['title'], 455 $_POST['trac'] 456 ), 438 457 'content' => $_POST['comment'], 439 458 'component' => 'tracs', 440 459 'type' => 'trac_comment_create', … … 450 469 // Record commit to committer's activity stream 451 470 $args = array( 452 471 'user_id' => $user->ID, 453 'action' => sprintf( __( 'Committed [%s] to %s Trac', 'wporg' ), $_POST['changeset'], $_POST['trac'] ), 472 'action' => sprintf( 473 /* translators: 1: revision number, 2: Trac title */ 474 __( 'Committed [%1$s] to %2$s Trac', 'wporg' ), 475 $_POST['changeset'], 476 $_POST['trac'] 477 ), 454 478 'content' => $_POST['message'], 455 479 'component' => 'tracs', 456 480 'type' => 'trac_commit_create', … … 472 496 if ( empty( $user ) ) continue; 473 497 $args = array( 474 498 'user_id' => $user->ID, 475 'action' => sprintf( __( 'Received props in %s', 'wporg' ), $_POST['trac'] ), 499 'action' => sprintf( 500 /* translators: %s: Trac title */ 501 __( 'Received props in %s', 'wporg' ), 502 $_POST['trac'] 503 ), 476 504 'content' => $_POST['message'], 477 505 'component' => 'tracs', 478 506 'type' => 'trac_props_mention', … … 504 532 505 533 if ( isset( $_POST['wordcamp_date'] ) && ! empty( $_POST['wordcamp_date'] ) ) { 506 534 $action = sprintf( 507 __( 'Confirmed as a speaker for <a href="%s">%s</a> coming up on %s', 'wporg' ), 508 esc_url( $_POST['url'] ), 509 $_POST['wordcamp_name'], 535 /* translators: 1: WordCamp link, 2: WordCamp date */ 536 __( 'Confirmed as a speaker for %1$s coming up on %2$s', 'wporg' ), 537 sprintf( '<a href="%s">%s</a>', 538 esc_url( $_POST['url'] ), 539 $_POST['wordcamp_name'] 540 ), 510 541 $_POST['wordcamp_date'] 511 542 ); 512 543 } else { 513 544 $action = sprintf( 514 __( 'Confirmed as a speaker for <a href="%s">%s</a>', 'wporg' ), 515 esc_url( $_POST['url'] ), 516 $_POST['wordcamp_name'] 545 /* translators: %s: WordCamp link */ 546 __( 'Confirmed as a speaker for %s', 'wporg' ), 547 sprintf( '<a href="%s">%s</a>', 548 esc_url( $_POST['url'] ), 549 $_POST['wordcamp_name'] 550 ) 517 551 ); 518 552 } 519 553 } elseif ( isset( $_POST['organizer_id'] ) && ! empty( $_POST['organizer_id'] ) ) { … … 522 556 523 557 if ( isset( $_POST['wordcamp_date'] ) && ! empty( $_POST['wordcamp_date'] ) ) { 524 558 $action = sprintf( 525 __( 'Joined the organizing team for <a href="%s">%s</a> coming up %s', 'wporg' ), 526 esc_url( $_POST['url'] ), 527 $_POST['wordcamp_name'], 559 /* translators: 1: WordCamp link, 2: WordCamp date */ 560 __( 'Joined the organizing team for %1$s coming up on %2$s', 'wporg' ), 561 sprintf( '<a href="%s">%s</a>', 562 esc_url( $_POST['url'] ), 563 $_POST['wordcamp_name'] 564 ), 528 565 $_POST['wordcamp_date'] 529 566 ); 530 567 } else { 531 568 $action = sprintf( 532 __( 'Joined the organizing team for <a href="%s">%s</a>', 'wporg' ), 533 esc_url( $_POST['url'] ), 534 $_POST['wordcamp_name'] 569 /* translators: %s: WordCamp link */ 570 __( 'Joined the organizing team for %s', 'wporg' ), 571 sprintf( '<a href="%s">%s</a>', 572 esc_url( $_POST['url'] ), 573 $_POST['wordcamp_name'] 574 ) 535 575 ); 536 576 } 537 577 } elseif ( isset( $_POST['attendee_id'] ) && ! empty( $_POST['attendee_id'] ) ) { … … 540 580 if ( 'attendee_registered' == $_POST['activity_type'] ) { 541 581 $type = 'wordcamp_attendee_add'; 542 582 543 $action = sprintf(544 __( 'Registered to attend <a href="%s">%s</a>', 'wporg' ),545 esc_url( $_POST['url'] ),546 $_POST['wordcamp_name']547 );548 549 583 if ( isset( $_POST['wordcamp_date'] ) && ! empty( $_POST['wordcamp_date'] ) ) { 550 $action .= ' ' . sprintf( __( 'coming up %s', 'wporg' ), $_POST['wordcamp_date'] ); 584 $action = sprintf( 585 /* translators: 1: WordCamp link, 2: WordCamp date */ 586 __( 'Registered to attend %1$s coming up on %2$s', 'wporg' ), 587 sprintf( '<a href="%s">%s</a>', 588 esc_url( $_POST['url'] ), 589 $_POST['wordcamp_name'] 590 ), 591 $_POST['wordcamp_date'] 592 ); 593 } else { 594 $action = sprintf( 595 /* translators: %s: WordCamp link */ 596 __( 'Registered to attend %s', 'wporg' ), 597 sprintf( '<a href="%s">%s</a>', 598 esc_url( $_POST['url'] ), 599 $_POST['wordcamp_name'] 600 ) 601 ); 551 602 } 552 603 } elseif ( 'attendee_checked_in' == $_POST['activity_type'] ) { 553 604 $type = 'wordcamp_attendee_checked_in'; … … 554 605 $order = absint( $_POST['checked_in_count'] ); 555 606 556 607 $action = sprintf( 557 __( 'Is the %s person to arrive at <a href="%s">%s</a>', 'wporg' ), 608 /* translators: 1: number of the person, 2: WordCamp link */ 609 __( 'Is the %1$s person to arrive at %2$s', 'wporg' ), 558 610 $this->append_ordinal_suffix( $order ), 559 esc_url( $_POST['url'] ), 560 $_POST['wordcamp_name'] 611 sprintf( '<a href="%s">%s</a>', 612 esc_url( $_POST['url'] ), 613 $_POST['wordcamp_name'] 614 ) 561 615 ); 562 616 } 563 617 } … … 623 677 $type = 'blog_comment_create'; 624 678 $item_id = $_POST['comment_id']; 625 679 $action = sprintf( 626 __( 'Wrote a <a href="%s">comment</a> on the post %s, on the site %s', 'wporg' ), 680 /* translators: 1: comment URL, 2: post title, 3: site title */ 681 __( 'Wrote a <a href="%1$s">comment</a> on the post %2$s, on the site %3$s', 'wporg' ), 627 682 esc_url( $_POST['url'] ), 628 683 $_POST['title'], 629 684 $_POST['blog'] … … 632 687 $type = 'blog_post_create'; 633 688 $item_id = $_POST['post_id']; 634 689 $action = sprintf( 635 __( 'Wrote a new post, <a href="%s">%s</a>, on the site %s', 'wporg' ), 636 esc_url( $_POST['url'] ), 637 $_POST['title'], 690 /* translators: 1: link to the post, 2: site title */ 691 __( 'Wrote a new post, %1$s, on the site %2$s', 'wporg' ), 692 sprintf( '<a href="%s">%s</a>', 693 esc_url( $_POST['url'] ), 694 $_POST['title'] 695 ), 638 696 $_POST['blog'] 639 697 ); 640 698 }