[Cs-content-commits] SF.net SVN: cs-content:[412] trunk/1.0/cs_tabs.class.php
PHP Templating & Includes System
Brought to you by:
crazedsanity
From: <cra...@us...> - 2009-07-29 19:03:45
|
Revision: 412 http://cs-content.svn.sourceforge.net/cs-content/?rev=412&view=rev Author: crazedsanity Date: 2009-07-29 19:03:37 +0000 (Wed, 29 Jul 2009) Log Message: ----------- Minor adjustment to add a bit of flexibility to tabs. /cs_tabs.class.php: * display_tabs(): -- add "cleanTitle" to the (small) list of things that can be parsed into the tab template: it is basically the title, but stripped-down to alphanumerics ONLY, with anything else replaced with underscores. -- NOTE::: in a title that has multiple replaced characters in a row, they will have the corresponding number of underscores. For instance, "My - Tab" would become "My___Tab". Modified Paths: -------------- trunk/1.0/cs_tabs.class.php Modified: trunk/1.0/cs_tabs.class.php =================================================================== --- trunk/1.0/cs_tabs.class.php 2009-07-22 04:54:48 UTC (rev 411) +++ trunk/1.0/cs_tabs.class.php 2009-07-29 19:03:37 UTC (rev 412) @@ -149,8 +149,9 @@ } $parseThis = array( - 'title' => $tabName, - 'url' => $url + 'title' => $tabName, + 'url' => $url, + 'cleanTitle' => preg_replace('/[^a-zA-Z0-9]/', '_', $tabName) ); $finalString .= $this->csPageObj->mini_parser($useTabContent, $parseThis, '%%', '%%'); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |