Esempio n. 1
0
 public static function toSlug($string, $separator = '-', $replace = null, $lowercase = true)
 {
     $string = self::decodeText($string);
     $string = self::removeVietnameseMark($string);
     return TextSlug::generate($string, $separator, $replace, $lowercase);
 }
Esempio n. 2
0
 /**
  * Converts texts into URL-friendly titles
  *
  *<code>
  * echo WpPepVN\Tag::friendlyTitle('These are big important news', '-')
  *</code>
  *
  * @param string text
  * @param string separator
  * @param boolean lowercase
  * @param mixed replace
  * @return text
  */
 public static function friendlyTitle($text, $separator = '-', $lowercase = true, $replace = null)
 {
     return TextSlug::generate($text, $separator, $replace, $lowercase);
 }