|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #67260 php v5.5.12-1~dotdeb.1 parse_ini_file problems
Submitted: 2014-05-12 16:32 UTC Modified: 2021-06-06 04:22 UTC
Avg. Score:5.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: hakery at bk dot ru Assigned: cmb (profile)
Status: No Feedback Package: PHP options/info functions
PHP Version: 5.5.12 OS: Debian 7 (x64)
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2014-05-12 16:32 UTC] hakery at bk dot ru
problem occurs when parsing ini file. 
Apache Web server successfully handles parsing and outputs the result, in my case it change language on the site. Language changes successfully but at the same time, the script displays an error that I could not find the file.on the server and сentos 5.5.11 was no such problem

Test script:
function lang(){
	if(!isset($_SESSION['country'])){  //Проверки сессии. Если сессия пустая получаем код страны по ИП пользователя
		$country = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2);
		$langMod =$country.".ini";
		$landDir= $_SERVER['DOCUMENT_ROOT'].'/lang/'.$langMod;
		$_SESSION['DebugTemp']='Небыло сессии и определили его по ип';
					$lang = parse_ini_file("$landDir");   //проверяем есть ли языковой пакет в папке, если есть то загружаем его
					}else{  // если пакета нету грузим по умолчанию англ
					$langMod ="us.ini";
					$landDir= $_SERVER['DOCUMENT_ROOT'].'/lang/'.$langMod;
					$lang = parse_ini_file("$landDir");
		$langSession =$_SESSION['country']; 
		$langMod = $langSession;
		$landDir= $_SERVER['DOCUMENT_ROOT'].'/lang/'.$langMod.'.ini';
		$lang = parse_ini_file("$landDir");
		$_SESSION['DebugTemp']='из сессии';

Expected result:
change language

Actual result:
hange of language but also informs that the current language pack does not have a


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2021-05-28 13:52 UTC]
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2021-05-28 13:52 UTC]
Is this still an issue with any of the actively supported PHP

[1] <>
 [2021-06-06 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Jul 16 12:01:28 2024 UTC