Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 12 additions & 34 deletions docs/en/contributing/cakephp-coding-conventions.md
Original file line number Diff line number Diff line change
Expand Up @@ -411,40 +411,18 @@ be preceded by a newline.

Variable types for use in DocBlocks:

Type
Description

mixed
A variable with undefined (or multiple) type.

int
Integer type variable (whole number).

float
Float type (point number).

bool
Logical type (true or false).

string
String type (any value in " " or ' ').

null
Null type. Usually used in conjunction with another type.

array
Array type.

object
Object type. A specific class name should be used if possible.

resource
Resource type (returned by for example mysql_connect()).
Remember that when you specify the type as mixed, you should indicate
whether it is unknown, or what the possible types are.

callable
Callable function.
| Type | Description |
|------|-------------|
| mixed | A variable with undefined (or multiple) type. |
| int | Integer type variable (whole number). |
| float | Float type (point number). |
| bool | Logical type (true or false). |
| string | String type (any value in " " or ' '). |
| null | Null type. Usually used in conjunction with another type. |
| array | Array type. |
| object | Object type. A specific class name should be used if possible. |
| resource | Resource type (returned by for example mysql_connect()). Remember that when you specify the type as mixed, you should indicate whether it is unknown, or what the possible types are. |
| callable | Callable function. |

You can also combine types using the pipe char:

