concatTitleFields() static public method

Joins two title string fragments (in $fields) either with a space or a colon.
static public concatTitleFields ( $fields ) : string
$fields array
return string the joined string
Esempio n. 1
0
 /**
  * Get the chapter full title (with title and subtitle).
  * @return string
  */
 function getLocalizedFullTitle()
 {
     $fullTitle = $this->getLocalizedTitle();
     if ($subtitle = $this->getLocalizedSubtitle()) {
         $fullTitle = PKPString::concatTitleFields(array($fullTitle, $subtitle));
     }
     return $fullTitle;
 }
Esempio n. 2
0
 /**
  * Get the series full title (with title and subtitle).
  * @return string
  */
 function getLocalizedFullTitle()
 {
     $fullTitle = null;
     if ($prefix = $this->getLocalizedPrefix()) {
         $fullTitle = $prefix . ' ';
     }
     $fullTitle .= $this->getLocalizedTitle();
     if ($subtitle = $this->getLocalizedSubtitle()) {
         $fullTitle = PKPString::concatTitleFields(array($fullTitle, $subtitle));
     }
     return $fullTitle;
 }
 /**
  * Get the submission full title (with prefix, title
  * and subtitle).
  * @param $locale string Locale to fetch data in.
  * @return string
  */
 function getFullTitle($locale)
 {
     $fullTitle = $this->getTitle($locale);
     if ($subtitle = $this->getSubtitle($locale)) {
         $fullTitle = PKPString::concatTitleFields(array($fullTitle, $subtitle));
     }
     return $fullTitle;
 }
Esempio n. 4
0
 /**
  * Get the submission full title (with prefix, title
  * and subtitle).
  * @param $locale string Locale to fetch data in.
  * @return string
  */
 function getFullTitle($locale)
 {
     $fullTitle = null;
     if ($prefix = $this->getPrefix($locale)) {
         $fullTitle = $prefix . ' ';
     }
     $fullTitle .= $this->getTitle($locale);
     if ($subtitle = $this->getSubtitle($locale)) {
         $fullTitle = PKPString::concatTitleFields(array($fullTitle, $subtitle));
     }
     return $fullTitle;
 }