Skip to content
This repository
Browse code

Remove more <?php blocks.

  • Loading branch information...
commit f75866c0ac2fff3f5e87fe58845bd57483a58322 1 parent 60ba09d
Mark Story authored November 19, 2012

Showing 60 changed files with 26 additions and 614 deletions. Show diff stats Hide diff stats

  1. 2  en/appendices/cakephp-development-process.rst
  2. 2  en/cakephp-overview/understanding-model-view-controller.rst
  3. 2  en/cakephp-overview/where-to-get-help.rst
  4. 2  en/console-and-shells/acl-shell.rst
  5. 2  en/console-and-shells/code-generation-with-bake.rst
  6. 2  en/console-and-shells/testsuite-shell.rst
  7. 2  en/contributing/tickets.rst
  8. 2  en/controllers/pages-controller.rst
  9. 14  en/core-libraries/events.rst
  10. 3  en/core-libraries/global-constants-and-functions.rst
  11. 9  en/core-libraries/internationalization-and-localization.rst
  12. 13  en/core-libraries/logging.rst
  13. 2  en/core-libraries/toc-behaviors.rst
  14. 2  en/core-libraries/toc-components.rst
  15. 2  en/core-libraries/toc-general-purpose.rst
  16. 2  en/core-libraries/toc-helpers.rst
  17. 2  en/core-libraries/toc-utilities.rst
  18. 18  en/core-utility-libraries/app.rst
  19. 20  en/core-utility-libraries/email.rst
  20. 21  en/core-utility-libraries/hash.rst
  21. 13  en/core-utility-libraries/httpsocket.rst
  22. 2  en/core-utility-libraries/inflector.rst
  23. 13  en/core-utility-libraries/number.rst
  24. 2  en/core-utility-libraries/router.rst
  25. 4  en/core-utility-libraries/sanitize.rst
  26. 6  en/core-utility-libraries/security.rst
  27. 27  en/core-utility-libraries/set.rst
  28. 13  en/core-utility-libraries/string.rst
  29. 14  en/core-utility-libraries/time.rst
  30. 20  en/core-utility-libraries/xml.rst
  31. 19  en/development/configuration.rst
  32. 5  en/development/debugging.rst
  33. 8  en/development/dispatch-filters.rst
  34. 4  en/development/errors.rst
  35. 12  en/development/exceptions.rst
  36. 5  en/development/rest.rst
  37. 47  en/development/routing.rst
  38. 13  en/development/sessions.rst
  39. 39  en/development/testing.rst
  40. 2  en/development/vendor-packages.rst
  41. 1  en/getting-started/cakephp-conventions.rst
  42. 2  en/getting-started/cakephp-folder-structure.rst
  43. 2  en/getting-started/cakephp-structure.rst
  44. 1  en/installation/advanced-installation.rst
  45. 6  en/models/additional-methods-and-properties.rst
  46. 26  en/models/associations-linking-models-together.rst
  47. 17  en/models/behaviors.rst
  48. 7  en/models/callback-methods.rst
  49. 61  en/models/data-validation.rst
  50. 10  en/models/datasources.rst
  51. 4  en/models/deleting-data.rst
  52. 10  en/models/model-attributes.rst
  53. 36  en/models/retrieving-your-data.rst
  54. 29  en/models/saving-your-data.rst
  55. 3  en/models/transactions.rst
  56. 12  en/models/virtual-fields.rst
  57. 13  en/views/helpers.rst
  58. 3  en/views/json-and-xml-views.rst
  59. 2  en/views/media-view.rst
  60. 3  en/views/themes.rst
2  en/appendices/cakephp-development-process.rst
Source Rendered
@@ -53,4 +53,4 @@ on irc.freenode.net.
53 53
 
54 54
 .. meta::
55 55
     :title lang=en: CakePHP Development Process
56  
-    :keywords lang=en: maintenance branch,community interaction,community feature,necessary feature,stable release,ticket system,advanced feature,power users,feature set,chat irc,leading edge,router,new features,members,attempt,development branches,branch development
  56
+    :keywords lang=en: maintenance branch,community interaction,community feature,necessary feature,stable release,ticket system,advanced feature,power users,feature set,chat irc,leading edge,router,new features,members,attempt,development branches,branch development
2  en/cakephp-overview/understanding-model-view-controller.rst
Source Rendered
@@ -107,4 +107,4 @@ To get started on your first CakePHP application,
107 107
 
108 108
 .. meta::
109 109
     :title lang=en: Understanding Model-View-Controller
110  
-    :keywords lang=en: model view controller,model layer,formatted result,model objects,music documents,business logic,text representation,first glance,retrieving data,software design,html page,videos music,new friends,interaction,cakephp,interface,photo,presentation,mvc,photos
  110
+    :keywords lang=en: model view controller,model layer,formatted result,model objects,music documents,business logic,text representation,first glance,retrieving data,software design,html page,videos music,new friends,interaction,cakephp,interface,photo,presentation,mvc,photos
2  en/cakephp-overview/where-to-get-help.rst
Source Rendered
@@ -96,4 +96,4 @@ and solved questions as well.
96 96
 .. meta::
97 97
     :title lang=en: Where to Get Help
98 98
     :description lang=en: Where to get help with CakePHP: The official CakePHP website, The Cookbook, The Bakery, The API, in the test cases, the IRC channel, The CakePHP Google Group or CakePHP Questions.
99  
-    :keywords lang=en: cakephp,cakephp help,help with cakephp,where to get help,cakephp irc,cakephp questions,cakephp api,cakephp test cases,open source projects,channel irc,code reference,irc channel,developer tools,test case,bakery
  99
+    :keywords lang=en: cakephp,cakephp help,help with cakephp,where to get help,cakephp irc,cakephp questions,cakephp api,cakephp test cases,open source projects,channel irc,code reference,irc channel,developer tools,test case,bakery
2  en/console-and-shells/acl-shell.rst
Source Rendered
@@ -79,4 +79,4 @@ allows you to return only a portion of the requested tree::
79 79
 
80 80
 .. meta::
81 81
     :title lang=en: ACL Shell
82  
-    :keywords lang=en: record style,style reference,acl,database tables,group id,notations,alias,privilege,node,privileges,shell,databases
  82
+    :keywords lang=en: record style,style reference,acl,database tables,group id,notations,alias,privilege,node,privileges,shell,databases
2  en/console-and-shells/code-generation-with-bake.rst
Source Rendered
@@ -230,4 +230,4 @@ and add the files there.
230 230
 
231 231
 .. meta::
232 232
     :title lang=en: Code Generation with Bake
233  
-    :keywords lang=en: command line interface,functional application,atabase,database configuration,bash script,basic ingredients,roject,odel,path path,code generation,scaffolding,windows users,configuration file,few minutes,config,iew,shell,models,running,mysql
  233
