[Mapbender-commits] r8547 - trunk/mapbender/http/classes

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Fri Jan 18 10:50:42 PST 2013


Author: armin11
Date: 2013-01-18 10:50:41 -0800 (Fri, 18 Jan 2013)
New Revision: 8547

Modified:
   trunk/mapbender/http/classes/class_connector.php
Log:
Allow print module to work under owsproxy and redirects with curl

Modified: trunk/mapbender/http/classes/class_connector.php
===================================================================
--- trunk/mapbender/http/classes/class_connector.php	2013-01-18 17:52:04 UTC (rev 8546)
+++ trunk/mapbender/http/classes/class_connector.php	2013-01-18 18:50:41 UTC (rev 8547)
@@ -35,6 +35,7 @@
 	private $httpContentType;
 	private $httpPostFieldsNumber;
 	private $curlSendCustomHeaders = true; //decide to send own headers or not
+	private $curlCookiesession = true;
 	
 		
 	/**
@@ -204,8 +205,8 @@
 		curl_setopt($ch, CURLOPT_BINARYTRANSFER, true); //for images
 		curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
 		curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
-		//dont store and load cookies from previous sessions
-		curl_setopt($ch, CURLOPT_COOKIESESSION, true);
+		//hold cookies on redirects (302) - http://stackoverflow.com/questions/1458683/how-do-i-pass-cookies-on-a-curl-redirect - needed for print via internal owsproxy!
+		curl_setopt($ch, CURLOPT_COOKIEFILE, "");
 		//allow https connections and handle certificates quite simply ;-)
 		curl_setopt($ch,CURLOPT_SSL_VERIFYHOST,0);
 		curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);



More information about the Mapbender_commits mailing list