Issue Details (XML | Word | Printable)

Key: MDL-18195
Type: Sub-task Sub-task
Status: Resolved Resolved
Resolution: Fixed
Priority: Minor Minor
Assignee: Eloy Lafuente (stronk7)
Reporter: Eloy Lafuente (stronk7)
Votes: 0
Watchers: 0
Operations

Add/Edit UI Mockup to this issue
If you were logged in you would be able to see more operations.
Moodle
MDL-17458

Slashes normalization in installer

Created: 10/Feb/09 12:36 AM   Updated: 12/Feb/09 02:02 AM
Return to search
Component/s: Installation
Affects Version/s: 2.0
Fix Version/s: 2.0

Database: Any
Participants: Eloy Lafuente (stronk7) and Petr Skoda
Security Level: None
QA Assignee: Petr Skoda
Resolved date: 12/Feb/09
Affected Branches: MOODLE_20_STABLE
Fixed Branches: MOODLE_20_STABLE


 Description  « Hide
When working in the Windows installer, I've detected that threre are some problems with back & forward slashes in the installer:

dirroot is calculated with dirname() that uses "native" windows backslashes.
dataroot is calculated with moodle stuff, that always use forwardslashes

Later, dirroot is written with forwardslashes.

And then, later, in admin/index.php, dirroot is checked again with realpath(), and that doesn't pass the test when comparing back & forward slashed dirroots.

So I'm going to:

0) After chat with Sam, use always forward-slashes seems to be ok.
1) Change install to suggest forward-slashed dirroot.
2) Change admin/index.php check to ignore back & forward slashes differences.

Ciao :-)

 All   Comments   Change History   Version Control      Sort Order: Ascending order - Click to sort in descending order
Eloy Lafuente (stronk7) added a comment - 10/Feb/09 06:36 AM
I've done 2) make the admin/index.php slash-insensitive

Petr, do you have anything to do about 1) like calculate dirroot/dataroot always with forward-slashes?

Or can we leave that, as far as config.php is always written with forward ones?

Ciao


Petr Skoda added a comment - 10/Feb/09 07:40 AM
my +1 for always / everywhere

Eloy Lafuente (stronk7) added a comment - 10/Feb/09 11:07 AM
Oki going to implement 1) calculated dirrott/dataroot with forward-slashes

Eloy Lafuente (stronk7) added a comment - 12/Feb/09 02:02 AM
Done. Now all initial calculations + config.php write are always using forward slashes.

Resolving as fixed. Ciao