original_string: public function publicationselector($courseid) {
          $text = '';
  
          $advertiseurl = new moodle_url("/course/publish/metadata.php",
              array('sesskey' => sesskey(), 'id' => $courseid, 'advertise' => true));
          $advertisebutton = new single_button($advertiseurl, get_string('advertise', 'hub'));
          $text .= $this->output->render($advertisebutton);
          $text .= html_writer::tag('div', get_string('advertisepublication_help', 'hub'),
              array('class' => 'publishhelp'));
  
          $text .= html_writer::empty_tag('br');  // TODO Delete.
  
          $uploadurl = new moodle_url("/course/publish/metadata.php",
              array('sesskey' => sesskey(), 'id' => $courseid, 'share' => true));
          $uploadbutton = new single_button($uploadurl, get_string('share', 'hub'));
          $text .= $this->output->render($uploadbutton);
          $text .= html_writer::tag('div', get_string('sharepublication_help', 'hub'),
              array('class' => 'publishhelp'));
  
          return $text;
      }
code: public function publicationselector($courseid) {
          $text = '';
  
          $advertiseurl = new moodle_url("/course/publish/metadata.php",
              array('sesskey' => sesskey(), 'id' => $courseid, 'advertise' => true));
          $advertisebutton = new single_button($advertiseurl, get_string('advertise', 'hub'));
          $text .= $this->output->render($advertisebutton);
          $text .= html_writer::tag('div', get_string('advertisepublication_help', 'hub'),
              array('class' => 'publishhelp'));
  
          $text .= html_writer::empty_tag('br');  // TODO Delete.
  
          $uploadurl = new moodle_url("/course/publish/metadata.php",
              array('sesskey' => sesskey(), 'id' => $courseid, 'share' => true));
          $uploadbutton = new single_button($uploadurl, get_string('share', 'hub'));
          $text .= $this->output->render($uploadbutton);
          $text .= html_writer::tag('div', get_string('sharepublication_help', 'hub'),
              array('class' => 'publishhelp'));
  
          return $text;
      }
code_tokens: public function publicationselector ( $ courseid ) { $ text = '' ; $ advertiseurl = new moodle_url ( "/course/publish/metadata.php" , array ( 'sesskey' => sesskey ( ) , 'id' => $ courseid , 'advertise' => true ) ) ; $ advertisebutton = new single_button ( $ advertiseurl , get_string ( 'advertise' , 'hub' ) ) ; $ text .= $ this -> output -> render ( $ advertisebutton ) ; $ text .= html_writer :: tag ( 'div' , get_string ( 'advertisepublication_help' , 'hub' ) , array ( 'class' => 'publishhelp' ) ) ; $ text .= html_writer :: empty_tag ( 'br' ) ; // TODO Delete. $ uploadurl = new moodle_url ( "/course/publish/metadata.php" , array ( 'sesskey' => sesskey ( ) , 'id' => $ courseid , 'share' => true ) ) ; $ uploadbutton = new single_button ( $ uploadurl , get_string ( 'share' , 'hub' ) ) ; $ text .= $ this -> output -> render ( $ uploadbutton ) ; $ text .= html_writer :: tag ( 'div' , get_string ( 'sharepublication_help' , 'hub' ) , array ( 'class' => 'publishhelp' ) ) ; return $ text ; }
docstring: Display the selector to advertise or publish a course
  @param int $courseid
docstring_tokens: Display the selector to advertise or publish a course