Expand Down
8 changes: 4 additions & 4 deletions docs/en/controllers/request-response.md
Original file line number Diff line number Diff line change
Expand Up @@ -782,12 +782,12 @@ $response = $this->response->withFile(
The supported options are:

name
The name allows you to specify an alternate file name to be sent to
the user.
: The name allows you to specify an alternate file name to be sent to
the user.

download
A boolean value indicating whether headers should be set to force
download.
: A boolean value indicating whether headers should be set to force
download.

### Sending a String as a File

Expand Down
2 changes: 1 addition & 1 deletion docs/en/core-libraries/logging.md
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,7 @@ more information.
`static` Cake\\Log\\Log::**configured**(): array

returns
An array of configured loggers.
: An array of configured loggers.

Get the names of the configured loggers.

Expand Down
97 changes: 48 additions & 49 deletions docs/en/development/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,11 @@ Below is a description of the variables and how they affect your CakePHP
application.

debug
Changes CakePHP debugging output. `false` = Production mode. No error
messages, errors, or warnings shown. `true` = Errors and warnings shown.
: Changes CakePHP debugging output. `false` = Production mode. No error
messages, errors, or warnings shown. `true` = Errors and warnings shown.

App.namespace
The namespace to find app classes under.
: The namespace to find app classes under.

> [!NOTE]
> When changing the namespace in your configuration, you will also
Expand All @@ -102,78 +102,77 @@ The namespace to find app classes under.
<div id="core-configuration-baseurl">

App.baseUrl
Un-comment this definition if you **dont** plan to use Apaches
mod_rewrite with CakePHP. Dont forget to remove your .htaccess
files too.
: Un-comment this definition if you **don't** plan to use Apache's
mod_rewrite with CakePHP. Don't forget to remove your .htaccess
files too.

App.base
The base directory the app resides in. If `false` this
will be auto detected. If not `false`, ensure your string starts
with a `/` and does NOT end with a `/`. For example, `/basedir` is a valid
App.base.
: The base directory the app resides in. If `false` this
will be auto detected. If not `false`, ensure your string starts
with a `/` and does NOT end with a `/`. For example, `/basedir` is a valid
App.base.

App.encoding
Define what encoding your application uses. This encoding
is used to generate the charset in the layout, and encode entities.
It should match the encoding values specified for your database.
: Define what encoding your application uses. This encoding
is used to generate the charset in the layout, and encode entities.
It should match the encoding values specified for your database.

App.webroot
The webroot directory.
: The webroot directory.

App.wwwRoot
The file path to webroot.
: The file path to webroot.

App.fullBaseUrl
The fully qualified domain name (including protocol) to your application's
root. This is used when generating absolute URLs. By default, this value
is generated using the `$_SERVER` environment. However, you should define it
manually to optimize performance or if you are concerned about people
manipulating the `Host` header.
In a CLI context (from command) the `fullBaseUrl` cannot be read from $_SERVER,
as there is no webserver involved. You do need to specify it yourself if
you do need to generate URLs from a shell (for example, when sending emails).
: The fully qualified domain name (including protocol) to your application's
root. This is used when generating absolute URLs. By default, this value
is generated using the `$_SERVER` environment. However, you should define it
manually to optimize performance or if you are concerned about people
manipulating the `Host` header.
In a CLI context (from command) the `fullBaseUrl` cannot be read from $_SERVER,
as there is no webserver involved. You do need to specify it yourself if
you do need to generate URLs from a shell (for example, when sending emails).

App.imageBaseUrl
Web path to the public images directory under webroot. If you are using
a `CDN` you should set this value to the CDN's location.
: Web path to the public images directory under webroot. If you are using
a `CDN` you should set this value to the CDN's location.

App.cssBaseUrl
Web path to the public css directory under webroot. If you are using
a `CDN` you should set this value to the CDN's location.
: Web path to the public css directory under webroot. If you are using
a `CDN` you should set this value to the CDN's location.

App.jsBaseUrl
Web path to the public js directory under webroot. If you are using
a `CDN` you should set this value to the CDN's location.
: Web path to the public js directory under webroot. If you are using
a `CDN` you should set this value to the CDN's location.

App.paths
Configure paths for non class based resources. Supports the
`plugins`, `templates`, `locales` subkeys, which allow the definition
of paths for plugins, view templates and locale files respectively.
: Configure paths for non class based resources. Supports the
`plugins`, `templates`, `locales` subkeys, which allow the definition
of paths for plugins, view templates and locale files respectively.

App.uploadedFilesAsObjects
Defines whether uploaded files are being represented as objects (`true`),
or arrays (`false`). This option is being treated as enabled by default.
See the [File Uploads section](../controllers/request-response#request-file-uploads) in the Request &
Response Objects chapter for more information.
: Defines whether uploaded files are being represented as objects (`true`),
or arrays (`false`). This option is being treated as enabled by default.
See the [File Uploads section](../controllers/request-response#request-file-uploads) in the Request &
Response Objects chapter for more information.

Security.salt
A random string used in hashing. This value is also used as the
HMAC salt when doing symmetric encryption.
: A random string used in hashing. This value is also used as the
HMAC salt when doing symmetric encryption.

Asset.timestamp
Appends a timestamp which is last modified time of the particular
file at the end of asset files URLs (CSS, JavaScript, Image) when
using proper helpers. Valid values:

- (bool) `false` - Doesn't do anything (default)
- (bool) `true` - Appends the timestamp when debug is `true`
- (string) 'force' - Always appends the timestamp.
: Appends a timestamp which is last modified time of the particular
file at the end of asset files URLs (CSS, JavaScript, Image) when
using proper helpers. Valid values:
(bool) `false` - Doesn't do anything (default),
(bool) `true` - Appends the timestamp when debug is `true`,
(string) 'force' - Always appends the timestamp.

Asset.cacheTime
Sets the asset cache time. This determines the http header `Cache-Control`'s
`max-age`, and the http header's `Expire`'s time for assets.
This can take anything that you version of PHP's [strtotime function](https://php.net/manual/en/function.strtotime.php) can take.
The default is `+1 day`.
: Sets the asset cache time. This determines the http header `Cache-Control`'s
`max-age`, and the http header's `Expire`'s time for assets.
This can take anything that you version of PHP's [strtotime function](https://php.net/manual/en/function.strtotime.php) can take.
The default is `+1 day`.

</div>

Expand Down
Loading