Bladeren bron

Add test on curl prerequisite. Remove test on GD lib.

Laurent Destailleur 9 jaren geleden
bovenliggende
commit
e747c39809
2 gewijzigde bestanden met toevoegingen van 16 en 1 verwijderingen
  1. 14 1
      htdocs/install/check.php
  2. 2 0
      htdocs/langs/en_US/install.lang

+ 14 - 1
htdocs/install/check.php

@@ -123,7 +123,7 @@ else
 
 
 // Check if GD supported
-if (! function_exists("imagecreate"))
+/*if (! function_exists("imagecreate"))
 {
 	$langs->load("errors");
 	print '<img src="../theme/eldy/img/warning.png" alt="Error"> '.$langs->trans("ErrorPHPDoesNotSupportGD")."<br>\n";
@@ -132,6 +132,19 @@ if (! function_exists("imagecreate"))
 else
 {
 	print '<img src="../theme/eldy/img/tick.png" alt="Ok"> '.$langs->trans("PHPSupportGD")."<br>\n";
+}*/
+
+
+// Check if Curl supported
+if (! function_exists("curl_init"))
+{
+    $langs->load("errors");
+    print '<img src="../theme/eldy/img/warning.png" alt="Error"> '.$langs->trans("ErrorPHPDoesNotSupportCurl")."<br>\n";
+    // $checksok=0;		// If image ko, just warning. So check must still be 1 (otherwise no way to install)
+}
+else
+{
+    print '<img src="../theme/eldy/img/tick.png" alt="Ok"> '.$langs->trans("PHPSupportCurl")."<br>\n";
 }
 
 

+ 2 - 0
htdocs/langs/en_US/install.lang

@@ -11,12 +11,14 @@ PHPSupportSessions=This PHP supports sessions.
 PHPSupportPOSTGETOk=This PHP supports variables POST and GET.
 PHPSupportPOSTGETKo=It's possible your PHP setup does not support variables POST and/or GET. Check your parameter <b>variables_order</b> in php.ini.
 PHPSupportGD=This PHP support GD graphical functions.
+PHPSupportCurl=This PHP support Curl.
 PHPSupportUTF8=This PHP support UTF8 functions.
 PHPMemoryOK=Your PHP max session memory is set to <b>%s</b>. This should be enough.
 PHPMemoryTooLow=Your PHP max session memory is set to <b>%s</b> bytes. This should be too low. Change your <b>php.ini</b> to set <b>memory_limit</b> parameter to at least <b>%s</b> bytes.
 Recheck=Click here for a more significative test
 ErrorPHPDoesNotSupportSessions=Your PHP installation does not support sessions. This feature is required to make Dolibarr working. Check your PHP setup.
 ErrorPHPDoesNotSupportGD=Your PHP installation does not support graphical function GD. No graph will be available.
+ErrorPHPDoesNotSupportCurl=Your PHP installation does not support Curl.
 ErrorPHPDoesNotSupportUTF8=Your PHP installation does not support UTF8 functions. Dolibarr can't work correctly. Solve this before installing Dolibarr.
 ErrorDirDoesNotExists=Directory %s does not exist.
 ErrorGoBackAndCorrectParameters=Go backward and correct wrong parameters.