Project

General

Profile

Actions

Bug #15827

closed

CLI Mode does not work properly under windows 2003 server

Added by Mathias Schreiber over 18 years ago. Updated over 18 years ago.

Status:
Closed
Priority:
Should have
Category:
-
Target version:
-
Start date:
2006-03-14
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.0
PHP Version:
4
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

init.php does check for paths in several ways.
PHP under windows 2003 server gives back backward slashes if "dirname" is used.
init.php then checks if ../typo3conf/ is avaliable in that path.
During calls from the webserver this is totally fine, since apache will convert those slashes to forward slashes and we are fine again.
PHP Command Line interface keeps the backslashes.

Set up a command line class as you wish.
Get burried in errors and PHPINFO output.
:)

init.php in 4.0RC1:
Add these lines on line 80 and following:
if (defined('TYPO3_cliMode') && TYPO3_OS == 'WIN') {
$temp_path = str_replace('\\','/',$temp_path);
}
These "fixed" path will work for the check.
(issue imported from #M2871)


Files

bug-2871-1.diff (694 Bytes) bug-2871-1.diff Administrator Admin, 2006-06-07 15:12
Actions #1

Updated by Michael Stucki over 18 years ago

Hi Mathias, attached is a patch written by Karsten that seems to solve the problem according to your description. Can you please test it and confirm if it works? Otherwise it will remain unresolved in 4.0.1...

Actions #2

Updated by Mathias Schreiber over 18 years ago

Thanks.

I can't find a check for the environment.
This bug only applies if a Windows System is used AND CLI Mode is on.

Otherwise everything will work fine.

Background:
Webserver (Linux and WIndows alike) will fix the Backslashes to Forward Slashes.
So all WEB DRIVEN applications in TYPO3 work out fine.

But if you use CLI Mode, there are no webserver involved, thus the slashes cannot be converted.

Actions #3

Updated by Karsten Dambekalns over 18 years ago

Mathias, that is right. But the replavcement doesn't do any harm, and a few lines up is a similar one without a check, too. So we decided to KISS. :)

Actions #4

Updated by Karsten Dambekalns over 18 years ago

Mathias, is the patch working for you? This is still unclear...

Actions #5

Updated by Mathias Schreiber over 18 years ago

Seems to work here

Actions #6

Updated by Karsten Dambekalns over 18 years ago

Is in CVS for a while now.

Actions

Also available in: Atom PDF