Revision: 1727
Author: olavmrk
Date: Fri Aug 28 02:09:11 2009
Log: SimpleSAML_XHTML_Template: Don't attempt to set language twice.
http://code.google.com/p/simplesamlphp/source/detail?r=1727

Modified:
  /trunk/lib/SimpleSAML/XHTML/Template.php

=======================================
--- /trunk/lib/SimpleSAML/XHTML/Template.php    Fri Aug 14 04:07:44 2009
+++ /trunk/lib/SimpleSAML/XHTML/Template.php    Fri Aug 28 02:09:11 2009
@@ -77,7 +77,9 @@
                $this->language = $language;
                // setcookie ( string $name [, string $value [, int $expire [, 
string  
$path [, string $domain [, bool $secure [, bool $httponly ]]]]]] )
                // time()+60*60*24*900 expires 900 days from now.
-               setcookie('language', $language, time()+60*60*24*900, '/');
+               if (!headers_sent()) {
+                       setcookie('language', $language, time()+60*60*24*900, 
'/');
+               }
        }

        /**

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"simpleSAMLphp commits" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/simplesamlphp-commits?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to