diff options
| author | Christian Fowler <spider@viovio.com> | 2007-09-25 06:36:45 +0000 |
|---|---|---|
| committer | Christian Fowler <spider@viovio.com> | 2007-09-25 06:36:45 +0000 |
| commit | d17b49967346935c74f093c93ea16e7f8120d772 (patch) | |
| tree | 5c323733785c6fc5fb77bdc418f24057866ffe01 /liberty_lib.php | |
| parent | 38c1f5d7aec0ebd452c3344dfcebc14866f98ee5 (diff) | |
| download | liberty-d17b49967346935c74f093c93ea16e7f8120d772.tar.gz liberty-d17b49967346935c74f093c93ea16e7f8120d772.tar.bz2 liberty-d17b49967346935c74f093c93ea16e7f8120d772.zip | |
add get_leadtitle and get_subtitle for pruning titles in .tpl's
Diffstat (limited to 'liberty_lib.php')
| -rw-r--r-- | liberty_lib.php | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/liberty_lib.php b/liberty_lib.php index be70ae0..618473d 100644 --- a/liberty_lib.php +++ b/liberty_lib.php @@ -1,6 +1,6 @@ <?php /** - * @version $Header: /cvsroot/bitweaver/_bit_liberty/liberty_lib.php,v 1.11 2007/09/15 01:58:34 spiderr Exp $ + * @version $Header: /cvsroot/bitweaver/_bit_liberty/liberty_lib.php,v 1.12 2007/09/25 06:36:45 spiderr Exp $ * @package liberty * @subpackage functions */ @@ -779,4 +779,19 @@ function get_image_size_options( $pEmptyOption = 'Disable this feature' ) { } return $ret; } + +function get_subtitle( $pTitle ) { + global $gBitSystem; + if( ($start = strpos( $pTitle, $gBitSystem->getConfig( 'libety_subtitle_delimiter',':' ) )) !== FALSE ) { + return( substr( $pTitle, ($start+1) ) ); + } +} + + +function get_leadtitle( $pTitle ) { + global $gBitSystem; + return( substr( $pTitle, 0, strpos( $pTitle, $gBitSystem->getConfig( 'libety_subtitle_delimiter',':' ) ) ) ); +} + + ?> |
