Ticket #125: index.html.diff

File index.html.diff, 1.8 kB (added by dmondark, 12 months ago)

a patch for index.html

  • .

     
    733733<pre>public function filter_plugin_config( $actions, $plugin_id ) 
    734734        { 
    735735                if ( $plugin_id == $this->plugin_id() ) { 
    736                         $actions[] = _('Configure'); 
     736                        $actions[] = _t('Configure'); 
    737737                } 
    738738                return $actions; 
    739739        }</pre> 
    740 The _() function translates the string into the language used by the site.  For English-language blogs, the output would be "Configure", while for Spanish-language blogs, for example, the output might be "Configurar". 
     740The _t() function translates the string into the language used by the site.  For English-language blogs, the output would be "Configure", while for Spanish-language blogs, for example, the output might be "Configurar". 
    741741<pre>public function action_plugin_ui( $plugin_id, $action ) 
    742742        { 
    743743                if ( $plugin_id == $this->plugin_id() ) { 
     
    742742        { 
    743743                if ( $plugin_id == $this->plugin_id() ) { 
    744744                        switch ( $action ) { 
    745                                 case _('Configure') : 
     745                                case _t('Configure') : 
    746746                                        $ui = new FormUI( strtolower( get_class( $this ) ) ); 
    747                                         $customvalue= $ui->add( 'text', 'customvalue', _('Your custom value:') ); 
     747                                        $customvalue= $ui->add( 'text', 'customvalue', _t('Your custom value:') ); 
    748748                                        $ui->on_success( array( $this, 'updated_config' ) ); 
    749749                                        $ui->out(); 
    750750                                break;