Permalink
Browse files

Added new method JApplication::__toString

git-svn-id: http://joomlacode.org/svn/joomla/development/trunk@13267 6f6e1ebd-4c2b-0410-823f-f34bde69bce9
  • Loading branch information...
1 parent 2453a36 commit 3b12b1921f1937136ba08247bf82102cb8cfda6b @ercanozkaya ercanozkaya committed Oct 21, 2009
Showing with 17 additions and 7 deletions.
  1. +1 −1 administrator/index.php
  2. +1 −1 index.php
  3. +3 −5 installation/index.php
  4. +12 −0 libraries/joomla/application/application.php
@@ -49,4 +49,4 @@
JDEBUG ? $_PROFILER->mark('afterRender') : null;
// Return the response.
-echo JResponse::toString($app->getCfg('gzip'));
+echo $app;
View
@@ -45,4 +45,4 @@
JDEBUG ? $_PROFILER->mark('afterRender') : null;
// Return the response.
-echo JResponse::toString($app->getCfg('gzip'));
+echo $app;
@@ -63,15 +63,13 @@
jimport('joomla.utilities.string');
// Create the application object.
-$app = & JFactory::getApplication('installation');
+$app = &JFactory::getApplication('installation');
// Initialize the application.
$app->initialise();
// Render the document.
$app->render();
-/**
- * RETURN THE RESPONSE
- */
-echo JResponse::toString();
+// Return the response.
+echo $app;
@@ -852,4 +852,16 @@ public function isSite()
{
return ($this->_clientId == 0);
}
+
+ /**
+ * Returns the response
+ *
+ * @return string
+ * @since 1.6
+ */
+ public function __toString()
+ {
+ $compress = $this->getCfg('gzip', false);
+ return JResponse::toString($compress);
+ }
}

0 comments on commit 3b12b19

Please sign in to comment.