+    :keywords lang=en: command line interface,functional application,atabase,database configuration,bash script,basic ingredients,roject,odel,path path,code generation,scaffolding,windows users,configuration file,few minutes,config,iew,shell,models,running,mysql
2  en/console-and-shells/testsuite-shell.rst
Source Rendered
@@ -14,4 +14,4 @@ For more information on basic usage of the test shell see
14 14
 
15 15
 .. meta::
16 16
     :title lang=en: Test Shell
17  
-    :keywords lang=en: cakephp testing,test shell,testsuite,command line
  17
+    :keywords lang=en: cakephp testing,test shell,testsuite,command line
2  en/contributing/tickets.rst
Source Rendered
@@ -51,4 +51,4 @@ CakePHP team will take the following actions:
51 51
 
52 52
 .. meta::
53 53
     :title lang=en: Tickets
54  
-    :keywords lang=en: bug reporting system,code snippet,reporting security,private mailing,release announcement,google,ticket system,core team,security issue,bug tracker,irc channel,test cases,support questions,bug report,security issues,bug reports,exploits,lighthouse,vulnerability,repository
  54
+    :keywords lang=en: bug reporting system,code snippet,reporting security,private mailing,release announcement,google,ticket system,core team,security issue,bug tracker,irc channel,test cases,support questions,bug report,security issues,bug reports,exploits,lighthouse,vulnerability,repository
2  en/controllers/pages-controller.rst
Source Rendered
@@ -25,4 +25,4 @@ created in your ``app/Controller/`` folder. You can also copy the file from
25 25
 
26 26
 .. meta::
27 27
     :title lang=en: The Pages Controller
28  
-    :keywords lang=en: pages controller,default controller,lib,cakephp,ships,php,file folder
  28
+    :keywords lang=en: pages controller,default controller,lib,cakephp,ships,php,file folder
14  en/core-libraries/events.rst
Source Rendered
@@ -55,7 +55,6 @@ Dispatching events
55 55
 So back to our example, we would have an `Order` model that will manage the buying logic,
56 56
 and probably a `place` method to save the order details and do any other logic::
57 57
 
58  
-    <?php
59 58
     // Cart/Model/Order.php
