[pLog-svn] r1298 - plugins/trunk/atom/class/net

oscar at devel.plogworld.net oscar at devel.plogworld.net
Thu Mar 3 23:21:15 GMT 2005


Author: oscar
Date: 2005-03-03 23:21:14 +0000 (Thu, 03 Mar 2005)
New Revision: 1298

Modified:
   plugins/trunk/atom/class/net/atomrequestgenerator.class.php
Log:
one small fix to get the atom plugin to work well with nokia's own Lifeblog

Modified: plugins/trunk/atom/class/net/atomrequestgenerator.class.php
===================================================================
--- plugins/trunk/atom/class/net/atomrequestgenerator.class.php	2005-03-03 23:04:02 UTC (rev 1297)
+++ plugins/trunk/atom/class/net/atomrequestgenerator.class.php	2005-03-03 23:21:14 UTC (rev 1298)
@@ -115,7 +115,14 @@
 		      $config =& Config::getConfig();
 		      $url = new Url($config->getValue( "base_url" ));
 		      $articleDate = $article->getDateObject();
-		      $date = $articleDate->getYear()."-".$articleDate->getMonth()."-".$articleDate->getDay();
+			  $month = $articleDate->getMonth();
+			  if( $month < 10 && strlen($month) < 2)
+				$month = "0".$month;
+			  $day = $articleDate->getDay();
+			  if( $day < 10 && strlen($day) < 2)
+				$day = "0".$day;				
+				
+		      $date = $articleDate->getYear()."-".$month."-".$day;
 		      $tag = "tag:post:".$url->getHost().",".$date.":".$article->getId();
 		      
 		      return $tag;




More information about the pLog-svn mailing list