[pLog-svn] r6466 - in plog/branches/lifetype-1.2/class: action/admin dao

jondaley at devel.lifetype.net jondaley at devel.lifetype.net
Sun May 18 07:15:11 EDT 2008


Author: jondaley
Date: 2008-05-18 07:15:10 -0400 (Sun, 18 May 2008)
New Revision: 6466

Modified:
   plog/branches/lifetype-1.2/class/action/admin/adminupdatearticlecategoryaction.class.php
   plog/branches/lifetype-1.2/class/dao/articlecategory.class.php
Log:
mangled name wasn't changed when the article category was renamed.  Fixes #1513.

Modified: plog/branches/lifetype-1.2/class/action/admin/adminupdatearticlecategoryaction.class.php
===================================================================
--- plog/branches/lifetype-1.2/class/action/admin/adminupdatearticlecategoryaction.class.php	2008-05-14 07:38:00 UTC (rev 6465)
+++ plog/branches/lifetype-1.2/class/action/admin/adminupdatearticlecategoryaction.class.php	2008-05-18 11:15:10 UTC (rev 6466)
@@ -73,6 +73,7 @@
 
             // update the fields
             $category->setName( $this->_categoryName );
+            $category->setMangledName( $this->_categoryName, true );
             $category->setUrl( "" );
             $category->setInMainPage( $this->_categoryInMainPage );
 			$category->setProperties( $this->_properties );

Modified: plog/branches/lifetype-1.2/class/dao/articlecategory.class.php
===================================================================
--- plog/branches/lifetype-1.2/class/dao/articlecategory.class.php	2008-05-14 07:38:00 UTC (rev 6465)
+++ plog/branches/lifetype-1.2/class/dao/articlecategory.class.php	2008-05-18 11:15:10 UTC (rev 6466)
@@ -360,11 +360,15 @@
 		 * links when custom URLs are enabled.
 		 *
 		 * @param mangledName A string containing a 'url-ified' version of the category name
-		 */		
-		function setMangledName( $mangledName )
-		{
-			$this->_mangledName = $mangledName;
-		}
+		 */
+        function setMangledName( $mangledName, $modify = false )
+        {
+            if( $modify ) {
+                lt_include( PLOG_CLASS_PATH."class/data/textfilter.class.php" );
+                $mangledName = Textfilter::urlize( $mangledName );
+            }
+            $this->_mangledName = $mangledName;
+        }
 		
 		/**
 		 * Returns the BlogInfo object to which this category belongs



More information about the pLog-svn mailing list