Fixed table presentations with new bootstrap, added HTML::abbr(), added public access to Database::config(), enabled DB compression to be disabled in database.php
This commit is contained in:
@@ -12,6 +12,26 @@
|
||||
abstract class lnApp_HTML extends Kohana_HTML {
|
||||
public static $windowed_urls = TRUE;
|
||||
|
||||
/**
|
||||
* Limit the number of characters that some text takes up.
|
||||
* If the Text is smaller than the number of characters to display, then it is
|
||||
* displayed normally.
|
||||
*
|
||||
* @param string Text to re-format
|
||||
* @param int Number of characters to display
|
||||
*/
|
||||
public static function abbr($string,$chars=0) {
|
||||
if (! $chars OR strlen($string)<=$chars)
|
||||
return $string;
|
||||
|
||||
return sprintf('<abbr title="%s">%s</abbr>',$string,Text::limit_chars($string,$chars));
|
||||
}
|
||||
|
||||
/**
|
||||
* If the string is blank, then return &nbsp;
|
||||
*
|
||||
* @param string Text to print.
|
||||
*/
|
||||
public static function nbsp($string) {
|
||||
if (strlen((string)$string))
|
||||
return $string;
|
||||
|
Reference in New Issue
Block a user