web:php:cakephp20
Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
web:php:cakephp20 [2014/10/18 04:09] – [Mise en place] sgariepy | web:php:cakephp20 [2022/02/02 00:42] (Version actuelle) – modification externe 127.0.0.1 | ||
---|---|---|---|
Ligne 71: | Ligne 71: | ||
- Dans '' | - Dans '' | ||
- | - Dans '' | + | - Dans '' |
Router:: | Router:: | ||
- | Router:: | + | Router:: |
</ | </ | ||
* Omettre le '' | * Omettre le '' | ||
+ | - Encore dans '' | ||
+ | Router:: | ||
+ | array( | ||
+ | ' | ||
+ | ' | ||
+ | ' | ||
+ | ' | ||
+ | ) | ||
+ | ); | ||
+ | Router:: | ||
+ | array( | ||
+ | ' | ||
+ | ' | ||
+ | ' | ||
+ | ' | ||
+ | ) | ||
+ | ); | ||
+ | </ | ||
+ | ===== Routes ===== | ||
+ | ==== POST / | ||
+ | |||
+ | Dans '' | ||
+ | <code php> | ||
+ | Router:: | ||
+ | array( | ||
+ | ' | ||
+ | ' | ||
+ | ' | ||
+ | ' | ||
+ | ), | ||
+ | array(' | ||
+ | ); | ||
+ | </ | ||
+ | |||
+ | |||
+ | ===== API Key ===== | ||
+ | |||
+ | |||
+ | |||
+ | ===== Sources ===== | ||
+ | * http:// | ||
+ | * https:// | ||
+ | * http:// | ||
+ | ====== Debug code ====== | ||
+ | |||
+ | |||
+ | <code php> | ||
+ | /** | ||
+ | * Prints out debug information about given variable. | ||
+ | * | ||
+ | * Only runs if debug level is greater than zero. | ||
+ | * | ||
+ | * @param boolean $var Variable to show debug information for. | ||
+ | * @param boolean $showHtml If set to true, the method prints the debug data in a screen-friendly way. | ||
+ | * @param boolean $showFrom If set to true, the method prints from where the function was called. | ||
+ | * @link http:// | ||
+ | */ | ||
+ | function debug($var = false, $showHtml = false, $showFrom = true) { | ||
+ | if (Configure:: | ||
+ | if ($showFrom) { | ||
+ | $calledFrom = debug_backtrace(); | ||
+ | echo '< | ||
+ | echo ' (line < | ||
+ | } | ||
+ | echo " | ||
+ | |||
+ | $var = print_r($var, | ||
+ | if ($showHtml) { | ||
+ | $var = str_replace('<', | ||
+ | } | ||
+ | echo $var . " | ||
+ | } | ||
+ | } | ||
+ | </ | ||
+ | [[http:// | ||
web/php/cakephp20.1413598165.txt.gz · Dernière modification : 2022/02/02 00:43 (modification externe)