php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #43317 Changed on include
Submitted: 2007-11-17 13:04 UTC Modified: 2007-11-17 13:30 UTC
From: jcastromail at yahoo dot es Assigned:
Status: Not a bug Package: Reproducible crash
PHP Version: 5.2.5 OS: Windows XP sp2
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: jcastromail at yahoo dot es
New email:
PHP Version: OS:

 

 [2007-11-17 13:04 UTC] jcastromail at yahoo dot es
Description:
------------
Hi there:

In *WINDOWS*, function include fail when i try :

  include("include\test2.php");

but works with : (take note on \ and / symbol)

  include("include/test2.php"); 
  include("include\\test2.php"); 

This error started when i installed the latest version.
I don't sure if the use of folder\file is a bad practice or not but i don't find this change on the documentation.



Reproduce code:
---------------
file test.php

<?php 
	include("include\test2.php");
?> 

file test2 on folder include

<?
  echo "include!!\n";
?>

Expected result:
----------------
include!!


Actual result:
--------------
[17-Nov-2007 09:56:35] PHP Warning:  include() [<a href='function.include'>function.include</a>]: Failed opening 'include	est2.php' for inclusion (include_path='.;C:\php5\pear') in C:\ats\fum\test.php on line 2



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-11-17 13:30 UTC] scottmac@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

\t is a tab character.
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Sat Mar 28 19:00:01 2026 UTC