Space before and after period...

NorseMan

Member
I think i got some trouble with the code pasted below:

include __DIR__.'/../Templates/' .$templateFileName;

Is it correct with a space before and after the period or not?
I have pasted an example without space.
 
For make the code more clean I can suggest to add space before and after the dots, when you concating the strings.
But the code can be without space, with space, even with new line before or after, that code looks weird but it will works:
Code:
 include __DIR__     .
 '
 /../Templates/'
 .     $templateFileName
 ;
 
Thanks Michalio. So it doesn't matter if it is with or without a space. That part of the problem was solved, and that is not where the error lies. Therefore, I can ignore __DIR__ . and move on debugging 😊🤓
 
Back
Top