[pLog-svn] r1270 - plog/trunk/class/view

oscar at devel.plogworld.net oscar at devel.plogworld.net
Tue Mar 1 07:28:47 GMT 2005


Author: oscar
Date: 2005-03-01 07:28:46 +0000 (Tue, 01 Mar 2005)
New Revision: 1270

Modified:
   plog/trunk/class/view/resourceserverview.class.php
Log:
fixed an issue with files from the resource center as reported here: http://forums.plogworld.net/viewtopic.php?t=1779. Looks like the View::setContentType() method was setting the content type after the ResourceServerView class was
setting the mime type of the resource file... I've fixed it by overwriting the View::setContentType() method to do 
nothing in ResourceServerView.


Modified: plog/trunk/class/view/resourceserverview.class.php
===================================================================
--- plog/trunk/class/view/resourceserverview.class.php	2005-03-01 07:19:53 UTC (rev 1269)
+++ plog/trunk/class/view/resourceserverview.class.php	2005-03-01 07:28:46 UTC (rev 1270)
@@ -54,6 +54,18 @@
 			return true;
 		}
 		
+		/**
+		 * we need to overwrite this method or else the View class will be sending the wrong
+		 * content type and character encoding... We overwrite it to do nothing, since we have
+		 * already sent the content type in _initResponse()
+		 *
+		 * @see View::sendContentType()		  
+		 */
+		function sendContentType()
+		{
+			return( true );	
+		}		
+		
 		function render()
 		{
 			// call the render method in the main view class... it will take care of sending the headers




More information about the pLog-svn mailing list