| [ Index ] |
PHP Cross Reference of Joomla 1.5.26 DE |
[Summary view] [Print] [Text view]
1 <?php 2 /** 3 * @version $Id: parameters.php 14401 2010-01-26 14:10:00Z louis $ 4 * @package Joomla.Legacy 5 * @subpackage 1.5 6 * @copyright Copyright (C) 2005 - 2010 Open Source Matters. All rights reserved. 7 * @license GNU/GPL, see LICENSE.php 8 * Joomla! is free software. This version may have been modified pursuant 9 * to the GNU General Public License, and as distributed it includes or 10 * is derivative of works licensed under the GNU General Public License or 11 * other free or open source software licenses. 12 * See COPYRIGHT.php for copyright notices and details. 13 */ 14 15 // Check to ensure this file is within the rest of the framework 16 defined('JPATH_BASE') or die(); 17 18 // Register legacy classes for autoloading 19 JLoader::register('JParameter' , JPATH_LIBRARIES.DS.'joomla'.DS.'html'.DS.'parameter.php'); 20 21 /** 22 * Legacy class, use {@link JParameter} instead 23 * 24 * @deprecated As of version 1.5 25 * @package Joomla.Legacy 26 * @subpackage 1.5 27 */ 28 class mosParameters extends JParameter 29 { 30 /** 31 * @param string The raw parms text 32 * @param string Path to the xml setup file 33 * @param string The type of setup file 34 */ 35 function __construct($text, $path = '', $type = 'component') 36 { 37 parent::__construct($text, $path); 38 } 39 40 /** 41 * Legacy function, use {@link JParameter::toObject() JParameter->toObject()} instead 42 * 43 * @deprecated As of version 1.5 44 */ 45 function toObject() 46 { 47 parent::toObject(); 48 } 49 50 /** 51 * Legacy function, use {@link JParameter::toArray() JParameter->toArray()} instead 52 * 53 * @deprecated As of version 1.5 54 */ 55 function toArray() 56 { 57 parent::toArray(); 58 } 59 60 /** 61 * Parse an .ini string, based on phpDocumentor phpDocumentor_parse_ini_file function 62 * 63 * @access public 64 * @param mixed The ini string or array of lines 65 * @param boolean add an associative index for each section [in brackets] 66 * @return object 67 */ 68 function parse($txt, $process_sections = false, $asArray = false) 69 { 70 $this->loadINI($txt); 71 72 if($asArray) { 73 return $this->toArray(); 74 } 75 76 return $this->toObject( ); 77 } 78 79 /** 80 * Special handling for textarea param 81 */ 82 function textareaHandling( &$txt ) 83 { 84 $total = count( $txt ); 85 for( $i=0; $i < $total; $i++ ) { 86 if ( strstr( $txt[$i], "\n" ) ) { 87 $txt[$i] = str_replace( "\n", '<br />', $txt[$i] ); 88 } 89 } 90 $txt = implode( "\n", $txt ); 91 92 return $txt; 93 } 94 }
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
| Generated: Wed Mar 28 15:54:07 2012 | Cross-referenced by PHPXref 0.7.1 |