60 59
     class Order extends AppModel {
61 60
 
@@ -77,7 +76,6 @@ about sending emails, and may not even have the inventory data to decrement the
77 76
 item from it, and definitely tracking usage statistics is not the best place to
78 77
 do it. So we need another solution, let's rewrite that using the event manager::
79 78
 
80  
-    <?php
81 79
     // Cart/Model/Order.php
82 80
     App::uses('CakeEvent', 'Event');
83 81
     class Order extends AppModel {
@@ -106,7 +104,6 @@ and to dispatch events you use :php:meth:`CakeEventManager::dispatch()` which
106 104
 receives an instance of the :php:class:`CakeEvent` class. Let's dissect now the
107 105
 process of dispatching an event::
108 106
 
109  
-    <?php
110 107
     new CakeEvent('Model.Order.afterPlace', $this, array(
111 108
         'order' => $order
112 109
     ));
@@ -145,7 +142,6 @@ For simplicity's sake, let's imagine we know in the plugin what the callbacks
145 142
 are available in the controller, and say this controller is responsible for
146 143
 attaching them. The possible code would look like this::
147 144
 
148  
-    <?php
149 145
     // Listeners configured somewhere else, maybe a config file:
150 146
     Configure::write('Order.afterPlace', array(
151 147
         'email-sending' => 'EmailSender::sendBuyEmail',
@@ -199,7 +195,6 @@ statistics. It would be natural to pass an instance of this class as a callback,
199 195
 instead of implementing a custom static function or converting any other workaround
200 196
 to trigger methods in this class. A listener is created as follows::
201 197
 
202  
-    <?php
203 198
     App::uses('CakeEventListener', 'Event');
204 199
     class UserStatistic implements CakeEventListener {
205 200
 
@@ -246,7 +241,6 @@ executed with a `FIFO` policy, the first listener method to be attached is calle
246 241
 first and so on. You set priorities using the `attach` method for callbacks, and
247 242
 declaring it in the `implementedEvents` function for event listeners::
248 243
 
249  
-    <?php
250 244
     // Setting priority for a callback
251 245
     $callback = array($this, 'doSomething');
252 246
     $this->getEventManager()->attach($callback, 'Model.Order.afterPlace', array('priority' => 2));
@@ -278,7 +272,6 @@ In order to toggle this option you have to add the `passParams` option to the
278 272
 third argument of the `attach` method, or declare it in the `implementedEvents`
279 273
 returned array similar to what you do with priorities::
280 274
 
281  
-    <?php
282 275
     // Setting priority for a callback
283 276
     $callback = array($this, 'doSomething');
284 277
     $this->getEventManager()->attach($callback, 'Model.Order.afterPlace', array('passParams' => true));
@@ -300,7 +293,6 @@ In the above code the `doSomething` function and `updateBuyStatistic` method wil
300 293
 receive `$orderData` instead of the `$event` object. This is so, because in our
301 294
 previous example we trigger the `Model.Order.afterPlace` event with some data::
302 295
 
303  
-    <?php
304 296
     $this->getEventManager()->dispatch(new CakeEvent('Model.Order.afterPlace', $this, array(
305 297
         'order' => $order
306 298
     )));
@@ -322,7 +314,6 @@ the code detects it cannot proceed any further.
322 314
 In order to stop events you can either return `false` in your callbacks or call
323 315
 the `stopPropagation` method on the event object::
324 316
 
325  
-    <?php
326 317
     public function doSomething($event) {
327 318
         // ...
328 319
         return false; // stops the event
@@ -342,7 +333,6 @@ we had a `beforePlace` stopping the event would have a valid meaning.
342 333
 
343 334
 To check if an event was stopped, you call the `isStopped()` method in the event object::
344 335
 
345  
-    <?php
346 336
     public function place($order) {
347 337
         $event = new CakeEvent('Model.Order.beforePlace', $this, array('order' => $order));
348 338
         $this->getEventManager()->dispatch($event);
@@ -370,7 +360,6 @@ the $order data.
370 360
 Event results can be altered either using the event object result property
371 361
 directly or returning the value in the callback itself::
372 362
 
373  
-    <?php
374 363
     // A listener callback
375 364
     public function doSomething($event) {
376 365
         // ...
@@ -410,7 +399,6 @@ If for any reason you want to remove any callback from the event manager just ca
410 399
 the :php:meth:`CakeEventManager::detach()` method using as arguments the first two
411 400
 params you used for attaching it::
412 401
 
413  
-    <?php
414 402
     // Attaching a function
415 403
     $this->getEventManager()->attach(array($this, 'doSomething'), 'My.event');
416 404
 
@@ -459,7 +447,6 @@ the local callbacks will get called in the respective priority order.
459 447
 Accessing the global event manager is as easy as calling a static function,
460 448
 the following example will attach a global event to the `beforePlace` event::
461 449
 
462  
-    <?php
463 450
     // In any configuration file or piece of code that executes before the event
464 451
     App::uses('CakeEventManager', 'Event');
465 452
     CakeEventManager::instance()->attach($aCallback, 'Model.Order.beforePlace');
@@ -476,7 +463,6 @@ to prevent some bugs. Remember that extreme flexibility implies extreme complexi
476 463
 Consider this callback that wants to listen for all Model beforeFinds but in
477 464
 reality, it cannot do its logic if the model is the Cart::
478 465
 
479  
-    <?php
480 466
     App::uses('CakeEventManager', 'Event');
481 467
     CakeEventManager::instance()->attach('myCallback', 'Model.beforeFind');
482 468
 
3  en/core-libraries/global-constants-and-functions.rst
Source Rendered
@@ -28,7 +28,6 @@ such as debugging and translating content.
28 28
     ``sprintf()``.  You can supply additional arguments to replace
29 29
     placeholders in your string::
30 30
 
31  
-        <?php
32 31
         __('You have %s unread messages', $number);
33 32
 
34 33
     .. note::
@@ -308,4 +307,4 @@ Timing Definition Constants
308 307
 
309 308
 .. meta::
310 309
     :title lang=en: Global Constants and Functions
311  
-    :keywords lang=en: internationalization and localization,global constants,example config,array php,convenience functions,core libraries,component classes,optional number,global functions,string string,core classes,format strings,unread messages,placeholders,useful functions,sprintf,arrays,parameters,existence,translations
  310
+    :keywords lang=en: internationalization and localization,global constants,example config,array php,convenience functions,core libraries,component classes,optional number,global functions,string string,core classes,format strings,unread messages,placeholders,useful functions,sprintf,arrays,parameters,existence,translations
9  en/core-libraries/internationalization-and-localization.rst
Source Rendered
@@ -82,7 +82,6 @@ Remember that po files are useful for short messages, if you find
82 82
 you want to translate long paragraphs, or even whole pages - you
83 83
 should consider implementing a different solution. e.g.::
84 84
 
85  
-    <?php
86 85
     // App Controller Code.
87 86
     public function beforeFilter() {
88 87
         $locale = Configure::read('Config.language');
@@ -94,7 +93,6 @@ should consider implementing a different solution. e.g.::
94 93
 
95 94
 or::
96 95
 
97  
-    <?php
98 96
     // View code
99 97
     echo $this->element(Configure::read('Config.language') . '/tos');
100 98
 
@@ -107,7 +105,6 @@ follow a few conventions.
107 105
 Instead of __() and __n() you will have to use __d() and __dn(). The D means 
108 106
 domain. So if you have a plugin called 'DebugKit' you would have to do this::
109 107
 
110  
-    <?php
111 108
     __d('debug_kit', 'My example text');
112 109
 
113 110
 Using the underscored syntax is important, if you don't use it CakePHP won't
@@ -133,7 +130,6 @@ Localization in CakePHP
133 130
 To change or set the language for your application, all you need to
134 131
 do is the following::
135 132
 
136  
-    <?php
137 133
     Configure::write('Config.language', 'fre');
138 134
 
139 135
 This tells Cake which locale to use (if you use a regional locale, such as
@@ -146,13 +142,11 @@ in fact anytime at all before you want a message in a different language.  To
146 142
 set the language for the current user, you can store the setting in the Session
147 143
 object, like this::
148 144
 
149  
-    <?php
150 145
     $this->Session->write('Config.language', 'fre');
151 146
 
152 147
 At the beginning of each request in your controller's ``beforeFilter`` you 
153 148
 should configure ``Configure`` as well::
154 149
 
155  
-    <?php
156 150
     class AppController extends Controller {
157 151
         public function beforeFilter() {
158 152
             Configure::write('Config.language', $this->Session->read('Config.language'));
@@ -198,7 +192,6 @@ CakePHP will automatically extract the validation error when you are using the
198 192
 :doc:`i18n console task </console-and-shells>`. By default, the default domain is used.
199 193
 This can be overwritten by setting the ``$validationDomain`` property in your model::
200 194
 
201  
-    <?php
202 195
     class User extends AppModel {
203 196
 
204 197
         public $validationDomain = 'validation_errors';
@@ -207,7 +200,6 @@ This can be overwritten by setting the ``$validationDomain`` property in your mo
207 200
 Additional parameters defined in the validation rule are passed to the translation
208 201
 function. This allows you to create dynamic validation messages::
209 202
 
210  
-    <?php
211 203
     class User extends AppModel {
212 204
 
213 205
         public $validationDomain = 'validation';
@@ -224,7 +216,6 @@ function. This allows you to create dynamic validation messages::
224 216
 
225 217
 Which will do the following internal call::
226 218
 
227  
-    <?php
228 219
     __d('validation', 'Username should be between %d and %d characters', array(2, 10));
229 220
 
230 221
 .. meta::
13  en/core-libraries/logging.rst
Source Rendered
@@ -32,7 +32,6 @@ configured ``CakeLog`` will attempt to load Configuring log streams
32 32
 is done by calling ``CakeLog::config()``. Configuring our
33 33
 DataBaseLogger would look like::
34 34
     
35  
-    <?php
36 35
     // for app/Lib
37 36
     CakeLog::config('otherFile', array(
38 37
         'engine' => 'DatabaseLogger',
@@ -51,7 +50,6 @@ When configuring a log stream the ``engine`` parameter is used to
51 50
 locate and load the log handler. All of the other configuration
52 51
 properties are passed to the log stream's constructor as an array.::
53 52
 
54  
-    <?php
55 53
     App::uses('CakeLogInterface', 'Log');
56 54
 
57 55
     class DatabaseLogger implements CakeLogInterface {
@@ -113,7 +111,6 @@ message is stored in. If a type is not supplied, LOG\_ERROR is used
113 111
 which writes to the error log. The default log location is
114 112
 ``app/tmp/logs/$type.log``::
115 113
 
116  
-    <?php
117 114
     // Executing this inside a CakePHP class
118 115
     $this->log("Something didn't work!");
119 116
     
@@ -124,7 +121,6 @@ You can specify a custom log name using the first parameter. The
124 121
 default built-in FileLog class will treat this log name as the file
125 122
 you wish to write logs to::
126 123
 
127  
-    <?php
128 124
     // called statically
129 125
     CakeLog::write('activity', 'A special message for activity logging');
130 126
     
@@ -138,7 +134,6 @@ You can configure additional/alternate FileLog locations using
138 134
 :php:meth:`CakeLog::config()`. FileLog accepts a ``path`` which allows for
139 135
 custom paths to be used::
140 136
 
141  
-    <?php
142 137
     CakeLog::config('custom_path', array(
143 138
         'engine' => 'FileLog',
144 139
         'path' => '/path/to/custom/place/'
@@ -152,14 +147,12 @@ Writing to logs
152 147
 Writing to the log files can be done in 2 different ways. The first
153 148
 is to use the static :php:meth:`CakeLog::write()` method::
154 149
 
155  
-    <?php
156 150
     CakeLog::write('debug', 'Something did not work');
157 151
 
158 152
 The second is to use the log() shortcut function available on any
159 153
 class that extends ``Object``. Calling log() will internally call
160 154
 CakeLog::write()::
161 155
 
162  
-    <?php
163 156
     // Executing this inside a CakePHP class:
164 157
     $this->log("Something did not work!", 'debug');
165 158
 
@@ -188,7 +181,6 @@ the log messages will be directed to those loggers.  If a log message is written
188 181
 to an unknown scope, loggers that handle that level of message will log the
189 182
 message. For example::
190 183
 
191  
-    <?php
192 184
     // configure tmp/logs/shops.log to receive all types (log levels), but only
193 185
     // those with `orders` and `payments` scope
194 186
     CakeLog::config('shops', array(
@@ -260,14 +252,12 @@ CakeLog API
260 252
     To append the additional levels 'user0' and 'user1' to the default
261 253
     log levels use::
262 254
 
263  
-        <?php
264 255
         CakeLog::levels(array('user0', 'user1'));
265 256
         // or
266 257
         CakeLog::levels(array('user0', 'user1'), true);
267 258
 
268 259
     Calling ``CakeLog::levels()`` will result in::
269 260
 
270  
-        <?php
271 261
         array(
272 262
             0 => 'emergency',
273 263
             1 => 'alert',
@@ -279,12 +269,10 @@ CakeLog API
279 269
     To set/replace an existing configuration, pass an array with the second
280 270
     argument set to false::
281 271
 
282  
-        <?php
283 272
         CakeLog::levels(array('user0', 'user1'), false);
284 273
 
285 274
     Calling ``CakeLog::levels()`` will result in::
286 275
 
287  
-        <?php
288 276
         array(
289 277
             0 => 'user0',
290 278
             1 => 'user1',
@@ -296,7 +284,6 @@ CakeLog API
296 284
 
297 285
     Resets log levels to their original values::
298 286
 
299  
-        <?php
300 287
         array(
301 288
             'emergency' => LOG_EMERG,
302 289
             'alert'     => LOG_ALERT,
2  en/core-libraries/toc-behaviors.rst
Source Rendered
@@ -7,4 +7,4 @@ Behaviors
7 7
     behaviors/acl
8 8
     behaviors/containable
9 9
     behaviors/translate
10  
-    behaviors/tree
  10
+    behaviors/tree
2  en/core-libraries/toc-components.rst
Source Rendered
@@ -11,4 +11,4 @@ Components
11 11
     components/request-handling
12 12
     components/pagination
13 13
     components/security-component
14  
-    components/sessions
  14
+    components/sessions
2  en/core-libraries/toc-general-purpose.rst
Source Rendered
@@ -7,4 +7,4 @@ General Purpose
7 7
     global-constants-and-functions
8 8
     ../core-utility-libraries/app
9 9
     events
10  
-    collections
  10
+    collections
2  en/core-libraries/toc-helpers.rst
Source Rendered
@@ -13,4 +13,4 @@ Helpers
13 13
     helpers/rss
14 14
     helpers/session
15 15
     helpers/text
16  
-    helpers/time
  16
+    helpers/time
2  en/core-libraries/toc-utilities.rst
Source Rendered
@@ -19,4 +19,4 @@ Utilities
19 19
     ../core-utility-libraries/hash
20 20
     ../core-utility-libraries/set
21 21
     ../core-utility-libraries/string
22  
-    ../core-utility-libraries/xml
  22
+    ../core-utility-libraries/xml
18  en/core-utility-libraries/app.rst
Source Rendered
@@ -73,7 +73,6 @@ Loading classes in plugins works much the same as loading app and
73 73
 core classes except you must specify the plugin you are loading
74 74
 from::
75 75
 
76  
-    <?php
77 76
     // Load the class Comment in app/Plugin/PluginName/Model/Comment.php
78 77
     App::uses('Comment', 'PluginName.Model');
79 78
 
@@ -90,14 +89,12 @@ Finding paths to packages using App::path()
90 89
 
91 90
     Used to read information stored path::
92 91
 
93  
-        <?php
94 92
         // return the model paths in your application
95 93
         App::path('Model');
96 94
 
97 95
     This can be done for all packages that are apart of your application. You
98 96
     can also fetch paths for a plugin::
99 97
 
100  
-        <?php
101 98
         // return the component paths in DebugKit
102 99
         App::path('Component', 'DebugKit');
103 100
 
@@ -115,7 +112,6 @@ Finding paths to packages using App::path()
115 112
 
116 113
     Used for finding the path to a package inside CakePHP::
117 114
 
118  
-        <?php
119 115
         // Get the path to Cache engines.
120 116
         App::core('Cache/Engine');
121 117
 
@@ -143,7 +139,6 @@ Adding paths for App to find packages in
143 139
 
144 140
     Usage::
145 141
 
146  
-        <?php
147 142
         //will setup a new search path for the Model package
148 143
         App::build(array('Model' => array('/a/full/path/to/models/'))); 
149 144
 
@@ -159,7 +154,6 @@ Adding paths for App to find packages in
159 154
 
160 155
     Examples::
161 156
 
162  
-        <?php
163 157
         App::build(array('controllers' => array('/full/path/to/controllers')));
164 158
         //becomes 
165 159
         App::build(array('Controller' => array('/full/path/to/Controller')));
@@ -181,7 +175,6 @@ Add new packages to an application
181 175
 when you want to add new top level packages or, sub-packages to your
182 176
 application::
183 177
 
184  
-    <?php
185 178
     App::build(array(
186 179
         'Service' => array('%s' . 'Service' . DS)
187 180
     ), App::REGISTER);
@@ -207,7 +200,6 @@ Finding which objects CakePHP knows about
207 200
 
208 201
     Example usage::
209 202
 
210  
-        <?php
211 203
         //returns array('DebugKit', 'Blog', 'User');
212 204
         App::objects('plugin');
213 205
 
@@ -216,7 +208,6 @@ Finding which objects CakePHP knows about
216 208
 
217 209
     You can also search only within a plugin's objects by using the plugin dot syntax.::
218 210
 
219  
-        <?php
220 211
         // returns array('MyPluginPost', 'MyPluginComment');
221 212
         App::objects('MyPlugin.Model');
222 213
 
@@ -237,7 +228,6 @@ Locating plugins
237 228
     Plugins can be located with App as well. Using ``App::pluginPath('DebugKit');``
238 229
     for example, will give you the full path to the DebugKit plugin::
239 230
 
240  
-        <?php
241 231
         $path = App::pluginPath('DebugKit');
242 232
 
243 233
 Locating themes
@@ -269,7 +259,6 @@ Including files with App::import()
269 259
 
270 260
     ::
271 261
 
272  
-        <?php
273 262
         // The same as require('Controller/UsersController.php');
274 263
         App::import('Controller', 'Users');
275 264
         
@@ -320,14 +309,12 @@ Loading Vendor Files
320 309
 You can use ``App::uses()`` to load classes in vendors directories. It follows
321 310
 the same conventions as loading other files::
322 311
 
323  
-    <?php
324 312
     // Load the class Geshi in app/Vendor/Geshi.php
325 313
     App::uses('Geshi', 'Vendor');
326 314
 
327 315
 To load classes in subdirectories, you'll need to add those paths 
328 316
 with ``App::build()``::
329 317
 
330  
-    <?php
331 318
     // Load the class ClassInSomePackage in app/Vendor/SomePackage/ClassInSomePackage.php
332 319
     App::build(array('Vendor' => array(APP . 'Vendor' . DS . 'SomePackage')));
333 320
     App::uses('ClassInSomePackage', 'Vendor');
@@ -340,7 +327,6 @@ any of the vendor folders.
340 327
 
341 328
 To load **app/Vendor/geshi.php**::
342 329
 
343  
-    <?php
344 330
     App::import('Vendor', 'geshi');
345 331
 
346 332
 .. note::
@@ -350,17 +336,14 @@ To load **app/Vendor/geshi.php**::
350 336
 
351 337
 To load **app/Vendor/flickr/flickr.php**::
352 338
 
353  
-    <?php
354 339
     App::import('Vendor', 'flickr/flickr');
355 340
 
356 341
 To load **app/Vendor/some.name.php**::
357 342
 
358  
-    <?php
359 343
     App::import('Vendor', 'SomeName', array('file' => 'some.name.php'));
360 344
 
361 345
 To load **app/Vendor/services/well.named.php**::
362 346
 
363  
-    <?php
364 347
     App::import('Vendor', 'WellNamed', array('file' => 'services' . DS . 'well.named.php'));
365 348
 
366 349
 It wouldn't make a difference if your vendor files are inside your /vendors 
@@ -368,7 +351,6 @@ directory. Cake will automatically find it.
368 351
 
369 352
 To load **vendors/vendorName/libFile.php**::
370 353
 
371  
-    <?php
372 354
     App::import('Vendor', 'aUniqueIdentifier', array('file' => 'vendorName' . DS . 'libFile.php'));
373 355
 
374 356
 App Init/Load/Shutdown Methods
20  en/core-utility-libraries/email.rst
Source Rendered
@@ -17,13 +17,11 @@ Basic usage
17 17
 
18 18
 First of all, you should ensure the class is loaded using :php:meth:`App::uses()`::
19 19
 
20  
-    <?php
21 20
     App::uses('CakeEmail', 'Network/Email');
22 21
 
23 22
 Using CakeEmail is similar to using :php:class:`EmailComponent`. But instead of
24 23
 using attributes you must use methods. Example::
25 24
 
26  
-    <?php
27 25
     $email = new CakeEmail();
28 26
     $email->from(array('me@example.com' => 'My Site'));
29 27
     $email->to('you@example.com');
@@ -33,7 +31,6 @@ using attributes you must use methods. Example::
33 31
 To simplify things, all of the setter methods return the instance of class.
34 32
 You can re-write the above code as::
35 33
 
36  
-    <?php
37 34
     $email = new CakeEmail();
38 35
     $email->from(array('me@example.com' => 'My Site'))
39 36
         ->to('you@example.com')
@@ -46,7 +43,6 @@ Choosing the sender
46 43
 When sending email on behalf of other people it's often a good idea to define the
47 44
 original sender using the Sender header.  You can do so using ``sender()``::
48 45
 
49  
-    <?php
50 46
     $email = new CakeEmail();
51 47
     $email->sender('app@example.com', 'MyApp emailer');
52 48
 
@@ -69,7 +65,6 @@ The ``app/Config/email.php.default`` has an example of this file.
69 65
 config. If you have dynamic data to put in the configs, you can use the
70 66
 constructor to do that::
71 67
 
72  
-    <?php
73 68
     class EmailConfig {
74 69
         public function __construct() {
75 70
             // Do conditional assignments here.
@@ -83,7 +78,6 @@ load an array of configs.
83 78
 To load a config from ``EmailConfig`` you can use the ``config()`` method or pass it
84 79
 to the constructor of ``CakeEmail``::
85 80
 
86  
-    <?php
87 81
     $email = new CakeEmail();
88 82
     $email->config('default');
89 83
 
@@ -93,7 +87,6 @@ to the constructor of ``CakeEmail``::
93 87
 Instead of passing a string which matches the configuration name in ``EmailConfig``
94 88
 you can also just load an array of configs::
95 89
 
96  
-    <?php
97 90
     $email = new CakeEmail();
98 91
     $email->config(array('from' => 'me@example.org', 'transport' => 'MyCustom'));
99 92
 
@@ -103,7 +96,6 @@ you can also just load an array of configs::
103 96
 You can configure SSL SMTP servers, like GMail. To do so, put the ``'ssl://'``
104 97
 at prefix in the host and configure the port value accordingly.  Example::
105 98
 
106  
-    <?php
107 99
     class EmailConfig {
108 100
         public $gmail = array(
109 101
             'host' => 'ssl://smtp.gmail.com',
@@ -121,7 +113,6 @@ at prefix in the host and configure the port value accordingly.  Example::
121 113
 
122 114
 As of 2.3.0 you can also enable TLS SMTP using the ``tls`` option::
123 115
 
124  
-    <?php
125 116
     class EmailConfig {
126 117
         public $gmail = array(
127 118
             'host' => 'smtp.gmail.com',
@@ -208,7 +199,6 @@ The templates for emails reside in a special folder in your applications
208 199
 ``View`` directory.  Email views can also use layouts, and elements just like
209 200
 normal views::
210 201
 
211  
-    <?php
212 202
     $email = new CakeEmail();
213 203
     $email->template('welcome', 'fancy')
214 204
         ->emailFormat('html')
@@ -220,7 +210,6 @@ The above would use ``app/View/Emails/html/welcome.ctp`` for the view,
220 210
 and ``app/View/Layouts/Emails/html/fancy.ctp`` for the layout. You can
221 211
 send multipart templated email messages as well::
222 212
 
223  
-    <?php
224 213
     $email = new CakeEmail();
225 214
     $email->template('welcome', 'fancy')
226 215
         ->emailFormat('both')
@@ -240,7 +229,6 @@ When sending templated emails you have the option of sending either
240 229
 
241 230
 You can set view variables with ``CakeEmail::viewVars()``::
242 231
 
243  
-    <?php
244 232
     $email = new CakeEmail('templated');
245 233
     $email->viewVars(array('value' => 12345));
246 234
 
@@ -252,7 +240,6 @@ You can use helpers in emails as well, much like you can in normal view files.
252 240
 By default only the :php:class:`HtmlHelper` is loaded.  You can load additional
253 241
 helpers using the ``helpers()`` method::
254 242
 
255  
-    <?php
256 243
     $email->helpers(array('Html', 'Custom', 'Text'));
257 244
 
258 245
 When setting helpers be sure to include 'Html' or it will be removed from the
@@ -261,7 +248,6 @@ helpers loaded in your email template.
261 248
 If you want to send email using templates in a plugin you can use the familiar
262 249
 :term:`plugin syntax` to do so::
263 250
 
264  
-    <?php
265 251
     $email = new CakeEmail();
266 252
     $email->template('Blog.new_comment', 'Blog.auto_message');
267 253
 
@@ -271,7 +257,6 @@ In some cases, you might need to override the default template provided by plugi
271 257
 You can do this using themes by telling CakeEmail to use appropriate theme using
272 258
 ``CakeEmail::theme()`` method::
273 259
 
274  
-    <?php
275 260
     $email = new CakeEmail();
276 261
     $email->template('Blog.new_comment', 'Blog.auto_message');
277 262
     $email->theme('TestTheme');
@@ -299,7 +284,6 @@ you want the filenames to appear in the recipient's mail client:
299 284
    photo.png, not some_hash.png.
300 285
 4. Nested arrays::
301 286
 
302  
-    <?php
303 287
     $email->attachments(array(
304 288
         'photo.png' => array(
305 289
             'file' => '/full/some_hash.png',
@@ -339,7 +323,6 @@ systems (like SwiftMailer). To create your transport, first create the file
339 323
 ``app/Lib/Network/Email/ExampleTransport.php`` (where Example is the name of your
340 324
 transport). To start off your file should look like::
341 325
 
342  
-    <?php
343 326
     App::uses('AbstractTransport', 'Network/Email');
344 327
 
345 328
     class ExampleTransport extends AbstractTransport {
@@ -359,7 +342,6 @@ If you need to call additional methods on the transport before send, you can use
359 342
 :php:meth:`CakeEmail::transportClass()` to get an instance of the transport.
360 343
 Example::
361 344
 
362  
-    <?php
363 345
     $yourInstance = $email->transport('your')->transportClass();
364 346
     $yourInstance->myCustomMethod();
365 347
     $email->send();
@@ -376,7 +358,6 @@ You can create your configuration in ``EmailConfig``, or use an array with all
376 358
 options that you need and use the static method ``CakeEmail::deliver()``.
377 359
 Example::
378 360
 
379  
-    <?php
380 361
     CakeEmail::deliver('you@example.com', 'Subject', 'Message', array('from' => 'me@example.com'));
381 362
 
382 363
 This method will send an email to you@example.com, from me@example.com with
@@ -408,7 +389,6 @@ When sending emails within a CLI script (Shells, Tasks, ...) you should manually
408 389
 set the domain name for CakeEmail to use. It will serve as the host name for the
409 390
 message id (since there is no host name in a CLI environment)::
410 391
 
411  
-    <?php
412 392
     $email->domain('www.example.org');
413 393
     // Results in message ids like ``<UUID@www.example.org>`` (valid)
414 394
     // instead of `<UUID@>`` (invalid)
21  en/core-utility-libraries/hash.rst
Source Rendered
@@ -81,7 +81,6 @@ elements you can use attribute matching with methods like ``extract()``.
81 81
     structures.  Instead you use path expressions to qualify which elements you
82 82
     want returned ::
83 83
 
84  
-        <?php
85 84
         // Common Usage:
86 85
         $users = $this->User->find("all");
87 86
         $results = Hash::extract($users, '{n}.User.id');
@@ -95,7 +94,6 @@ elements you can use attribute matching with methods like ``extract()``.
95 94
     Inserts $data into an array as defined by $path. This method only supports
96 95
     the expression types of :ref:`hash-path-syntax`::
97 96
 
98  
-        <?php
99 97
         $a = array(
100 98
             'pages' => array('name' => 'page')
101 99
         );
@@ -126,7 +124,6 @@ elements you can use attribute matching with methods like ``extract()``.
126 124
     Removes all elements from an array that match $path. This method supports
127 125
     all the expression elements of :ref:`hash-path-syntax`::
128 126
 
129  
-        <?php
130 127
         $a = array(
131 128
             'pages' => array('name' => 'page'),
132 129
             'files' => array('name' => 'files')
@@ -155,7 +152,6 @@ elements you can use attribute matching with methods like ``extract()``.
155 152
     You can optionally group the values by what is obtained when following the
156 153
     path specified in $groupPath.::
157 154
 
158  
-        <?php
159 155
         $a = array(
160 156
             array(
161 157
                 'User' => array(
@@ -256,7 +252,6 @@ elements you can use attribute matching with methods like ``extract()``.
256 252
     the first value will be used as a format string, for values extracted by the
257 253
     other paths::
258 254
 
259  
-        <?php
260 255
         $result = Hash::combine(
261 256
             $a,
262 257
             '{n}.User.id',
@@ -297,7 +292,6 @@ elements you can use attribute matching with methods like ``extract()``.
297 292
     Returns a series of values extracted from an array, formatted with a
298 293
     format string::
299 294
 
300  
-        <?php
301 295
         $data = array(
302 296
             array(
303 297
                 'Person' => array(
@@ -355,7 +349,6 @@ elements you can use attribute matching with methods like ``extract()``.
355 349
     Determines if one Hash or array contains the exact keys and values
356 350
     of another::
357 351
 
358  
-        <?php
359 352
         $a = array(
360 353
             0 => array('name' => 'main'),
361 354
             1 => array('name' => 'about')
@@ -380,7 +373,6 @@ elements you can use attribute matching with methods like ``extract()``.
380 373
 
381 374
     Checks if a particular path is set in an array::
382 375
 
383  
-        <?php
384 376
         $set = array(
385 377
             'My Index 1' => array('First' => 'The first item')
386 378
         );
@@ -416,7 +408,6 @@ elements you can use attribute matching with methods like ``extract()``.
416 408
     custom $callback to filter the array elements. You callback should return
417 409
     ``false`` to remove elements from the resulting array::
418 410
 
419  
-        <?php
420 411
         $data = array(
421 412
             '0',
422 413
             false,
@@ -446,7 +437,6 @@ elements you can use attribute matching with methods like ``extract()``.
446 437
 
447 438
     Collapses a multi-dimensional array into a single dimension::
448 439
 
449  
-        <?php
450 440
         $arr = array(
451 441
             array(
452 442
                 'Post' => array('id' => '1', 'title' => 'First Post'),
@@ -478,7 +468,6 @@ elements you can use attribute matching with methods like ``extract()``.
478 468
     Expands an array that was previously flattened with
479 469
     :php:meth:`Hash::flatten()`::
480 470
 
481  
-        <?php
482 471
         $data = array(
483 472
             '0.Post.id' => 1,
484 473
             '0.Post.title' => First Post,
@@ -520,7 +509,6 @@ elements you can use attribute matching with methods like ``extract()``.
520 509
 
521 510
     ::
522 511
 
523  
-        <?php
524 512
         $array = array(
525 513
             array(
526 514
                 'id' => '48c2570e-dfa8-4c32-a35e-0d71cbdd56cb',
@@ -567,7 +555,6 @@ elements you can use attribute matching with methods like ``extract()``.
567 555
 
568 556
     Checks to see if all the values in the array are numeric::
569 557
 
570  
-        <?php
571 558
         $data = array('one');
572 559
         $res = Hash::numeric(array_keys($data));
573 560
         // $res is true
@@ -583,7 +570,6 @@ elements you can use attribute matching with methods like ``extract()``.
583 570
     Counts the dimensions of an array. This method will only 
584 571
     consider the dimension of the first element in the array::
585 572
 
586  
-        <?php
587 573
         $data = array('one', '2', 'three');
588 574
         $result = Hash::dimensions($data);
589 575
         // $result == 1
@@ -610,7 +596,6 @@ elements you can use attribute matching with methods like ``extract()``.
610 596
     Similar to :php:meth:`~Hash::dimensions()`, however this method returns,
611 597
     the deepest number of dimensions of any element in the array::
612 598
 
613  
-        <?php
614 599
         $data = array('1' => '1.1', '2', '3' => array('3.1' => '3.1.1'));
615 600
         $result = Hash::dimensions($data, true);
616 601
         // $result == 2
@@ -638,7 +623,6 @@ elements you can use attribute matching with methods like ``extract()``.
638 623
     Sorts an array by any value, determined by a :ref:`hash-path-syntax`
639 624
     Only expression elements are supported by this method::
640 625
 
641  
-        <?php
642 626
         $a = array(
643 627
             0 => array('Person' => array('name' => 'Jeff')),
644 628
             1 => array('Shirt' => array('color' => 'black'))
@@ -680,7 +664,6 @@ elements you can use attribute matching with methods like ``extract()``.
680 664
 
681 665
     Computes the difference between two arrays::
682 666
 
683  
-        <?php
684 667
         $a = array(
685 668
             0 => array('name' => 'main'),
686 669
             1 => array('name' => 'about')
@@ -712,7 +695,6 @@ elements you can use attribute matching with methods like ``extract()``.
712 695
     **Example 1**
713 696
     ::
714 697
 
715  
-        <?php
716 698
         $array1 = array('ModelOne' => array('id' => 1001, 'field_one' => 'a1.m1.f1', 'field_two' => 'a1.m1.f2'));
717 699
         $array2 = array('ModelOne' => array('id' => 1003, 'field_one' => 'a3.m1.f1', 'field_two' => 'a3.m1.f2', 'field_three' => 'a3.m1.f3'));
718 700
         $res = Hash::mergeDiff($array1, $array2);
@@ -733,7 +715,6 @@ elements you can use attribute matching with methods like ``extract()``.
733 715
     **Example 2**
734 716
     ::
735 717
 
736  
-        <?php
737 718
         $array1 = array("a" => "b", 1 => 20938, "c" => "string");
738 719
         $array2 = array("b" => "b", 3 => 238, "c" => "string", array("extra_field"));
739 720
         $res = Hash::mergeDiff($array1, $array2);
@@ -761,7 +742,6 @@ elements you can use attribute matching with methods like ``extract()``.
761 742
     converted to string keys with null values. Normalizing an array, makes using
762 743
     the results with :php:meth:`Hash::merge()` easier::
763 744
 
764  
-        <?php
765 745
         $a = array('Tree', 'CounterCache',
766 746
             'Upload' => array(
767 747
                 'folder' => 'products',
@@ -826,7 +806,6 @@ elements you can use attribute matching with methods like ``extract()``.
826 806
 
827 807
     Example::
828 808
 
829  
-        <?php
830 809
         $data = array(
831 810
             array('ModelName' => array('id' => 1, 'parent_id' => null)),
832 811
             array('ModelName' => array('id' => 2, 'parent_id' => 1)),
13  en/core-utility-libraries/httpsocket.rst
Source Rendered
@@ -19,7 +19,6 @@ HTTP methods.
19 19
     and values. The get method makes a simple HTTP GET request returning the
20 20
     results::
21 21
 
22  
-        <?php
23 22
         App::uses('HttpSocket', 'Network/Http');
24 23
 
25 24
         $HttpSocket = new HttpSocket();
@@ -40,7 +39,6 @@ HTTP methods.
40 39
     made; ``$query`` is the data to be posted, either as s string, or as 
41 40
     an array of keys and values::
42 41
 
43  
-        <?php
44 42
         App::uses('HttpSocket', 'Network/Http');
45 43
 
46 44
         $HttpSocket = new HttpSocket();
@@ -80,7 +78,6 @@ HTTP methods.
80 78
     $request is a keyed array of various options. Here is the format
81 79
     and default settings::
82 80
 
83  
-        <?php
84 81
         public $request = array(
85 82
             'method' => 'GET',
86 83
             'uri' => array(
@@ -121,7 +118,6 @@ contents of an HTTP response. This class implements the
121 118
 so you can continue using the ``$http->response`` as array and the return of
122 119
 request methods as string::
123 120
 
124  
-    <?php
125 121
     App::uses('HttpSocket', 'Network/Http');
126 122
 
127 123
     $http = new HttpSocket();
@@ -173,7 +169,6 @@ keys sent. In order to safely access the header fields, it's best to use
173 169
 
174 170
 You could fetch the above headers by calling::
175 171
 
176  
-    <?php
177 172
     // $response is an instance of HttpResponse
178 173
     // get the Content-Type header.
179 174
     $response->getHeader('Content-Type');
@@ -227,7 +222,6 @@ configure how SSL certificates are handled:
227 222
 
228 223
 These options are provided as constructor arguments::
229 224
 
230  
-    <?php
231 225
     $socket = new HttpSocket(array(
232 226
         'ssl_allow_self_signed' => true
233 227
     ));
@@ -244,7 +238,6 @@ Creating a custom response class
244 238
 You can create your own response class to use with HttpSocket. You could create
245 239
 the file ``app/Lib/Network/Http/YourResponse.php`` with the content::
246 240
 
247  
-    <?php
248 241
     App::uses('HttpResponse', 'Network/Http');
249 242
 
250 243
     class YourResponse extends HttpResponse {
@@ -258,7 +251,6 @@ the file ``app/Lib/Network/Http/YourResponse.php`` with the content::
258 251
 
259 252
 Before your request you'll need to change the responseClass property::
260 253
 
261  
-    <?php
262 254
     App::uses('HttpSocket', 'Network/Http');
263 255
 
264 256
     $http = new HttpSocket();
@@ -275,7 +267,6 @@ HttpSocket has a new method called `setContentResource()`. By setting a resource
275 267
 with this method, the content will be written to this resource, using
276 268
 `fwrite()`. To you download a file, you can do::
277 269
 
278  
-    <?php
279 270
     App::uses('HttpSocket', 'Network/Http');
280 271
 
281 272
     $http = new HttpSocket();
@@ -298,7 +289,6 @@ box.  You can also create custom authentication objects to support protocols
298 289
 like OAuth.  To use any authentication system you need to configure the
299 290
 ``HttpSocket`` instance::
300 291
 
301  
-    <?php
302 292
     App::uses('HttpSocket', 'Network/Http');
303 293
 
304 294
     $http = new HttpSocket();
@@ -314,7 +304,6 @@ You can now create your own authentication method to use with HttpSocket. You
314 304
 could create the file ``app/Lib/Network/Http/YourMethodAuthentication.php`` with the
315 305
 content::
316 306
 
317  
-    <?php
318 307
 
319 308
     class YourMethodAuthentication {
320 309
 
@@ -334,7 +323,6 @@ content::
334 323
 To configure HttpSocket to use your auth configuration, you can use the new
335 324
 method ``configAuth()``::
336 325
 
337  
-    <?php
338 326
     $http->configAuth('YourMethod', array('config1' => 'value1', 'config2' => 'value2'));
339 327
     $http->get('http://secure.your-site.com');
340 328
 
@@ -347,7 +335,6 @@ As part of auth configuration, you can configure proxy authentication. You can
347 335
 create your customized method to proxy authentication in the same class of
348 336
 authentication. For example::
349 337
 
350  
-    <?php
351 338
 
352 339
     class YourMethodAuthentication {
353 340
 
2  en/core-utility-libraries/inflector.rst
Source Rendered
@@ -73,4 +73,4 @@ normally accessed statically. Example:
73 73
 
74 74
 .. meta::
75 75
     :title lang=en: Inflector
76  
-    :keywords lang=en: apple orange,word variations,apple pie,person man,latin versions,profile settings,php class,initial state,puree,slug,apples,oranges,user profile,underscore
  76
+    :keywords lang=en: apple orange,word variations,apple pie,person man,latin versions,profile settings,php class,initial state,puree,slug,apples,oranges,user profile,underscore
13  en/core-utility-libraries/number.rst
Source Rendered
@@ -6,7 +6,6 @@ CakeNumber
6 6
 If you need :php:class:`NumberHelper` functionalities outside of a ``View``,
7 7
 use the ``CakeNumber`` class::
8 8
 
9  
-    <?php
10 9
     class UsersController extends AppController {
11 10
 
12 11
         public $components = array('Auth');
@@ -38,7 +37,6 @@ automatically echo the output into the view.
38 37
     This method is used to display a number in common currency formats
39 38
     (EUR,GBP,USD). Usage in a view looks like::
40 39
 
41  
-        <?php
42 40
         // called as NumberHelper
43 41
         echo $this->Number->currency($number, $currency);
44 42
 
@@ -103,7 +101,6 @@ automatically echo the output into the view.
103 101
     If a non-recognized $currency value is supplied, it is prepended to
104 102
     a USD formatted number. For example::
105 103
 
106  
-        <?php
107 104
         // called as NumberHelper
108 105
         echo $this->Number->currency('1234.56', 'FOO');
109 106
 
@@ -132,7 +129,6 @@ automatically echo the output into the view.
132 129
     Add a currency format to the Number helper. Makes reusing
133 130
     currency formats easier::
134 131
 
135  
-        <?php
136 132
         // called as NumberHelper
137 133
         $this->Number->addFormat('BRR', array('before' => 'R$ '));
138 134
 
@@ -142,7 +138,6 @@ automatically echo the output into the view.
142 138
 
143 139
     You can now use `BRR` as a short form when formatting currency amounts::
144 140
 
145  
-        <?php
146 141
         // called as NumberHelper
147 142
         echo $this->Number->currency($value, 'BRR');
148 143
 
@@ -152,7 +147,6 @@ automatically echo the output into the view.
152 147
 
153 148
     Added formats are merged with the following defaults::
154 149
 
155  
-       <?php
156 150
        array(
157 151
            'wholeSymbol'      => '',
158 152
            'wholePosition'    => 'before',
@@ -175,7 +169,6 @@ automatically echo the output into the view.
175 169
     precision (decimal places). It will round in order to maintain the
176 170
     level of precision defined.::
177 171
 
178  
-        <?php
179 172
         // called as NumberHelper
180 173
         echo $this->Number->precision(456.91873645, 2);
181 174
 
@@ -197,7 +190,6 @@ automatically echo the output into the view.
197 190
     precision). This method also expresses the number as a percentage
198 191
     and prepends the output with a percent sign.::
199 192
 
200  
-        <?php
201 193
         // called as NumberHelper
202 194
         echo $this->Number->toPercentage(45.691873645);
203 195
 
@@ -228,7 +220,6 @@ automatically echo the output into the view.
228 220
     of data supplied (i.e. higher sizes are expressed in larger
229 221
     terms)::
230 222
 
231  
-        <?php
232 223
         // called as NumberHelper
233 224
         echo $this->Number->toReadableSize(0); // 0 Bytes
234 225
         echo $this->Number->toReadableSize(1024); // 1 KB
@@ -249,7 +240,6 @@ automatically echo the output into the view.
249 240
     most of the other NumberHelper methods). Using this method might
250 241
     looks like::
251 242
 
252  
-        <?php
253 243
         // called as NumberHelper
254 244
         $this->Number->format($number, $options);
255 245
 
@@ -279,7 +269,6 @@ automatically echo the output into the view.
279 269
 
280 270