User Tools

Site Tools


en:dev:284:registry

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Last revisionBoth sides next revision
en:dev:284:registry [26.09.2023 04:21] – [Overview] Manuela v.d.Deckenen:dev:284:registry [26.09.2023 06:24] Manuela v.d.Decken
Line 69: Line 69:
  
 __for all statements in common the following rules apply:__ __for all statements in common the following rules apply:__
-  * As PATH_SEPERATOR only the slash** / ** is allowed. Adjustments can be made easily with\\ <php> $sPath = str_replace('\\', '/', $sPath); </php>+  * As PATH_SEPERATOR only the slash** / ** is allowed. Adjustments can be made easily with\\ <code> $sPath = str_replace('\\', '/', $sPath); </code>
   * If the last element of a URL, Rel, Path-, or Dir-specified directory, the indication must terminate on a slash** / **.\\   * If the last element of a URL, Rel, Path-, or Dir-specified directory, the indication must terminate on a slash** / **.\\
-  * To ensure that a directory path is terminated with a single slash** / **the short sequence is sufficient\\ <php> $sPath = rtrim($sPath, '/').'/'; </php+  * To ensure that a directory path is terminated with a single slash** / **the short sequence is sufficient\\ <code> $sPath = rtrim($sPath, '/').'/'; </code
-  *  Leading slashes** / **are removed by\\ <php>  $sPath = ltrim($sPath, '/');  </php>+  *  Leading slashes** / **are removed by\\ <code>  $sPath = ltrim($sPath, '/');  </code>
  
 OLD => NEW example: OLD => NEW example:
Line 86: Line 86:
  
 ===== Application of WbAdaptor ===== ===== Application of WbAdaptor =====
-This class can be reached from anywhere. It is sufficient to import that only existing active instance of the class with\\ <php> $oReg = \bin\WbAdaptor::getInstance(); </php> to import into the current scope. +This class can be reached from anywhere. It is sufficient to import that only existing active instance of the class with\\ <code> $oReg = \bin\WbAdaptor::getInstance(); </code> to import into the current scope. 
 But even better is the use of dependency injection, i.e. the transfer of the instance from outside to the function or class. But even better is the use of dependency injection, i.e. the transfer of the instance from outside to the function or class.
  
Line 92: Line 92:
  
 Also the request of the individual values quite straightforward:\\ Also the request of the individual values quite straightforward:\\
-<php> echo $oReg->TemplateDir.'images/logo.png'; </php> \\+<code> echo $oReg->TemplateDir.'images/logo.png'; </code> \\
 Output:  ''templates/myTemplate/images/logo.png'' Output:  ''templates/myTemplate/images/logo.png''
  
en/dev/284/registry.txt · Last modified: 26.09.2023 07:14 by Manuela v.d.Decken